Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support angelo_nwl

    (@angelo_nwl)

    using your snippet

    function similar_events() {
    	$replace = "";
    	$events = EM_Events::get(array('limit'=>4,'scope'=>'future'));
    	shuffle($event);
    	foreach ( $events as $EM_Event ) {
    		$replace .= '<h6>'.$EM_Event->output('#_EVENTLINK').'</h6>';
    	}
    	return $replace;
    }
    add_shortcode( 'similarevents', 'similar_events' );
    Thread Starter val-13Love

    (@val-13love)

    Hi Angelo

    Thanks for the updated snippet. It now positions the results in the same location where the shortcode is added which is great. However it is still displaying the same 4 events and not random events.

    Do you by any chance have any other suggestions that will make it show random events please?

    Much Thanks
    Val ??

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Display random future events’ is closed to new replies.