I have several cases where {TOKEN} is not being passed to the endurl for a survey. Here's the endurl:
Code:
https://mywebsite.com/rpt.php?token={TOKEN}&code={code}
Email template, basic admin notification:
Code:
Hello,
A new response was submitted for your survey '{SURVEYNAME}'.
Link to report: https://mywebsite.com/rpt.php?token={TOKEN}&code={code}
Possibly token: {TOKEN: TOKEN}
Click the following link to see the individual response:
{VIEWRESPONSEURL}
And the email generated to me:
Code:
A new response was submitted for your survey 'Church Life Cycle'.
Link to report: https://mywebsite/rpt.php?token=&code=clc11
Possibly token:
Click the following link to see the individual response:
https://mywebsite.com/app/s/index.php/admin/responses/sa/view/surveyid/178587/id/256
This means the endurl for the user was:
Code:
https://mywebsite/rpt.php?token=&code=clc11
My rpt.php file requires the token parameter, as you might expect. When it's empty, rpt.php redirects the participant to an error form to notify me of the issue.
Now I know why some have been complaining.
The extremely odd thing about this issue is I use the same pattern on several surveys (about 20). The {TOKEN} has not failed before.
Looking at the individual response from {VIEWRESPONSEURL}, [token] appears twice:
- [token] Token ID TW1912081575783506HhqYjq
- [submitdate] Submission date 12-07-2019 16:48:33
- Completed Y
- [id] Response ID 256
- [startlanguage] Start language en
- [seed] Seed 902380868
- [token] Token TW1912081575783506HhqYjq
I took the survey myself to see what the confirmation email rendered. Here's some good news. The confirmation email includes the correct link. Here's the line in the email template:
Code:
You can view your individual results here: https://mywebsite.com/rpt.php?token={TOKEN}&code={code}
And here's how the email looks:
Code:
You can view your individual results here: https://mywebsite.com/rpt.php?token=TW1912081575803450LqkPuR&code=demo
However, as before, the endurl was not correctly rendered. The {TOKEN} is not inserted, even though it's obviously there in the confirmation email.
Any thoughts for my next round of debugging?
Many thanks.