Support » Plugin: Events Manager » [Plugin: Events Manager] Hiding an Event

  • Using Plugin 4.304 still (not the time to do this big step to posts, yet)

    I want to hide an event (temporarily) to avoid that I have to retype all the crap again when deciding to put it up again.

    Besides putting an old date, is there a simple way out like a custom attribute that then easily removes all the events with that flag set from all event queries ?

    I want to avoid the need to add stuff to my own plugin to achieve this if possible.


Viewing 1 replies (of 1 total)
  • you can create a similar search attribute like these:

    function my_em_hide_event($searches, $array){
    	if( !empty($array['hide_event']) ){
    		$searches['hide_event'] = $array['hide_event'];
    	return $searches;
    function my_em_hide_event_get($events, $args){
    	if( !empty($args['hide_event']) ){
    		foreach($events as $event_key => $EM_Event){
    			if( in_array($args['hide_event'],$EM_Event->event_attributes) ){
    	return $events;

    Modify and copy to your theme functions.php

    Sample usage: [events_list hide_event=1]

Viewing 1 replies (of 1 total)
  • The topic ‘[Plugin: Events Manager] Hiding an Event’ is closed to new replies.