Events Made Easy Forums Generic Using attributes in events published through EME frontend submit

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #55331
    Anonymous
    Inactive

    The instructions said I could use EMEFS::attribute(‘something’) to create attribute fields. It wasn’t working for me. So I went through the code to see what was happening, and it appears that the code to add the data in $_POST[‘event_attributes’] is missing.

    Here’s a patch that fixes it.

    — events-made-easy-frontend-submit/emefs.php 2016-02-08 13:56:47.508014940 -0800
    +++ events-made-easy-frontend-submit-jk/emefs.php 2016-02-12 16:32:56.224528861 -0800
    @@ -239,6 +239,12 @@
    }
    }

    + // add in the event_attributes
    + if ( !empty( $_POST[‘event_attributes’] ) ) {
    + $event_attributes = stripslashes_deep($_POST[‘event_attributes’]);
    + $event_data[‘event_attributes’] = serialize($event_attributes);
    + }
    +
    // after submit, not all event fields are present, so we will merge the submitted data with a new event
    $new_event = eme_new_event();

    #55332
    Franky
    Keymaster

    Weird … I’m sure I tested that and it worked fine 🙂
    Thanks for the fix, I added something similar.
    Could you test if this fixes it too:
    http://plugins.trac.wordpress.org/changeset/1350554

    #55335
    Anonymous
    Inactive

    Thank you! I’ll try to test this today.

    This isn’t really related, but I found that, for our purposes of making a list of marches across the country, the event organizers didn’t know when the event would end.

    #55338
    Franky
    Keymaster

    For that: create an attribute that says to ignore the end time, and in the event template check for that value and don’t show the end date if not desired (using conditional tags).

Viewing 4 posts - 1 through 4 (of 4 total)
  • The forum ‘Generic’ is closed to new topics and replies.
Scroll to Top