Bugs relating to the “Hide the opening hours?” setting
-
The setting “Hide the opening hours?” doesn’t affect the [wpsl_hours] shortcode, meaning the shortcode will continue to show the opening hours despite this setting being enabled.
Furthermore, the code provided on https://wpstorelocator.co/document/show-opening-hours-in-search-results/ does not support this setting, resulting in listing failure when the setting is enabled. I fixed this by adding an ‘if’ statement:
if ( !$wpsl_settings['hide_hours'] ) { $listing_template .= "\t\t\t" . '<% if ( hours ) { %>' . "\r\n"; $listing_template .= "\t\t\t" . '<p><%= hours %></p>' . "\r\n"; $listing_template .= "\t\t\t" . '<% } %>' . "\r\n"; }
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Bugs relating to the “Hide the opening hours?” setting’ is closed to new replies.