Hi I have a simple form with a dynamic drop down, which is working great
Once the user selects and item from the drop down, and presses the submit button, I am trying to send them to the next form passing the value of their selected items to the token url parameter
here is the forms url
Here is the redirectuser text
if I hard code a token value it works
what is the syntax for getting the value of the drop down named input_select_4 ?
Thanks in advance for your assistance
Dean-O
Once the user selects and item from the drop down, and presses the submit button, I am trying to send them to the next form passing the value of their selected items to the token url parameter
here is the forms url
<div id="main">
<div id="system-message-container"></div>
<form action="http://localhost:8888/pigskin/index.php?option=com_chronoforms&tmpl=component&chronoform=Buttons_Main_Menu&event=submit" name="Buttons_Main_Menu" id="chronoform_Buttons_Main_Menu" method="post" class="Chronoform">
<div class="ccms_form_element cfdiv_select" id="autoID-441c323485a8fbde2faedc74a59a7431_container_div" style="">
<label>Select An Option</label>
<select size="1" class="" title="" container_id="0" name="input_select_4">
<option value="1">Bar</option>
<option value="2">Car</option>
<option value="3">Bus</option>
<option value="4">General</option>
</select>
<div class="clear"></div>
<div id="error-message-input_select_4"></div>
</div>
<input type="hidden" name="3212360ca5ffd4d221f3f1360014b2e8" value="1" /></form>
Here is the redirectuser text
index.php?option=com_chronoforms&chronoform=next_page&token={input_select_4}
if I hard code a token value it works
index.php?option=com_chronoforms&chronoform=next_page&token=3
what is the syntax for getting the value of the drop down named input_select_4 ?
Thanks in advance for your assistance
Dean-O
Hi rockie12_us,
You don't need to add the token to the URL. You can use the Data to Session action in the On Submit event of the first form and the Data to Session action in the beginning of the On Load action of the second form. But you do need to use a session key if they are different forms (rather than different pages or events on the same form).
Bob
You don't need to add the token to the URL. You can use the Data to Session action in the On Submit event of the first form and the Data to Session action in the beginning of the On Load action of the second form. But you do need to use a session key if they are different forms (rather than different pages or events on the same form).
Bob
Thanks for your reply
I saw an example were the token was set to {pid} which was a text box I want to do the same thing but use a drop down. What is the syntax for that when wanting to use the selected value of a drop down?
Is there an exmaple using this data to session between to forms?
Also, is there a way to purchase support for this tool?
I saw an example were the token was set to {pid} which was a text box I want to do the same thing but use a drop down. What is the syntax for that when wanting to use the selected value of a drop down?
Is there an exmaple using this data to session between to forms?
Also, is there a way to purchase support for this tool?
Hi rockie12_us,
You can pass the value of a select drop-down in exactly the same way as the value of a text input.
Both Max (the developer) and I do some private paid support for ChronoForms, though most of mine is here in the forums.
Bob
You can pass the value of a select drop-down in exactly the same way as the value of a text input.
Both Max (the developer) and I do some private paid support for ChronoForms, though most of mine is here in the forums.
Bob
Hi Bob
I tried using &a token={selectFieldName} but it did not send the selected vale to the next form. But if I use &token=7 it does
How might we purchase some support? Like 10 phone calls etc to get us over our initial questions like this?
Thanks
Dean-O
WeBenefitAll.com LLC
I tried using &a token={selectFieldName} but it did not send the selected vale to the next form. But if I use &token=7 it does
How might we purchase some support? Like 10 phone calls etc to get us over our initial questions like this?
Thanks
Dean-O
WeBenefitAll.com LLC
How do I use the selected value as the token value in the URL?
Hi rockie12_us,
I've lost track of what you are doing here? Where does the value of selectedFieldName come from?
As I said earlier you don't need to add it to the URL if is data from a previous form - you can pass it using the 'Data to Session' and 'Session to Data' actions.
Bob
I offer support by email or Skype messaging if you need it.
I've lost track of what you are doing here? Where does the value of selectedFieldName come from?
As I said earlier you don't need to add it to the URL if is data from a previous form - you can pass it using the 'Data to Session' and 'Session to Data' actions.
Bob
I offer support by email or Skype messaging if you need it.
I have set up a data to session in form 1 and then in my other form I have a session to data set up, but how do I get the value from the select drop down in the first form to be used as the query where conditional for the second form?
How do I put screen shots in here so you can see my forms and parameters in the forms etc?
Dean-O
How do I put screen shots in here so you can see my forms and parameters in the forms etc?
Dean-O
I got it
So when I go from one form to another, in the second form in the On Load section in the DB Multi Record Loader configuration
set the request parameter to the field name from the previous form
set the DB Field to the field you want to search the database on using the Request Param
and then select the fields if you only want some of the fields brought back
and set you Model ID for this form so you can assign values to form elements
Then you go to your form elements and using the Model ID you can set the values for the element... such as a select box value and text
There might be another way to do this, but this worked for me.
Dean-O
So when I go from one form to another, in the second form in the On Load section in the DB Multi Record Loader configuration
set the request parameter to the field name from the previous form
set the DB Field to the field you want to search the database on using the Request Param
and then select the fields if you only want some of the fields brought back
and set you Model ID for this form so you can assign values to form elements
Then you go to your form elements and using the Model ID you can set the values for the element... such as a select box value and text
There might be another way to do this, but this worked for me.
Dean-O
Hi
Newbie to chronoforms...
I have a form with a select box that it gets its data onload from a database
that works fine
then when the user selects an item and hits submit, I use a redirect user option to have them go to a second page. I have the second page go to the database using the value of the option they selected and then bring back a new list. This works find too.
Then once on the second page, I use a redirect user to send them to the second page and use the value of the selected option and then go to the database to get the new values. Thi is not working, it is always keeping the value of their first item they selected. I am using a redirect user element to have them go to this same page over and over. The debugger from the main page where they select an item
input_select_4 is the item I am using to do the querying
Data Array:
Array
(
[option] => com_chronoforms
[chronoform] => Buttons_Main_Menu
[Itemid] =>
[event] => submit
[input_select_4] => 7
[input_submit_5] => Submit
[b9f1213b373421b1c2ac51bbcacf0206] => 1
)
SELECT `cf_id`, `btn_txt` FROM `sa_content` AS `sa_content` WHERE `parent_id` = '7'
Then when they are on the second page and they select something and hit submit, you can see the value is new for input_select_4 but when the select runs it keeps using the initial value of the input_select_4
Data Array:
Array
(
[option] => com_chronoforms
[chronoform] => next_page
[event] => submit
[Itemid] =>
[input_select_4] => 8
[input_submit_2] => Submit
[b9f1213b373421b1c2ac51bbcacf0206] => 1
)
how do I fix this?
Thanks in advance for your assistance
Dean-O
Newbie to chronoforms...
I have a form with a select box that it gets its data onload from a database
that works fine
then when the user selects an item and hits submit, I use a redirect user option to have them go to a second page. I have the second page go to the database using the value of the option they selected and then bring back a new list. This works find too.
Then once on the second page, I use a redirect user to send them to the second page and use the value of the selected option and then go to the database to get the new values. Thi is not working, it is always keeping the value of their first item they selected. I am using a redirect user element to have them go to this same page over and over. The debugger from the main page where they select an item
input_select_4 is the item I am using to do the querying
Data Array:
Array
(
[option] => com_chronoforms
[chronoform] => Buttons_Main_Menu
[Itemid] =>
[event] => submit
[input_select_4] => 7
[input_submit_5] => Submit
[b9f1213b373421b1c2ac51bbcacf0206] => 1
)
SELECT `cf_id`, `btn_txt` FROM `sa_content` AS `sa_content` WHERE `parent_id` = '7'
Then when they are on the second page and they select something and hit submit, you can see the value is new for input_select_4 but when the select runs it keeps using the initial value of the input_select_4
Data Array:
Array
(
[option] => com_chronoforms
[chronoform] => next_page
[event] => submit
[Itemid] =>
[input_select_4] => 8
[input_submit_2] => Submit
[b9f1213b373421b1c2ac51bbcacf0206] => 1
)
how do I fix this?
Thanks in advance for your assistance
Dean-O
oops on my part forgot to put the session name in the box on the data to session before the redirect user action.
Learning
Dean-O
Learning
Dean-O
This topic is locked and no more replies can be posted.