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 120381 - Broken HTML end tag CC with embeded scriplet
Summary: Broken HTML end tag CC with embeded scriplet
Status: VERIFIED FIXED
Alias: None
Product: javaee
Classification: Unclassified
Component: JSP (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Marek Fukala
URL:
Keywords:
: 121044 121333 (view as bug list)
Depends on: 121046
Blocks:
  Show dependency tree
 
Reported: 2007-10-29 17:10 UTC by Martin Schovanek
Modified: 2008-09-08 16:51 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Schovanek 2007-10-29 17:10:49 UTC
[#200710281200, jdk1.5.0]

to reproduce:
-------------
1) have a .jsp like:
    <html><body>
    <h3>
    <%= "Hello"%>
    </|
    </body></html>
NOTE: | represents cursor
2) invoke CC
ERROR: CC offers only </html> end tag instead of </h3> (CC ideally should offer only the </h3>)
Comment 1 Jindrich Sedek 2007-11-02 09:25:31 UTC
bracket matching also doesn't work over scriptlet sections:
use this code:
-----------------
    <table> 
    <% %> 
    </ta|ble> 
----------------
set cursor possition at place of "|" -> start <table> tag is no highlighted and it's not possible to jump between start 
and end tag using Ctrl + [
Comment 2 Marek Fukala 2007-11-03 09:48:00 UTC
*** Issue 121044 has been marked as a duplicate of this issue. ***
Comment 3 Marek Fukala 2007-11-04 17:40:12 UTC
reoroducible, it's a cause of issue #121046
Comment 4 Marek Fukala 2007-11-07 20:54:33 UTC
*** Issue 121333 has been marked as a duplicate of this issue. ***
Comment 5 lvw 2007-12-05 08:17:29 UTC
End tag is one thing, but inside an HTML tag, there are many possible attributes .

Problem is that the CC for HTML attributes is also broken after an inside scriptlet.  

try this :
<input type="text" value="<%="1"%>" name="test" >
  before the [value] attribute : the HTML CC works fine
  after the [value] attribute : the ide shows the javascript CC!

This HTML attribute CC is a very important feature, at least P2 according to me.
Thanks.
Comment 6 Marek Fukala 2007-12-05 12:06:45 UTC
I am aware of the problem. There will be completely rewriten html parsing support in 6.1 which already handles the
embedding problems.
Comment 7 Marek Fukala 2008-03-05 21:31:06 UTC
This should really be fixed, it is very unpleasant - it likely involves either fixing the legacy html completion code or
migration to html parser.
Comment 8 Jiri Prox 2008-04-11 01:20:44 UTC
moving opened issues from TM <= 6.1 to TM=Dev
Comment 9 Marek Fukala 2008-09-03 09:32:55 UTC
tags matching works now, the </h3> completion still doesn't

<input type="text" value="<%="1"%>" name="test" > also reproducible
Comment 10 Marek Fukala 2008-09-03 11:06:55 UTC
fixed by switching the code to joined token sequences.

changeset:   99651:dfdbf3626f58
tag:         tip
user:        Marek Fukala <mfukala@netbeans.org>
date:        Wed Sep 03 12:05:52 2008 +0200
summary:     #120381 - Broken HTML end tag CC with embeded scriplet
Comment 11 Quality Engineering 2008-09-03 17:31:41 UTC
Integrated into 'main-golden', will be available in build *200809031401* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/dfdbf3626f58
User: Marek Fukala <mfukala@netbeans.org>
Log: #120381 - Broken HTML end tag CC with embeded scriplet
Comment 12 Jindrich Sedek 2008-09-08 16:51:50 UTC
verified.
NetBeans IDE Dev (Build 200809061401)