View Issue Details

This issue affects 1 person(s).
 4
IDProjectCategoryView StatusLast Update
06560Bug reportsData Entry (non public)public2012-09-18 08:27
Reporteruser21791Assigned Toc_schmitz  
PriorityhighSeveritytweak 
Status closedResolutionno change required 
Product Version1.92+ 
Summary06560: Question code within
 is parsed and changed
Description

I am in need to input C/C++ source code in my surveys.

I tried both the HTML editor in source mode and the simple textbox, but all the code I input between

 and 
tags is parsed and "corrected".

For example I cannot write #include <iostream> because it is interpreted as a tag, so it is not displayed and the closing tag is also inserted. So I have to replace it with #include < iostream >, which is wrong.

Same goes for special entities such as < or >.

Steps To Reproduce

Enter the following in the editor


#include <iostream>

TagsNo tags attached.
Bug heat4
Complete LimeSurvey version number (& build)120909
I will donate to the project if issue is resolvedNo
Browser
Database type & versionMySQL 5.5.25a
Server OS (if known)Win 7
Webserver software & version (if known)XAMPP
PHP Version5.4.4
Git branch / Pull Request URL

Users monitoring this issue

There are no users monitoring this issue.

Activities

user21791

2012-09-17 20:20

  ~20716

I am talking about pre-formatted sections in HTML. Funny enough the pre tags seem to work here too, so they have been "cut out" from the subject and desription.

c_schmitz

c_schmitz

2012-09-17 22:42

administrator   ~20717

I am not sure how this is a bug? Just insert it in HTML WYSIWYG editor mode (not in source) and it will be correctly parsed.

user21791

2012-09-18 02:33

  ~20718

Last edited: 2012-09-18 03:53

I am sorry, but I have tried any editor configuration, both the HTML editor in source mode and no editor at all, and the problem persists.

Non-source mode is a no go because I need the code to stand out. Source within pre tags is usually displayed using monospaced fonts, which is what I need, and it is also the only option available since the editor does not allow to change fonts (at least not on my configuration).

I also apologize for the first reply that was quite harsh, hence the edit.

user21791

2012-09-18 03:58

  ~20719

Ok, found a temporary solution. Using the HTML editor

1) Add pre tags in source code mode
2) Revert to HTML edit mode and insert code, which will then be encoded for display

Its annoying but I guess I can live with it.
A font selection tool would be nice, or IMHO the editor needs some reworking to allow the correct use of pre tags.

c_schmitz

c_schmitz

2012-09-18 08:27

administrator   ~20720

If you use the full-screen version of the editor (left most button in the toolbar) you have the option to select the style 'formatted' in the format box which will put (pre) tags as intended without the need to enter source code mode.

Issue History

Date Modified Username Field Change
2012-09-17 20:17 user21791 New Issue
2012-09-17 20:20 user21791 Note Added: 20716
2012-09-17 22:42 c_schmitz Note Added: 20717
2012-09-17 22:42 c_schmitz Assigned To => c_schmitz
2012-09-17 22:42 c_schmitz Status new => feedback
2012-09-17 23:32 c_schmitz Status feedback => closed
2012-09-17 23:32 c_schmitz Resolution open => no change required
2012-09-18 02:33 user21791 Note Added: 20718
2012-09-18 02:33 user21791 Status closed => feedback
2012-09-18 02:33 user21791 Resolution no change required => reopened
2012-09-18 02:39 user21791 Note Edited: 20718
2012-09-18 02:39 user21791 Note Edited: 20718
2012-09-18 03:53 user21791 Note Edited: 20718
2012-09-18 03:58 user21791 Note Added: 20719
2012-09-18 03:58 user21791 Status feedback => assigned
2012-09-18 08:27 c_schmitz Note Added: 20720
2012-09-18 08:27 c_schmitz Status assigned => closed
2012-09-18 08:27 c_schmitz Resolution reopened => no change required