The options include showing all events today, tomorrow, next month, and there seems to be a way with PHP to create a custom range, but typing a date into the search bar does not return events on that date, and there is no way to select a date and see only events on that date if it is not “today” or “tomorrow”.
We need to be able to pull up all events on a certain date (for example, Christmas day) several months in advance to edit or delete them all, and we have hundreds of events in our system, so going to each event one by one is incredibly tedious and time consuming when there ought to be a way to search for “everything on 25 December” and pull them all up at once.
https://www.ads-software.com/plugins/events-manager/
]]>This would allow users to find, for example:
Posts with the word “marketing” that were published between 01/01/2010 and 01/01/2015.
Is this available? Either in the free or premium version?
Thanks!
https://www.ads-software.com/plugins/relevanssi/
]]>Does this theme have a feature to search by on Dates (ie. Stay needed ‘from’ ‘to’ dates) and of course some standard search options like City, No of Guests?
Thank u
]]>Adolfo
https://www.ads-software.com/extend/plugins/gigs-calendar/
]]>I want to make it possible for people to search/ filter events by dates. For example, they can search for all events happening between 2nd December, 2011 and 1st March, 2012 and get results from events that have their dates between the months of December and March (ie. december, january, february and march).
I want to know the best way to go about this. Any ideas?
You can see an example of what I want to achieve by looking at the “Search events by date” feature on this page https://www.londontown.com/events
Here is the code for the start and end date meta boxes:
$prefix = 'ghes_';
add_filter( 'ghes_meta_boxes', 'ghes_sample_metaboxes' );
function ghes_sample_metaboxes( $meta_boxes ) {
global $prefix;
$meta_boxes[] = array(
'id' => 'event_meta',
'title' => 'Event Metabox',
'pages' => array('event'), // post type
'context' => 'normal',
'priority' => 'high',
'show_names' => true,
'fields' => array(
array(
'name' => 'Event Start Date',
'desc' => 'field description (optional)',
'id' => $prefix . 'event_start_timestamp',
'type' => 'text_date_timestamp'
),
array(
'name' => 'Event End Date',
'desc' => 'field description (optional)',
'id' => $prefix . 'event_end_timestamp',
'type' => 'text_date_timestamp'
)
Here is how the date data is saved:
case 'text_date_timestamp':
echo '<input class="ghes_text_small ghes_datepicker" type="text" name="', $field['id'], '" id="', $field['id'], '" value="', $meta ? date( 'm\/d\/Y', $meta ) : $field['std'], '" /><span class="ghes_metabox_description">', $field['desc'], '</span>';
break;
And this is what I have for my search box:
<form action="<?php bloginfo('url'); ?>" method="get" id="searchform" class="form_search">
Event Search:
<!-- START Category Search -->
<select name="event_cat">
<option value="0">Select...</option>
<?php
$theterms = get_terms('event_cat', 'orderby=name');
foreach ($theterms AS $term) :
echo "<option value='".$term->slug."'".($_GET['event_cat'] == $term->slug ? ' selected="selected"' : '').">".$term->name."</option>\n";
endforeach;
?>
</select>
<!-- END Category Search -->
<!-- START Date Search -->
<span class="em-events-search-dates">
<?php _e('between','ghes'); ?>:
<input class="ghes_text_small ghes_datepicker" type="text_date_timestamp" name="ghes_event_start_timestamp" id="ghes_event_start_timestamp" value=""/>'
<input type="hidden" id="ghes_event_start_timestamp" name="start" value="" />
<?php _e('and','ghes'); ?>
<input class="ghes_text_small ghes_datepicker" type="text" name="ghes_event_end_timestamp" id="ghes_event_end_timestamp" value=""/>'
<input type="hidden" id="ghes_event_end_timestamp" name="end" value="" />
</span>
<!-- END Date Search -->
<input type="hidden" name="_wpnonce" value="<?php echo wp_create_nonce('search_events'); ?>" />
<input type="submit" value="<?php _e('Search','ghes'); ?>" class="em-events-search-submit" />
</form>
How do I get the form to process the “date search” data and display results between the dates users select?
Is the search form missing anything? Is there something I should add to functions.php to make this work?
I have been looking for an answer for almost two weeks now and really want to learn how this works. Please share your thoughts if you have an idea of how to get this to work.
Thanks in advance.
]]>