Check out the LimeSurvey source code on GitHub!
Welcome, Guest
Username: Password:

TOPIC: Include participant's TOKEN into the Print Answers Page-Template

Include participant's TOKEN into the Print Answers Page-Template 5 years 5 months ago #62371

  • encyency
  • encyency's Avatar
  • Offline
  • Fresh Lemon
  • Posts: 2
  • Karma: 0
Hi,

thank you for developing such a great tool!

Question:

I would like to include the participant's token into the answers-print-out page. I already managed to include things like {TOKEN:LASTNAME} and {TOKEN:EMAIL} into the printanswers.pstpl (right before {ANSWERTABLE}), but cannot manage to include {TOKEN}. Obviously the software needs to know which token I would like to print out. I don’t know how to do that.

Is there a possibility to change the {ANSWERTABLE} content? Where?

Thank you for your time!
Attachments:
The administrator has disabled public write access.

Include participant's TOKEN into the Print Answers Page-Template 5 years 5 months ago #62424

  • Ben_V
  • Ben_V's Avatar
  • Offline
  • Platinum Lime
  • Posts: 1894
  • Thank you received: 467
  • Karma: 118
I really hope that you 'll get a better answer, but if not (and token ID absolutly necessary for you) you can install and use LS 1.87, because the token ID is natively included into the {ANSWERTABLE}...
The big problem: you won't import a .lss saved survey if already made with LS +1.90 !

Benoît

EM Variables => bit.ly/1TKQyNu | EM Roadmap => bit.ly/1UTrOB4
All LS releases => bit.ly/1VMuTDu | 2.06lts => bit.ly/1Qv44A1
Demo surveys => goo.gl/HuR6Xe (already included in /docs/demosurveys)
Last Edit: 5 years 5 months ago by Ben_V.
The administrator has disabled public write access.

Aw: Include participant's TOKEN into the Print Answers Page-Template 5 years 5 months ago #62441

  • encyency
  • encyency's Avatar
  • Offline
  • Fresh Lemon
  • Posts: 2
  • Karma: 0
@benitov Thank you very much for your suggestion!

I kind of stumbeled over the right solution! Here it goes:

If you would like TOKEN displayed in the print-answers-output you'll need to make some changes inside the printanswers.php. You'll find it in the root directory of your limesurvey installation.

1. backup your "printanswers.php"
2. open "printanswers.php" in the root directory
3. search for "TOKEN"
4. delete entry "unset ($fnames);"
5. save

That's it!

Thanks everyone for reading and trying to help!
Last Edit: 5 years 5 months ago by encyency.
The administrator has disabled public write access.

Aw: Include participant's TOKEN into the Print Answers Page-Template 5 years 5 months ago #62443

  • Ben_V
  • Ben_V's Avatar
  • Offline
  • Platinum Lime
  • Posts: 1894
  • Thank you received: 467
  • Karma: 118
The best way: to ask and to search by yourself in the same time.
Thanks a lot to share this because it's an important thing to know and sure i'll use it soon.
Ben
Benoît

EM Variables => bit.ly/1TKQyNu | EM Roadmap => bit.ly/1UTrOB4
All LS releases => bit.ly/1VMuTDu | 2.06lts => bit.ly/1Qv44A1
Demo surveys => goo.gl/HuR6Xe (already included in /docs/demosurveys)
The administrator has disabled public write access.
Time to create page: 0.568 seconds
Imprint                   Privacy policy         General Terms & Conditions         Revocation information and revocation form