Forums

Pass Session Variable from CCv6 to CFv6

omidhz 15 Jul, 2017
I am trying to create a edit link in CC to edit my data in CF form. Here is what I have so far, but I don't know how to make the connection properly.

Form1 in CFv6 reads my database table using the following WHERE condition:
model1.id:{session:create_answer.answer_ID}

If it finds the data, then it uses the following data provider in form display.
{var:read_data11.model1}
.

I have a CCv6 Table view that lists all data from the same database table, and I added a column called Edit that is linked to Form1 in CFv6 via a form view element in CCv6.

What I'm trying to do is to pass the same session {session:create_answer.answer_ID} information from CC to CF for my form to work properly.

Thanks in advance.
Max_admin 15 Jul, 2017
1 Likes
Hi omidhz,

You do not need to store the id in the session, you pass this in the url to the form, and you should call the form "section" in the form view in connectivity, or ignore the edit event altogether in connectivity and load the data in chronoforms.

Best regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
omidhz 15 Jul, 2017

ignore the edit event altogether in connectivity and load the data in chronoforms


I like this option, but how can I pass the WHERE condition from CC to CF?
If I add the ID in the URL, then people can manually change the URL and edit other records. That's why I was looking for another option.
Max_admin 16 Jul, 2017
Hi omid,

You must pass the id in the url in any case, if you want to permit users to edit specific records then you will need to use the permissions settings and provide an "owner id" per record.

Best regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
omidhz 16 Jul, 2017
Max,
Thank you for your reply.
Let me see if I can figure out how to setup the switch to check for owner ID.
This topic is locked and no more replies can be posted.