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

TOPIC: Adding new pstpl template file.

Adding new pstpl template file. 3 years 5 months ago #96934

  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Team
  • Posts: 6570
  • Thank you received: 1477
  • Karma: 579
I don't think you need to go to those lengths to have survey-specific banners.

Place the two banner graphics in your template directory and name them something like banner-28836.png and banner-69731.png.

Then you should be able to use something like this in startpage.pstpl:
<img class="banner" src="{TEMPLATEURL}banner-{SID}.png" />

If you need a default banner, you can use jQuery to modify the src attribute of the image tag.
Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Last Edit: 3 years 5 months ago by tpartner.
The administrator has disabled public write access.

Adding new pstpl template file. 3 years 5 months ago #96936

  • joss
  • joss's Avatar
  • Offline
  • Fresh Lemon
  • Posts: 16
  • Karma: 0
Thanks! It was super easy!
The default banner in the example is banner-.png which is again working.
The administrator has disabled public write access.

Adding new pstpl template file. 3 years 5 months ago #96938

  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Team
  • Posts: 6570
  • Thank you received: 1477
  • Karma: 579
The default banner in the example is banner-.png which is again working.
Even easier than JavaScript :cheer:
Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The administrator has disabled public write access.
Time to create page: 0.452 seconds
Imprint                   Privacy policy         General Terms & Conditions         Revocation information and revocation form