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 207296 - JDOC:INCLUDE tag parsing (joomla template)
Summary: JDOC:INCLUDE tag parsing (joomla template)
Status: RESOLVED WORKSFORME
Alias: None
Product: web
Classification: Unclassified
Component: HTML Editor (show other bugs)
Version: 7.0.1
Hardware: All All
: P3 normal (vote)
Assignee: Marek Fukala
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-01-13 18:45 UTC by malkowitch
Modified: 2012-04-19 21:11 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Primary file for default Joomla! template (13.80 KB, text/plain)
2012-01-19 04:05 UTC, hobbespdx
Details

Note You need to log in before you can comment on or make changes to this bug.
Description malkowitch 2012-01-13 18:45:40 UTC
Product Version = NetBeans IDE 7.0.1 (Build 201107282000)
Operating System = Windows 7 version 6.1 running on x86
Java; VM; Vendor = 1.6.0_29
Runtime = Java HotSpot(TM) Client VM 20.4-b02

I love NetBeans and use it as PHP IDE for years. One things makes me crazy for a long time.
Joomla! php CMS uses its own xml element in templates. It's called <jdoc:include /> and can be placed anywhere in code also in HEAD section.
It can take atributes like type,name, style and some custom. 
First problem is that NetBeans ton recognize this tag and report error.
Second is with STYLE atrribute in this tag. Netbeans takes it as html style attribute so it is parsed as CSS code.
But it contains words.

Possible solutions:
- parse tags with ":" in name as custom XML elements and ignore attributes contents
- give possibility to add custom tags to HTML/XHTML parser (its attributes should not be parsed)
Comment 1 Tomas Mysik 2012-01-18 10:45:40 UTC
HTML area, please evaluate.

Thanks.
Comment 2 Marek Fukala 2012-01-18 11:15:08 UTC
please add a sample file.
Comment 3 hobbespdx 2012-01-19 04:05:25 UTC
Created attachment 115058 [details]
Primary file for default Joomla! template

File can be found in the J! trunk, at;

http://joomlacode.org/gf/project/joomla/scmsvn/?action=browse&path=%2F%2Acheckout%2A%2Fdevelopment%2Ftrunk%2Ftemplates%2Fbeez_20%2Findex.php
Comment 4 hobbespdx 2012-01-19 04:06:30 UTC
An example XML tag;
<jdoc:include type="modules" name="position-4" style="beezHide" headerLevel="3" state="0" id="3" />
Comment 5 Marek Fukala 2012-04-19 09:32:39 UTC
html code validation is disabled in php files by default since in most cases it simply cannot work. The attached file is completely free of any errors (green status). Can you please verify in latest dev builds? 

(please doublecheck if the html error checking is disabled - hint at the very first line, if not just disable it for php files or this particular file)
Comment 6 hobbespdx 2012-04-19 20:28:34 UTC
Using NB 7.1.1; (unable to use latest dev builds)
HTML error checking *was* disabled by default.

When enabled, the <jdoc:include /> tags are providing the following error;

The prefix 'jdoc' for element 'jdoc:include' is not bound.
Rule Category: All Other




I think this issue is not important, FWIW.
Comment 7 Marek Fukala 2012-04-19 21:11:26 UTC
OK If you have the possibility please download from

http://bits.netbeans.org/download/trunk/nightly/latest/

and let me know. 

I'll keep the issue closed meanwhile. As I said there's no error in the file in the dev build.