You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tapestry.apache.org by "mindhawk (JIRA)" <ji...@apache.org> on 2009/12/02 07:42:20 UTC

[jira] Created: (TAP5-942) Javascript error after zone refreshed for IE

Javascript error after zone refreshed for IE
--------------------------------------------

                 Key: TAP5-942
                 URL: https://issues.apache.org/jira/browse/TAP5-942
             Project: Tapestry 5
          Issue Type: Bug
    Affects Versions: 5.1.0.5
            Reporter: mindhawk
            Priority: Critical


If I write such a html template as follows:

<div t:type="zone" t:id="zone">
	    <div onclick="javascript:alert('ok')">click</div>
</div>

There will be an javascript error for IE because at this time the template is show as follow:
<div onclick='alert(&apos;ok&apos;)'>click</div>

If I click on the div, a error will occour in IE, but others work well 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (TAP5-942) Javascript error after zone refreshed for IE

Posted by "Howard M. Lewis Ship (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/TAP5-942?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Howard M. Lewis Ship updated TAP5-942:
--------------------------------------

    Priority: Minor  (was: Critical)

Real applications in Tapestry do no use inline JavaScript as in your example, for many reasons, including browser compatibility. There are ample workarounds for avoiding these encoding issues properly; you should assign an id to the div (using JavaScriptSupport) and use other methods of JavaScriptSupport to attach the onclick event handler.

> Javascript error after zone refreshed for IE
> --------------------------------------------
>
>                 Key: TAP5-942
>                 URL: https://issues.apache.org/jira/browse/TAP5-942
>             Project: Tapestry 5
>          Issue Type: Bug
>    Affects Versions: 5.1.0.5
>            Reporter: mindhawk
>            Priority: Minor
>
> If I write such a html template as follows:
> <div t:type="zone" t:id="zone">
> 	    <div onclick="javascript:alert('ok')">click</div>
> </div>
> There will be an javascript error for IE because at this time the template is show as follow:
> <div onclick='alert(&apos;ok&apos;)'>click</div>
> If I click on the div, a error will occour in IE, but others work well 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (TAP5-942) Javascript error after zone refreshed for IE

Posted by "Howard M. Lewis Ship (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/TAP5-942?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Howard M. Lewis Ship updated TAP5-942:
--------------------------------------

    Priority: Minor  (was: Critical)

Real applications in Tapestry do no use inline JavaScript as in your example, for many reasons, including browser compatibility. There are ample workarounds for avoiding these encoding issues properly; you should assign an id to the div (using JavaScriptSupport) and use other methods of JavaScriptSupport to attach the onclick event handler.

> Javascript error after zone refreshed for IE
> --------------------------------------------
>
>                 Key: TAP5-942
>                 URL: https://issues.apache.org/jira/browse/TAP5-942
>             Project: Tapestry 5
>          Issue Type: Bug
>    Affects Versions: 5.1.0.5
>            Reporter: mindhawk
>            Priority: Minor
>
> If I write such a html template as follows:
> <div t:type="zone" t:id="zone">
> 	    <div onclick="javascript:alert('ok')">click</div>
> </div>
> There will be an javascript error for IE because at this time the template is show as follow:
> <div onclick='alert(&apos;ok&apos;)'>click</div>
> If I click on the div, a error will occour in IE, but others work well 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.