View Issue Details

This bug affects 1 person(s).
 6
IDProjectCategoryView StatusLast Update
18219Bug reportsQuestion editorpublic2022-06-30 12:09
Reporterzufolo441 Assigned ToDenisChenu  
PrioritynoneSeveritypartial_block 
Status closedResolutionfixed 
Product Version5.3.x 
Summary18219: unable to insert code in question
Description

Hi, in 5.3.22, when I try to edit a script in question caption and I save, text is devastated.
example:
Fase. Indicazioni operative
<script type="text/javascript" charset="utf-8">
$(document).ready(function(){
if ((''{tipo}'' !== ''1'') && (getSessParameter(''comune'') !==''1'')) {
$(''#question{QID} input[type = "radio"]'').attr("disabled", true);
}
});
</script>

after saving it becomes:

Fase. Indicazioni operative {tipo}'' !== ''1'') && (getSessParameter(''comune'') !==''1'')) { $(''#question{QID} input[type = "radio"]'').attr("disabled", true); } });

Steps To Reproduce

edit a question with a script and save.

TagsNo tags attached.
Bug heat6
Complete LimeSurvey version number (& build)5.3.22
I will donate to the project if issue is resolvedNo
BrowserFirefox 101
Database type & versionPostgresql 13
Server OS (if known)FreeBSD 13.1
Webserver software & version (if known)Nginx + php-fpm
PHP Version8.0

Users monitoring this issue

There are no users monitoring this issue.

Activities

zufolo441

zufolo441

2022-06-28 14:52

reporter   ~70585

source code becomes:
<p>Fase. Indicazioni operative {tipo}'' !== ''1'') && (getSessParameter(''comune'') !==''1'')) { $(''#question{QID} input[type = "radio"]'').attr("disabled", true); } });</p>

<p> </p>

duvemyster

duvemyster

2022-06-30 03:09

reporter   ~70618

In Global Settings on the General tab, try changing the Default HTML Editor mode to "Popup" or "HTML source".

zufolo441

zufolo441

2022-06-30 08:47

reporter   ~70619

thanks, it solved!

DenisChenu

DenisChenu

2022-06-30 12:09

developer   ~70625

Usage of HTML editor

Issue History

Date Modified Username Field Change
2022-06-28 14:51 zufolo441 New Issue
2022-06-28 14:52 zufolo441 Note Added: 70585
2022-06-28 14:52 zufolo441 Bug heat 0 => 2
2022-06-30 03:09 duvemyster Note Added: 70618
2022-06-30 03:09 duvemyster Bug heat 2 => 4
2022-06-30 08:47 zufolo441 Note Added: 70619
2022-06-30 12:09 DenisChenu Assigned To => DenisChenu
2022-06-30 12:09 DenisChenu Status new => closed
2022-06-30 12:09 DenisChenu Resolution open => fixed
2022-06-30 12:09 DenisChenu Note Added: 70625
2022-06-30 12:09 DenisChenu Bug heat 4 => 6