• 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!

TOPIC: Form and submission ID to be included in email

Form and submission ID to be included in email 14 years 10 months ago #7717

  • Kaladar
  • Kaladar's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 3
Am using RS forms to make a simple order of service form, and would like users to confirm their request by a link in email, so I need the submissionID which will be inserted in the DB table for the request to be included in the email.

Am I overlooking some easy feature to include the submissionID or is this a bit tougher? B)
Last Edit: 14 years 10 months ago by Kaladar. Reason: better suitable title...
The topic has been locked.

Re:Confirmation link in email 14 years 10 months ago #7718

  • Kaladar
  • Kaladar's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 3
I tried adding this code as a default value in a hidden field.
//<code>
return intval
(@mysql_result(mysql_query("SELECT *
FROM ".$RSadapter->tbl_rsform_submissions." 
ORDER BY `SubmissionId` DESC LIMIT 1"),0)+1);
//</code>


But that doesn't solve the problem as two or more users could be filling the form at the same time and thus would get the same id number.
Fetching the id number has to happen after user presses submit..:dry:
Last Edit: 14 years 10 months ago by Kaladar.
The topic has been locked.

Re:Confirmation link in email 14 years 10 months ago #7726

  • Kaladar
  • Kaladar's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 3
Just to let others know...

I found a solution, a bit of a hax tbh, but it gets the job done :silly:

I edited the mail function in adaptor.php, to filter messages being sent with some special symbols (e.g. "#$$$#" ) in front of the subject.

So before sending the email I could filter which form was trying to send the mail and make a database lookup for the submissionID and append it to the $body of the mail with appropriate info.

This way I ensure that each mail gets a correctly indexed confirmation link... :P
Last Edit: 14 years 10 months ago by Kaladar. Reason: typo fix...
The topic has been locked.
  • 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!