autopopulate based on cf_id

marklandry 13 Oct, 2010
Hi,
I need to provide a link to forms that have already been partially populated

Basically, the user will enter the info into the form and "on submit" a link needs to be generated/posted that would pull up the form, autopopulated with the info associated with the cf_id of that particular entry.

I know that I can (with some sweat for a noob) create some "on submit" php code that would populate a db column with something like "http://mysite/forms/myform+cf_id" then call that column's content using chronoconnectivity, but was wondering if I could get some help with the "on submit" code.

Once that link is clicked, is there a way to communicate the cf_id to the form so it knows what to pull up?

Does that make sense?

Thanx a ton for your help

If this is in the book I'm buying it asap...

Mark
GreyHead 13 Oct, 2010
Hi Mark,

It's in the book starting on page 297.

It's also in the latest ChronoConnectivity How-To document here which describes how to link from a ChronoConnectivity listing to view some details in a ChronoForm.

Bob
marklandry 13 Oct, 2010
thanx bob,
Buying the book now...
Mark
marklandry 13 Oct, 2010
Just got the book and looking at the table of contents - exciting! I know what I'm doing the rest of the day. Please don't try to call as I'll be busy....🙂
marklandry 13 Oct, 2010
Hi Bob,

Could you help/point me in the right direction regarding dynamically populating a db table with a link at "on submit" I can connect the form to a db, retrieve the info, etc., just don't know the php to 1) generate the link and 2) add an increment of "1" to end of it, like so:

?option=com_chronocontact&chronoformname=test_form_56&cf_id=[add 1 to the last entry]
marklandry 15 Oct, 2010
getting closer.... (assuming what's below will work....)

mysql_query("INSERT INTO database 
(table) VALUES('?option=com_chronocontact&chronoformname=test_form_56&cf_id=[add 1 to the last entry]' ) ") 
or die(mysql_error());


working on dynamically increasing the id # each time this is inserted into the db...
GreyHead 15 Oct, 2010
Hi Mark,

I'm lost, why do you need to add 1 to the cf_id? I don't understand what youa re trying to do here :-(

Bob
This topic is locked and no more replies can be posted.