Events Made Easy Forums How do I … Conditional Results to Hide Empty Category

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #42444
    Anonymous
    Inactive

    I want to hide sections with empty results rather than display their divs and h3 tags. I’d tried something like this:

    if (!eme_are_events_available(‘scope=future&category=2’)){

    But, the category doesn’t seem to be factored into this function conditional.

    Is there something I’m missing? Is there an efficient way to test if events from a certain category return an empty set?

    Thanks in advance.

    #46371
    Franky
    Keymaster

    I’ve implemented conditional tags in the next version, so you can do stuff like this from within the format properties now. See http://www.e-dynamics.be/bbpress/topic.php?id=416#post-1961

    In your case: I’ve extended the function to include the common parameters:

    eme_are_events_available($scope = “future”,$order = “ASC”, $location_id = “”, $category = ”, $author = ”, $contact_person = ”)

Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘How do I …’ is closed to new topics and replies.
Scroll to Top