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 246931 - Problems with JS formatting with smaty code in non-tpl file
Summary: Problems with JS formatting with smaty code in non-tpl file
Status: REOPENED
Alias: None
Product: php
Classification: Unclassified
Component: Smarty (show other bugs)
Version: 8.0
Hardware: PC Windows 7
: P3 normal (vote)
Assignee: Martin Fousek
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-09-09 02:52 UTC by m1509001
Modified: 2016-08-29 06:06 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
IDE 日志 (677.94 KB, text/plain)
2014-09-09 02:52 UTC, m1509001
Details
sample file from reporter (863 bytes, text/plain)
2014-09-22 14:52 UTC, Vladimir Riha
Details
screenshot (93.89 KB, image/png)
2014-09-22 14:53 UTC, Vladimir Riha
Details

Note You need to log in before you can comment on or make changes to this bug.
Description m1509001 2014-09-09 02:52:09 UTC
Product Version = NetBeans IDE 8.0 (Build 201403101706)
Operating System = Windows 7 version 6.1 running on x86
Java; VM; Vendor = 1.8.0_05
Runtime = Java HotSpot(TM) Client VM 25.5-b02
Comment 1 m1509001 2014-09-09 02:52:26 UTC
Created attachment 149075 [details]
IDE 日志
Comment 2 Vladimir Riha 2014-09-09 06:58:10 UTC
Could you please report in English? Based on translator, it seems you have a problem with jQuery formatting. Could you please attach sample file to reproduce the issue and step by step instruction to see what is wrong? It is hard to identify the problem without these information. Simply reopen the issue then.


Thank you in advance
Comment 3 Vladimir Riha 2014-09-22 14:52:04 UTC
Created attachment 149421 [details]
sample file from reporter

Here's a simplified sample file from reporter. The problem is JavaScript code contains {#$maxnum#} - some framework directive.

Based on the screenshot from reporter (to be attached), the HTML file extension is set to be treated as text/x-tpl mimetype. The directive is similar to Smarty framework so if one:
 - sets HTML to be treated as text/x-tpl
 - sets Smarty delimiters to {# and #}
 => the {#$maxnum#} is correctly highlighted but formatting still fails. It works in tpl file though. 

Reassigning to Smarty for further evaluation (please reassign back if I'm wrong). Thank you
Comment 4 Vladimir Riha 2014-09-22 14:53:56 UTC
Created attachment 149423 [details]
screenshot