Welcome, Guest
Username: Password: Remember me

TOPIC: Can't add javascript to a question

Can't add javascript to a question 2 years 3 months ago #78918

  • asklepio
  • asklepio's Avatar
  • OFFLINE
  • Fresh Lemon
  • Posts: 19
  • Karma: 0
Hi,

I'm a newbie, and i want add javascript code to a question I created.
so i added this under "source"
Question...
<script type="text/javascript" charset="utf-8">

alert("Test!");

</script>

I saved it and when i edit de question again, this is what i get:
Question... <sc<x>ript type="text/javascript" charset="utf-8"> alert("Test!"); </sc<x>
and the javascript is not working..

Did i forget anything before adding javascript?
thanks!
The administrator has disabled public write access.

Re: Can't add javascript to a question 2 years 3 months ago #78920

  • Ben_V
  • Ben_V's Avatar
  • OFFLINE
  • Platinum Lime
  • Posts: 1061
  • Thank you received: 234
  • Karma: 74
Set the 'Filter HTML for XSS' option to 'no'
Path: Global Settings > SECURITY > Filter HTML for XSS

Ben/
Benoît

goo.gl/Bw5iM => Recherche GG dans le forum français (remplacer "exemple" dans la barre de recherche)
goo.gl/WX8PH => GG search for english forum (Replace "example" in the search bar)
goo.gl/IxiGu => Búsqueda en el foro en español (Cambiar "ejemplo" en la barra de...
The administrator has disabled public write access.
The following user(s) said Thank You: DenisChenu, asklepio

Re: Can't add javascript to a question 2 years 3 months ago #78930

  • Mazi
  • Mazi's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 5301
  • Thank you received: 291
  • Karma: 247
For more information on how to add Javascript to a survey, have a look at the blog post on www.limesurvey-consulting.com:
How to use JavaScript at a Limesurvey template or survey

Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)limesurvey.org'"
The administrator has disabled public write access.
Moderators: ITEd
Time to create page: 0.110 seconds
Donation Image