Skip to content

Instantly share code, notes, and snippets.

@andrasguseo
Created October 14, 2022 21:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save andrasguseo/229ca1107a7ee7e57a2fc0a5b4ab3af5 to your computer and use it in GitHub Desktop.
Save andrasguseo/229ca1107a7ee7e57a2fc0a5b4ab3af5 to your computer and use it in GitHub Desktop.
TEC > Customize the "No results" search message
<?php
/* Description: Customize the "No results" search message
* Usage: Paste the below snippet into your active (child) theme's functions.php file
*
* Plugin: The Events Calendar
* Author: Andras Guseo
* Last updated: 2022-10-12
*/
add_filter( 'tribe_events_views_v2_messages_map', 'tec_custom_no_result_text' );
function tec_custom_no_result_text ( $map ) {
$map['no_results_found_w_keyword'] .= '<br/>Please try <a href="" onclick="window.location.reload(true)" style="text-decoration: underline;">refreshing</a> the page.';
return $map;
}
@andrasguseo
Copy link
Author

andrasguseo commented Oct 14, 2022

The above snippet will produce something like this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment