Hi,

when I am trying to upgrade our web app to Tapestry 5.1.0.5, I have got a
javascript syntax error when a javascript method with parameters is called
inside a Ajax block. I have tested many kinds of scenarios, I could not
figure out the problem. 

1. If the javascript method with parameters is not in a Ajax block, it runs
fine in IE and FF
2. If the javascript method with parameters is in a Ajax block, it runs fine
in FF, but has a syntax error in IE; 

Can someone tell me what is wrong? Thanks a lot.

Here are my codes:


Test.tml:

<t:layout xmlns:t="http://tapestry.apache.org/schema/tapestry_5_1_0.xsd";
xmlns:p="tapestry:parameter">
        <script type="text/javascript">
        function copyContentPieceToMceEditor(src, dest, editorId) {

                alert("src=" + src);
                alert("dest=" + dest);
                alert("editorId=" + editorId);
        }
        
        </script>
        
         Ajax Call 
                        
                        <t:zone t:id="updateZone" >
                        </t:zone>
                        
                        <t:block t:id="ajaxBlock" >
                                <table width="100%" cellpadding="0" 
cellspacing="0">
                                <tr>
                                        <td>
                                                <p>
                                                         # Edit 
                                                </p>
                                        </td>
                                </tr>
                        </table>
                        </t:block>
  </t:layout>

Test.java:

public class Test extends BasePage
{
        
        @Inject
        private Block ajaxBlock;

        public Block getAjaxBlock()
        {
                return ajaxBlock;
        }

        public Block onActionFromEditContentBlock()
        {
                return getAjaxBlock();
        }

}
-- 
View this message in context: 
http://old.nabble.com/Javascript-error-in-IE-when-a-javascript-call-in-an-Ajax-block-tp27761290p27761290.html
Sent from the Tapestry - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org

Reply via email to