Changeset 1874791
- Timestamp:
- 05/15/2018 03:56:50 PM (8 years ago)
- Location:
- wp-job-manager-locations/trunk
- Files:
-
- 4 edited
-
includes/class-template.php (modified) (2 diffs)
-
languages/wp-job-manager-locations.pot (modified) (2 diffs)
-
readme.txt (modified) (2 diffs)
-
wp-job-manager-locations.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
wp-job-manager-locations/trunk/includes/class-template.php
r1587517 r1874791 91 91 } 92 92 93 wp_dropdown_categories( apply_filters( 'job_manager_regions_dropdown_args', array(93 job_manager_dropdown_categories( apply_filters( 'job_manager_regions_dropdown_args', array( 94 94 'show_option_all' => __( 'All Regions', 'wp-job-manager-locations' ), 95 'multiple' => false, 95 96 'hierarchical' => true, 96 97 'orderby' => 'name', … … 145 146 */ 146 147 public function the_job_location( $job_location, $post ) { 148 $terms = wp_get_object_terms( 149 $post->ID, 150 'job_listing_region', 151 apply_filters( 'job_manager_locations_get_terms', array( 152 'orderby' => 'term_order', 153 'order' => 'desc' 154 ) ) 155 ); 156 157 $_terms = array(); 158 159 if ( empty( $terms ) ) { 160 return; 161 } 162 147 163 if ( is_singular( 'job_listing' ) ) { 148 return get_the_term_list( $post->ID, 'job_listing_region', '', ', ', '' ); 149 } else { 150 $terms = wp_get_object_terms( $post->ID, 'job_listing_region', array( 'orderby' => 'term_order', 'order' => 'desc') ); 151 152 if ( empty( $terms ) ) { 153 return; 164 foreach ( $terms as $term ) { 165 $_terms[] = '<a href=" ' . esc_url( get_term_link( $term ) ) . '">' . $term->name . '</a>'; 154 166 } 155 167 156 $names = array(); 168 } else { 169 foreach ( $terms as $term ) { 170 $_terms[] = $term->name; 171 } 172 } 157 173 158 foreach ( $terms as $term ) { 159 $names[] = $term->name; 160 } 174 $separator = apply_filters( 'job_manager_locations_get_term_list_separator', ', ' ); 161 175 162 return implode( ', ', $names ); 163 } 176 return implode( $separator, $_terms ); 164 177 } 165 178 } -
wp-job-manager-locations/trunk/languages/wp-job-manager-locations.pot
r1653764 r1874791 1 # Copyright (C) 201 7Astoundify1 # Copyright (C) 2018 Astoundify 2 2 # This file is distributed under the same license as the Regions for WP Job Manager package. 3 3 msgid "" 4 4 msgstr "" 5 "Project-Id-Version: Regions for WP Job Manager 1.1 3.0\n"5 "Project-Id-Version: Regions for WP Job Manager 1.15.0\n" 6 6 "Report-Msgid-Bugs-To: " 7 7 "https://wordpress.org/support/plugin/wp-job-manager-locations\n" 8 "POT-Creation-Date: 201 7-04-12 14:12:52+00:00\n"8 "POT-Creation-Date: 2018-05-14 14:40:00+00:00\n" 9 9 "MIME-Version: 1.0\n" 10 10 "Content-Type: text/plain; charset=utf-8\n" 11 11 "Content-Transfer-Encoding: 8bit\n" 12 "PO-Revision-Date: 201 7-MO-DA HO:MI+ZONE\n"12 "PO-Revision-Date: 2018-MO-DA HO:MI+ZONE\n" 13 13 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" 14 14 "Language-Team: LANGUAGE <LL@li.org>\n" … … 72 72 msgstr "" 73 73 74 #: includes/class-template.php:11 074 #: includes/class-template.php:111 75 75 msgid "Select Region" 76 76 msgstr "" -
wp-job-manager-locations/trunk/readme.txt
r1700422 r1874791 6 6 Tags: job, job listing, job region 7 7 Requires at least: 4.7.0 8 Tested up to: 4. 8.09 Stable Tag: 1.1 4.08 Tested up to: 4.9.6 9 Stable Tag: 1.15.0 10 10 License: GPLv3 11 11 License URI: http://www.gnu.org/licenses/gpl-3.0.html … … 31 31 32 32 == Changelog == 33 34 = 1.15.0: May 12, 2018 = 35 36 * New: Use `job_manager_dropdown_categories()` function instead of `wp_dropdown_categories()`. 37 * New: Add `job_manager_locations_get_terms` and `job_manager_locations_get_term_list_separator` filters for modifying output. 33 38 34 39 = 1.14.0: July 11, 2017 = -
wp-job-manager-locations/trunk/wp-job-manager-locations.php
r1700422 r1874791 6 6 * Author: Astoundify 7 7 * Author URI: http://astoundify.com 8 * Version: 1.1 4.08 * Version: 1.15.0 9 9 * Text Domain: wp-job-manager-locations 10 10 * Domain Path: /languages
Note: See TracChangeset
for help on using the changeset viewer.