Search

Hello,

I am a bit of a newbie and need some help creating events for forms on the frontend.

I have modeled my sections on the backend utilizing a couple of special field types, namely the 'select box link' and 'google map' field types.

When creating an event I get plain input fields for these fields. How can I utilize these fields on an event the way they work on the backend?

Thanks.

I faced the very same problem regarding the Map Location Field on a front end submission form: the only solution I could think of was to copy the way the field works in the back end and to transpose it in the front end – so in your front end you need to reproduce the very same HTML structure the field has in the back end and point to the javascript file you find in the assets folder contained in the Map Location Field extension one, which is named maplocationfield.publish.js.

I’m not aware if there are better ways to achieve the very same result or if there is any counter-indication.

Just look at the markup for an implementation of that field in the backend, and you will see how to pass data through to it.

The default event documentation can't sufficiently replicate all the variety of the extensions fields, so it doesn't even try.

The default event documentation can't sufficiently replicate all the variety of the extensions fields, so it doesn't even try.

Not true, it looks to see if an extension has implemented the getExampleFormMarkup function which returns an XMLElement that represents the markup required on the Frontend for the field to work with events.

While I don't think anyone has actually done it, this markup could return the &lt;script />/<link /> assets as well so that the full interface can be recreated on the frontend easily.

It's usually down to developer laziness: with the map location field I have never needed to submit from the frontend so I never bothered testing or documenting it.

Create an account or sign in to comment.

Symphony • Open Source XSLT CMS

Server Requirements

  • PHP 5.3-5.6 or 7.0-7.3
  • PHP's LibXML module, with the XSLT extension enabled (--with-xsl)
  • MySQL 5.5 or above
  • An Apache or Litespeed webserver
  • Apache's mod_rewrite module or equivalent

Compatible Hosts

Sign in

Login details