Support » Plugin: Events Manager » Hide single category from Events List Page

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

    (@angelo_nwl)

    try shortcode [events_list category=”-X”] where x is the event categories id at Events > Event Categories (to show event category id, click Screen Options > checked ID and click Apply Button)

    http://wp-events-plugin.com/documentation/shortcodes/

    Event Search Attributes

    Hi,

    Is there anyway of doing this in the settings because I have the widget on the homepage which has the View all Events link activated which seems to only point to the page that is selected within the settings.

    Plugin Support angelo_nwl

    (@angelo_nwl)

    using events widget, try WP Appearance > Widgets > Events widgets > Category IDs then try -X where x is the event categories id

    Hi,
    Sorry the widget is fine on the page needed but id you look at http://www.tsc.mkconsultancy.co.uk/our-events/ the main list of events has a “Football Test” in it near the top but do not want it there. Just want to list Football items on a widget on this page as you will see.

    This events page is selected within the Events Settings so I am unable to edit the page.

    Hiya,

    You will likely need to remove your main events page from the setting at Events > Settings > Pages > Event List/Archives

    Then, replace the contents of your events page (it should be “CONTENTS”) with the shortcode Angelo suggested above.

    Thanks,
    Phil

    Hi,

    Will give that ago, however how do I then get the widget on the homepage to link to the page that I have this shortcode on?

    Plugin Support caimin_nwl

    (@caimin_nwl)

    Do you mean the LIVE:Football widget? Those are links to single events pages so will work fine.

    Hi,

    No, on the homepage there is a link on the Events widget that goes to the page that is the page which has the list of events which is the actual page that is selected within the settings.

    So if I create a new events page and add the shortcode to it how would I then change the link on the homepage widget to point to the new page I have created?

    Plugin Support caimin_nwl

    (@caimin_nwl)

    Got you.

    You can set which page the plugin uses as the Events page by going to Events > Settings > Pages > Events List/Archive > Events page.

    Hi,

    I under stand that but I have created a new page and added the shortcode to show a specific category but if I then select that page in Events > Settings > Pages > Events List/Archive > Events page then the shortcode is stripped out the default code use used.

    I want that Events page to show a specific category id but still be able

    Plugin Support caimin_nwl

    (@caimin_nwl)

    Ok, then I think might need a slightly different approach. Does the category you’re filtering out need to be filtered out throughout the site?

    It is only going to be required on the Live: Football widget on the events page and maybe another page with a shortcode but that is it

    Plugin Support caimin_nwl

    (@caimin_nwl)

    In that case, the easiest way would probably be to use shortcodes a with category attribute to show that category when needed, while creating a custom version of the events-list.php template that filters out that category.

    This tutorial shows you how to create custom templates that are upgrade safe:
    http://wp-events-plugin.com/documentation/using-template-files/

    The file you need to copy / modify is events-list.php. You’ll need to filter / edit the $args array to exclude the unwanted category.

    This thread should help:
    http://wordpress.org/support/topic/events-manager-search-all-instead-of-only-future

    Just looking at this and I am not a developer so might need a quick point, I have copied the events-list.php and not sure what I need to add to the page to filter it out?

    The current page has the following in it:
    $args = apply_filters(’em_content_events_args’, $args);

    if( get_option(‘dbem_css_evlist’) ) echo “<div class=’css-events-list’>”;

    echo EM_Events::output( $args );

    if( get_option(‘dbem_css_evlist’) ) echo “</div>”;

    Above that, add this;

    $args = array( 'category' => -1 );

    …replacing 1 with the ID number of the category you want to exclude.

    Thanks

Viewing 15 replies - 1 through 15 (of 19 total)
  • The topic ‘Hide single category from Events List Page’ is closed to new replies.