PLEASE NOTE: These forums are no longer utilized and are provided as an archive for informational purposes only. All support issues will be handled via email using our support ticket system. For more detailed information on this change, please see this blog post.

Output data entry based on conditional fields selection

  1. FanaticWeb
    Member

    Hi guys,

    So far my forms auto-post the Title, Description field, Tags AND thanks to your help, the attached images and all this gets posted automatically on to the blog upon submission.

    I would like to push this a bit further by including important and relative conditional fields.

    Let's say the form is about posting an event and here are the conditions:
    Main conditional field: Local or Tourist
    If the user chooses Tourist, then the following Date fields will appear:
    Event start: (date field)
    Event Ends: (date field)

    I'm trying to output those results and display them within the post and most likely will need to do the same for other conditional fields and get them displayed in the post as well.

    My current code highlighting the image attachments:

    [php]
    <postContentTemplateEnabled><![CDATA[1]]></postContentTemplateEnabled>
    		<postContentTemplate><![CDATA[{Description:13}<p><br class="clear:both;" /></p>
    <div class='additional_images'><a href="url}" rel="nofollow">{Photo 2:36:thumbnail:left}</a><a href="url}" rel="nofollow">{Photo 3:37:thumbnail:left}</a><a href="url}" rel="nofollow">{Photo 4:38:thumbnail:left}</a><br class="clear:both;" /></div><p>
    
    </p>]]></postContentTemplate>

    I would like to be able to output the title entry of the conditional field (Local or Tourist) and display the Dates below it

    How do I go by pulling the end results of the user's selection from those conditional fields to output them in the post?

    Expected final results on the blog:
    Thumbnail of the post aligned to the right.
    Title
    Description
    Location status (Local or Tourist) - Visiting from (date field) - Visiting until (date field)
    Attached images (aligned in the middle to the left)
    And then the theme takes care of displaying the category and tags attached to the post.

    Posted 13 years ago on Friday September 2, 2011 | Permalink
  2. The content template does not currently support conditional statements. So there isn't currently a way to conditionally show information in the content template. It is a feature we would like to add in the future.

    Posted 13 years ago on Tuesday September 6, 2011 | Permalink
  3. FanaticWeb
    Member

    ok... hoping this future will be close enough, thanks Carl.

    Posted 13 years ago on Thursday September 8, 2011 | Permalink

This topic has been resolved and has been closed to new replies.