This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 268891 - New Line Stops Working when a TWIG variable is present in a SCRIPT Tag
Summary: New Line Stops Working when a TWIG variable is present in a SCRIPT Tag
Status: NEW
Alias: None
Product: php
Classification: Unclassified
Component: Twig (show other bugs)
Version: 8.2
Hardware: PC Windows 10 x64
: P3 normal (vote)
Assignee: Tomas Mysik
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-11-08 11:02 UTC by berridgeab
Modified: 2016-11-08 11:02 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Contains HTML to reproduce bug (75 bytes, application/octet-stream)
2016-11-08 11:02 UTC, berridgeab
Details

Note You need to log in before you can comment on or make changes to this bug.
Description berridgeab 2016-11-08 11:02:21 UTC
Created attachment 162823 [details]
Contains HTML to reproduce bug

Hi,

Problem - 

A newline, created by the return key, doesn't seem to work.

To reproduce - 

I use inline HTML templates on my website, stored in between <script></script> tags.

If you open the attached script in NetBeans, you will see that the HTML in between the <script> tag is blacked out text. The HTML also contains a TWIG template variable.

Position the cursor after the closing script tag, and press return, a new line should be created, as expected.

Now, position the cursor within the script tag, and press return. The text will turn blue (I guess NetBeans is parsing the contents), but no new line is created.

Other Notes - 

Affects .twig and .php file types.
.html file type is not affected.
If you remove the TWIG variable within the template, the issue goes away.

Seems like NetBeans doesn't like the presence of TWIG variables within a <script> tag.