Hi MainsailSoftware,
Please try this with v5:
{chronoforms5}form_name&activity=XYZ{/chronoforms5}
Now a field named "activity" in your form should have the XYZ value set.
Regards,
Max
Max
ChronoForms developer...
Did you try ChronoMyAdmin for managing your Joomla database tables ?
Thanks Max,
I tried
{chronoforms5}Activity&activity_id=XYZ{/chronoforms5}
and the following is what is seen using the Debug action.
Array
(
[Activity] =>
[amp;activity_id] => XYZ
)
It working, but not as I expected... Any suggestions?
I also tried
{chronoforms5}Activity&activity_id=XYZ&member_name=Name{/chronoforms5}
and got
Array
(
[Activity] =>
[amp;activity_id] => XYZ
[amp;member_name] => Name
)
I think that your text editor in the article has replaced the "&" by "&", please disable the editor and fix this then save and retry!
Regards,
Max
Max
ChronoForms developer...
Did you try ChronoMyAdmin for managing your Joomla database tables ?
Hummm...
I am using Chrome browser and the latest Joomla! admin JCE editor...
I will try looking into what exactly is being generated and get back to you.
Looking at what the JCE editor is producing, you are exactly correct! If I Toggle the editor to show the generated html, I get...
<p>{chronoforms5}Activity&activity_id=XYZ{/chronoforms5}</p>
I had to save the article with the JCE editor in Toggled to the html view. If you toggle back, it changes back to &.
I tried my code with this article plugin reference and change my data reference from amp;activity_id to activity_id and it works perfectly.
This is an editor issue as you suggest, but I would think most Joomla! admins will use the built-in content editing tools.
Perhaps you might consider allowing other separators in addition to &, such as $ or ? or colon or semi-colon or comma?
For now I can keep this issue in mind and perform direct HTML editing of the plugin reference before saving.
Thanks, I added a fix for that!
Regards,
Max
Max
ChronoForms developer...
Did you try ChronoMyAdmin for managing your Joomla database tables ?
Thanks Max...
Perfect Bob!
First, I want to say how great you guys provide support for your product! I am really happy that I purchased Chronoforms!
Bob, I made the change you suggested and that fixed the DB Save issue, but after I changed the Article back so that the JCE editor once again produced <p>{chronoforms5}Activity&activity_id=XYZ{/chronoforms5}</p> in the saved HTML, another error appeared.
The form I created initially does a DB Read to make sure the participant has not already registered for the Activity. As part of the conditions for the DB Read I have this snippet of PHP code:
<?php return array( 'activity_id' => $form->data['activity_id']); ?>
The error that appears on the frontend is as follows:
Notice: Undefined index: activity_id in /hsphere/local/home/a965916/mbiyc.com/joomla/administrator/components/com_chronoforms5/chronoforms/actions/db_read/db_read.php(67) : eval()'d code on line 4
Debut show:
Array
(
[Activity] =>
[amp;activity_id] => XYZ
)
I have look at the code in the admin component indicated at line 67. I guess I could hack something there, but I am not so sure I would be correcting the code in the right location. If I go back to making sure the saved Article HTML does not convert & to &, everything works correctly.
So, it appears that a fix to some other location in the code maybe needed. I will leave it up to you two to tell me how to proceed.
Jim
Sorry Guys.... Please ignore my previous 2 posts... The change you recommended worked fine.
Evidently, when I FileZilla'ed the new plugin code up to the server, it did not initially take... I assume a Caching issue.
I also modified your debug action to include pr($form->actions_config) so I can see what the action is getting...
Again, thanks to the both of you for a great job with support and the components you have developed!
Jim
Hi Jim,
Great, no problems!🙂
btw, no need to hack the debugger action, just use your code inside a "custom code" atcion:
<?php
pr($form);
Regards,
Max
Max
ChronoForms developer...
Did you try ChronoMyAdmin for managing your Joomla database tables ?
Dah!... I should have thought of that! But I was in coding mode in my local NetBeans editor.
Thanks again... love working with you guys!
Jim