Hello,
I recently startet to try out chronoforms and already understood a lot. But there are still some questions. I will post them in seperately.
For a prefilled form I tried to get some userdata (e.g. name) from the __users-table. I'm able to do this with custom code in the Code-Tab. The thing is, everytime I want to alter the form design with wizard designer, I have to switch in the Code-Tab, save and enter custom code again. So I tried to to this in the Setup-Tab ... and failed.
Details:
The onload area starts with a Custom Code event, containing: <?php $user =& JFactory::getUser(); ?>
After that I use DB Read. Here I put: Fields: name, Conditions: <?php return array("id" => "$user->id"); ?>
Notice: Undefined variable: user in C:\xampp\htdocs\joomla3\administrator\components\com_chronoforms5\chronoforms\actions\db_read\db_read.php(48) : eval()'d code on line 1
Notice: Trying to get property of non-object in C:\xampp\htdocs\joomla3\administrator\components\com_chronoforms5\chronoforms\actions\db_read\db_read.php(48) : eval()'d code on line 1
Notice: Undefined index: Data in C:\xampp\htdocs\joomla3\administrator\components\com_chronoforms5\chronoforms\actions\db_read\db_read.php on line 71
What have I done wrong?
Moreover, how exactly do I enter the read values in the forms. I've read distinct syntaxes. Is it Data[name] or Data.name? Do I have to put it in curly brackets?
Thanks in advance,
Christian
I recently startet to try out chronoforms and already understood a lot. But there are still some questions. I will post them in seperately.
For a prefilled form I tried to get some userdata (e.g. name) from the __users-table. I'm able to do this with custom code in the Code-Tab. The thing is, everytime I want to alter the form design with wizard designer, I have to switch in the Code-Tab, save and enter custom code again. So I tried to to this in the Setup-Tab ... and failed.
Details:
The onload area starts with a Custom Code event, containing: <?php $user =& JFactory::getUser(); ?>
After that I use DB Read. Here I put: Fields: name, Conditions: <?php return array("id" => "$user->id"); ?>
Notice: Undefined variable: user in C:\xampp\htdocs\joomla3\administrator\components\com_chronoforms5\chronoforms\actions\db_read\db_read.php(48) : eval()'d code on line 1
Notice: Trying to get property of non-object in C:\xampp\htdocs\joomla3\administrator\components\com_chronoforms5\chronoforms\actions\db_read\db_read.php(48) : eval()'d code on line 1
Notice: Undefined index: Data in C:\xampp\htdocs\joomla3\administrator\components\com_chronoforms5\chronoforms\actions\db_read\db_read.php on line 71
What have I done wrong?
Moreover, how exactly do I enter the read values in the forms. I've read distinct syntaxes. Is it Data[name] or Data.name? Do I have to put it in curly brackets?
Thanks in advance,
Christian