Home Forums Event Espresso Premium Front end submission

Front end submission

Posted: March 14, 2019 at 12:13 pm


March 14, 2019 at 12:13 pm

I want to create a Gravity Forms form that will allow various logged in user roles to submit an event from the front end of the website. Can someone suggest the hooks or filters that may come in handy for accomplishing. I plan to use the GF gform_after_submission Action Hook. I did see this post below and wanted to also check that there is nothing available for EE4?


  • Support Staff

March 14, 2019 at 3:52 pm


Event Espresso doesn’t actually expose hooks on the front end that are related to adding events. Any hooks you’d use in this case would be exposed by Gravity Forms.

You can make use of Event Espresso’s model system which simplifies writing data to tables used by Event Espresso for storing event related data.


March 27, 2019 at 4:04 pm

Thanks, the model system is exactly what I needed. After some playing around with the system, I was able to add a new event with EE_Event::new_instance. I am having some issue with deducing all the model references and field names. For instance, I need to set the dates and times for the event and trying to do different ways like this after getting my new event id:

$datetime = EE_Datetime::new_instance(array(
			'EVT_ID' => $event_id,
			'DTT_EVT_start' => '2019-04-01 08:00:00',
			'DTT_EVT_end' => '2019-04-01 08:00:00'
$datetime_id = $datetime->save();
error_log( print_r($datetime,true) );

I see the $datetime object in the error log after the save and see [DTT_EVT_start] => 2019-04-01 08:00:00\n and [DTT_EVT_end] => 2019-04-01 08:00:00\n, however the actual dates saved are the current date and time ran. Perhaps a format is not correct or I’m missing other required fields?

I’m also needing to add the image from a url and venue information.

Thanks for any pointers!


March 28, 2019 at 11:57 am

I was able to finally get all working. This snippet for the date and times:

$datetime = EE_Datetime::new_instance(array('EVT_ID' => $event_id), '', array('Y-m-d', 'G:i'));
$datetime->set_start_date( $start_date );
$datetime->set_start_time( $start_time );
$datetime->set_end_date( $end_date );
$datetime->set_end_time( $start_time );
$datetime_id = $datetime->save();

The support post ‘Front end submission’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Support forum for Event Espresso 3 and Event Espresso 4.
Documentation for EE3 and EE4
Documentation for Event Espresso 3

Documentation for Event Espresso 4

Status: closed

Updated by  wmnf 11 months ago ago

Topic Tags


This topic is: resolved
Do NOT follow this link or you will be banned from the site!