@@ -197,14 +197,14 @@ discard block |
||
197 | 197 | // Add marker cluster |
198 | 198 | if (isset($params['marker_cluster']) && gdsc_to_bool_val($params['marker_cluster']) && defined('GDCLUSTER_VERSION')) { |
199 | 199 | $map_args['enable_marker_cluster'] = true; |
200 | - if(get_option('geodir_marker_cluster_type')) { |
|
200 | + if (get_option('geodir_marker_cluster_type')) { |
|
201 | 201 | if ($map_args['autozoom']) { |
202 | 202 | $map_args['enable_marker_cluster_no_reposition'] = false; |
203 | 203 | } else { |
204 | 204 | $map_args['enable_marker_cluster_no_reposition'] = true; |
205 | 205 | } |
206 | 206 | |
207 | - $map_args['enable_marker_cluster_server'] = true ; |
|
207 | + $map_args['enable_marker_cluster_server'] = true; |
|
208 | 208 | |
209 | 209 | } |
210 | 210 | } else { |
@@ -212,7 +212,7 @@ discard block |
||
212 | 212 | } |
213 | 213 | |
214 | 214 | // if lat and long set in shortcode, hack it so the map is not repositioned |
215 | - if(!empty($params['latitude']) && !empty($params['longitude']) ){ |
|
215 | + if (!empty($params['latitude']) && !empty($params['longitude'])) { |
|
216 | 216 | $map_args['enable_marker_cluster_no_reposition'] = true; |
217 | 217 | } |
218 | 218 | |
@@ -300,7 +300,7 @@ discard block |
||
300 | 300 | |
301 | 301 | // Array_intersect returns only the items in $params['category'] that are also in our category list |
302 | 302 | // Otherwise it becomes empty and later on that will mean "All" |
303 | - $params['category'] = array_intersect($params['category'], $categories); |
|
303 | + $params['category'] = array_intersect($params['category'], $categories); |
|
304 | 304 | |
305 | 305 | if ($params['post_type'] == 'gd_event') { |
306 | 306 | $params['event_type'] = gdsc_validate_list_filter_choice($params['event_type']); |
@@ -316,7 +316,7 @@ discard block |
||
316 | 316 | 'gd_location' => false, |
317 | 317 | ); |
318 | 318 | |
319 | - if (!empty($params['category']) && isset($params['category'][0]) && (int)$params['category'][0] != 0) { |
|
319 | + if (!empty($params['category']) && isset($params['category'][0]) && (int) $params['category'][0] != 0) { |
|
320 | 320 | $category_taxonomy = geodir_get_taxonomies($params['post_type']); |
321 | 321 | |
322 | 322 | ######### WPML ######### |
@@ -964,20 +964,20 @@ discard block |
||
964 | 964 | |
965 | 965 | $show_adv_search = isset($params['show_adv_search']) && in_array($params['show_adv_search'], array('default', 'always', 'searched')) ? $params['show_adv_search'] : ''; |
966 | 966 | |
967 | - if ($show_adv_search != '' ) { |
|
968 | - $show_adv_class = 'geodir-advance-search-' . $show_adv_search . ' '; |
|
967 | + if ($show_adv_search != '') { |
|
968 | + $show_adv_class = 'geodir-advance-search-'.$show_adv_search.' '; |
|
969 | 969 | if ($show_adv_search == 'searched' && geodir_is_page('search')) { |
970 | 970 | $show_adv_search = 'search'; |
971 | 971 | } |
972 | - $show_adv_attrs = 'data-show-adv="' . $show_adv_search . '"'; |
|
972 | + $show_adv_attrs = 'data-show-adv="'.$show_adv_search.'"'; |
|
973 | 973 | |
974 | - $params['before_widget'] = str_replace('class="', $show_adv_attrs . ' class="' . $show_adv_class, $params['before_widget']); |
|
974 | + $params['before_widget'] = str_replace('class="', $show_adv_attrs.' class="'.$show_adv_class, $params['before_widget']); |
|
975 | 975 | } |
976 | 976 | |
977 | 977 | ob_start(); |
978 | 978 | |
979 | 979 | //geodir_get_template_part('listing', 'filter-form'); |
980 | - the_widget('geodir_advance_search_widget', $params, $params ); |
|
980 | + the_widget('geodir_advance_search_widget', $params, $params); |
|
981 | 981 | |
982 | 982 | $output = ob_get_contents(); |
983 | 983 | ob_end_clean(); |
@@ -1177,7 +1177,7 @@ discard block |
||
1177 | 1177 | |
1178 | 1178 | // Validate character_count |
1179 | 1179 | //todo: is this necessary? |
1180 | - $params['character_count'] = $params['character_count']; |
|
1180 | + $params['character_count'] = $params['character_count']; |
|
1181 | 1181 | |
1182 | 1182 | // Validate our layout choice |
1183 | 1183 | // Outside of the norm, I added some more simple terms to match the existing |
@@ -1189,7 +1189,7 @@ discard block |
||
1189 | 1189 | |
1190 | 1190 | // Validate Listing width, used in the template widget-listing-listview.php |
1191 | 1191 | // The context is in width=$listing_width% - So we need a positive number between 0 & 100 |
1192 | - $params['listing_width'] = gdsc_validate_listing_width($params['listing_width']); |
|
1192 | + $params['listing_width'] = gdsc_validate_listing_width($params['listing_width']); |
|
1193 | 1193 | |
1194 | 1194 | // Validate the checkboxes used on the widget |
1195 | 1195 | $params['add_location_filter'] = gdsc_to_bool_val($params['add_location_filter']); |
@@ -1205,7 +1205,7 @@ discard block |
||
1205 | 1205 | if (!empty($params['tags'])) { |
1206 | 1206 | if (!is_array($params['tags'])) { |
1207 | 1207 | $comma = _x(',', 'tag delimiter'); |
1208 | - if ( ',' !== $comma ) { |
|
1208 | + if (',' !== $comma) { |
|
1209 | 1209 | $params['tags'] = str_replace($comma, ',', $params['tags']); |
1210 | 1210 | } |
1211 | 1211 | $params['tags'] = explode(',', trim($params['tags'], " \n\t\r\0\x0B,")); |
@@ -1227,13 +1227,13 @@ discard block |
||
1227 | 1227 | unset($atts['pageno']); |
1228 | 1228 | } |
1229 | 1229 | |
1230 | - if ( !empty($atts['shortcode_content']) ) { |
|
1230 | + if (!empty($atts['shortcode_content'])) { |
|
1231 | 1231 | $content = $atts['shortcode_content']; |
1232 | 1232 | } |
1233 | 1233 | $params['shortcode_content'] = trim($content); |
1234 | 1234 | $atts['shortcode_content'] = trim($content); |
1235 | 1235 | |
1236 | - $params['shortcode_atts'] = $atts; |
|
1236 | + $params['shortcode_atts'] = $atts; |
|
1237 | 1237 | |
1238 | 1238 | $output = geodir_sc_gd_listings_output($params); |
1239 | 1239 | |
@@ -1305,8 +1305,8 @@ discard block |
||
1305 | 1305 | // Validate the checkboxes used on the widget |
1306 | 1306 | $params['hide_empty'] = gdsc_to_bool_val($params['hide_empty']); |
1307 | 1307 | $params['show_count'] = gdsc_to_bool_val($params['show_count']); |
1308 | - $params['hide_icon'] = gdsc_to_bool_val($params['hide_icon']); |
|
1309 | - $params['cpt_left'] = gdsc_to_bool_val($params['cpt_left']); |
|
1308 | + $params['hide_icon'] = gdsc_to_bool_val($params['hide_icon']); |
|
1309 | + $params['cpt_left'] = gdsc_to_bool_val($params['cpt_left']); |
|
1310 | 1310 | |
1311 | 1311 | if ($params['max_count'] != 'all') { |
1312 | 1312 | $params['max_count'] = absint($params['max_count']); |