please help with submit content

jinx5374 27 Dec, 2008
I'm kinda new when i comes to the ChronoForms but it so far it has been great. Quick question about the submitcontent application. can you have multiply fields enter into the body text. for example; a date field, location field, a description field and have all of it enter in the body of text. thanks in advance
Max_admin 27 Dec, 2008
Hi jinx5374,

yes you can, you can combine any number of fields when the form is submitted, do you just want them concatenated or how do you want them mixed exactly ? have a template ?

Regards
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
jinx5374 30 Dec, 2008
Thanks in advance for your help, what I'm trying to do is have the form recreate itself in the content so a person can go and see the filled out form and it could be sorted into different categories . i have a template done. would you like for me to post the html or a link to the page? thank you again.
GreyHead 30 Dec, 2008
Hi jinx5374,

Please take a backup copy of the form using the icon in the Forms Manager, zip it and post it here. And a link would be helpful too.

Bob
Max_admin 31 Dec, 2008
Hi Shane,

in general you will need to use str_replace to replace some placeholders in a constant string with the posted data then set the fulltext variable to equal the new constant string!

Regards
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
jinx5374 01 Jan, 2009
Cool thanks. if possiable can you give me an example? if not it's cool thanks again. sorry if i seem like an idiot, it's something complete new to me and i'm self teaching myself all of this as i go along.
Max_admin 01 Jan, 2009
Hi Shane,

assuming you have a field called "URL" in the form then ad this code to the onsubmit after email box:


<?php
$fulltext_template = "this is the URL added by the user:{URL}";
$fulltext_template = str_replace("{URL}", JRequest::getVar("URL"), $fulltext_template);
JRequest::setVar("fulltext", $fulltext_template);
?>


in the code above #1- I initiated the final template for the article, #2- replaced the placeholders with the submitted values of fields, #3- set the final article text to be the modified template!

pay attention to the order of the submit pieces, the onsubmit code should run before the auto generated code for this work correctly!

Regards
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
jinx5374 02 Jan, 2009
Thank you so much. this helps me out greatly.
This topic is locked and no more replies can be posted.