Hello,
I have a form (form A) with a redirect (to form B). In the extra parameters of the redirect I have the following:
In form B I have a db read with the following condition:
I also have another db read with the following condition:
Yet I get a warning for the second db read and not the first as seen in the picture:
[attachment=0]Illegal string 1.jpg[/attachment]
I noticed that the $_GET statement is sending the "site" as a string. I've tried casting the variable using the following in the db reader:
but I get the same warning.
Why am I getting this? Is there anyway to correct this besides turning my site Error Reporting down from Simple to None?
Thanks for your help,
Chris
I have a form (form A) with a redirect (to form B). In the extra parameters of the redirect I have the following:
region=location.region
site=location.site
In form B I have a db read with the following condition:
<?php
return array('regions.region_id' => $_GET["region"]);
?>
I also have another db read with the following condition:
<?php
return array('site.site_id' => $_GET["site"]);
?>
Yet I get a warning for the second db read and not the first as seen in the picture:
[attachment=0]Illegal string 1.jpg[/attachment]
I noticed that the $_GET statement is sending the "site" as a string. I've tried casting the variable using the following in the db reader:
<?php
return array('site.site_id' => (int)$_GET["site"]);
?>
but I get the same warning.
Why am I getting this? Is there anyway to correct this besides turning my site Error Reporting down from Simple to None?
Thanks for your help,
Chris
Hi Chris,
First, you don't need to do a ReDirect between forms including the data. If you use Data to Session and Session to Data actions with a Session Key ChronoForms will do that part for you.
Second in the structure here 'site' is ending up as an array so it would be $_GET['site'][0]['site_id'], or better $form->data['site'][0]['site_id']
Bob
First, you don't need to do a ReDirect between forms including the data. If you use Data to Session and Session to Data actions with a Session Key ChronoForms will do that part for you.
Second in the structure here 'site' is ending up as an array so it would be $_GET['site'][0]['site_id'], or better $form->data['site'][0]['site_id']
Bob
This topic is locked and no more replies can be posted.