4 lines of php which used to work with Chronoform 5 but does not with Chronoform 8.

certi 15 Dec, 2023
Dear Max,

This is certainly a lack of PHP knowledge on my side, but I really need your help.
I purchase the new Chronoform 8 and, also a 30 days elastic to work on my dev website domain.
I also post a positive review on Joomla.

This is the code

$input = new \Joomla\Input\Input;
$habitation = $input->get('dropdown1', '', 'POST');
print "Name: $habitation";
$form->data['text6'] = $habitation;

I am getting this error

Attempt to modify property "data" on null

Could you please tell me what I am doing wrong?

Thank you very much for your help

Sylvain
david3482 16 Dec, 2023
Answer
1 Likes
It looks like $form->data changed to $this->data back in CFv6.

See https://www.chronoengine.com/forums/topics/view/103626/chronforms-v6-form-data

Instead of
$form->data['text6']

Try
$this->data['text6']
certi 18 Dec, 2023
Thank you very much David, it is working now :-)

I have a new issue... the form is perfectly working on the preview, but I am getting a "Your session has timed out or your tried to access a wrong page." On the front-page website.

It is happening only if I am using the form more than once.
Must be about the loops... it was easier on the version 5 of Chronoform! :-/

Thank you again of helping me, I would never find alone.

Sylvain
You need to login to be able to post a reply.

VPS & Email Hosting 20% discount
hostinger