View Issue Details

IDProjectCategoryView StatusLast Update
13676Bug reports[All Projects] Theme editorpublic2018-05-25 11:30
ReporterduvemysterAssigned ToLouisGac 
PrioritynoneSeverityminor 
Status closedResolutionfixed 
Product Version3.6.x 
Target VersionFixed in Version 
Summary13676: Saving {{ : }} in a twig file crashes Theme Editor...
Description

Yes, the colon is a syntax error. But in Version 3.7.2+180508, adding this to 1 twig file this results in the 'Theme editor' link for all themes leading to a browser message that the server is redirecting the request for this address in a way that will never complete. Subsequent use of the browser back button leads to the following appropriate limesurvey message: Arguments must be separated by a comma. Unexpected token "punctuation" of value ":" ("punctuation" expected with value ",").

The behavior at demo.limesurvey.org (3.6.3) is a little different/better. Entering something like {{Test:Test}} or {{TOKEN:ATTRIBUTE_1}} there (yes, neither one something that you'd want to enter anyway) leads to inability to re-access the theme editor for that particular extended theme to correct the error.

Steps To Reproduce

Extend a theme, add {{Test:Test}}, then "Copy to local template and save changes".

TagsNo tags attached.
Complete LimeSurvey version number (& build)Version 3.7.2+180508
I will donate to the project if issue is resolvedNo
BrowserFirefox Qantum 60.0 (64-bit)
Database & DB-VersionMaridb with Mysql client api 5.5.58
Operating System (Server)Linux
Webserver software & versionApache 2.0
PHP VersionPHP Version 5.6.30-0+deb8u1

Relationships

related to 13532 closedLouisGac Invalid function in template : Unable to delete or fix it 

Activities

LouisGac

LouisGac

2018-05-16 11:20

manager   ~47600

yes you're right, it should only show an error message in the preview.

olle

olle

2018-05-16 12:12

administrator   ~47613

Resolved?

duvemyster

duvemyster

2018-05-16 18:10

reporter   ~47655

In 3.7.2+180508, 'Copy to local template and save changes' on nav_bar.twig actually changed themes/survey/vanilla/views/subviews/header/nav_bar.twig' rather than saving it to the new theme. That is also occurring in Version 3.7.3+180516.

duvemyster

duvemyster

2018-05-16 18:32

reporter   ~47656

(That may be why all 'Theme editor' links were crashing in 3.7.2+180508, as nav_bar.twig was the file where I had added the {{ : }}. )

LouisGac

LouisGac

2018-05-22 17:15

manager   ~47709

Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=27197

c_schmitz

c_schmitz

2018-05-25 11:30

administrator   ~47822

Version 3.8.1+180524 released

Related Changesets

LimeSurvey: master afb7e325

2018-05-22 17:14:56

LouisGac

Details Diff
Fixed issue 13676: Saving {{ : }} in a twig file crashes Theme Editor...
mod - application/controllers/admin/themes.php Diff File

Issue History

Date Modified Username Field Change
2018-05-16 02:35 duvemyster New Issue
2018-05-16 10:36 olle Assigned To => LouisGac
2018-05-16 10:36 olle Status new => assigned
2018-05-16 11:20 LouisGac Note Added: 47600
2018-05-16 12:12 olle Note Added: 47613
2018-05-16 13:20 LouisGac Relationship added related to 13532
2018-05-16 18:10 duvemyster Note Added: 47655
2018-05-16 18:32 duvemyster Note Added: 47656
2018-05-22 16:55 LouisGac Sticky Issue No => Yes
2018-05-22 17:15 LouisGac Changeset attached => LimeSurvey master afb7e325
2018-05-22 17:15 LouisGac Note Added: 47709
2018-05-22 17:15 LouisGac Resolution open => fixed
2018-05-22 17:16 LouisGac Sticky Issue Yes => No
2018-05-22 17:35 LouisGac Status assigned => resolved
2018-05-25 11:30 c_schmitz Note Added: 47822
2018-05-25 11:30 c_schmitz Status resolved => closed