You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Howard Lewis Ship <hl...@gmail.com> on 2009/06/02 17:22:29 UTC

Re: [T5.1.0.5] 'Tapestry' is undefined JavaScript error on form submit

That's odd because I've tested this under IE 7 and it works.  Anyone
else seeing this?

On Tue, Jun 2, 2009 at 7:44 AM, Eric Ma <er...@db.com> wrote:
>
> I have a simple form:
>
> <form t:id="myForm" t:type="Form">
>
> T5.1.0.5 turns it into:
>
> <form enctype="application/x-www-form-urlencoded"
> onsubmit="javascript:Tapestry.waitForPage(event);" action="../myClass"
> method="post" id="myForm" name="myForm">
>
> What is this extra bit onsubmit="javascript:Tapestry.waitForPage(event);"
> for?  IE 7 gives a runtime JS error: 'Tapestry' is undefined.  However, the
> form gets submiited properly.  So this is not a show-stopper.  It is simply
> an annoyance.
>
> Any suggestion how to suppress this event handler?  Thanks,
>
> Eric
> --
> View this message in context: http://www.nabble.com/-T5.1.0.5--%27Tapestry%27-is-undefined-JavaScript-error-on-form-submit-tp23834056p23834056.html
> Sent from the Tapestry - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>



-- 
Howard M. Lewis Ship

Creator of Apache Tapestry
Director of Open Source Technology at Formos

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


Re: [T5.1.0.5] 'Tapestry' is undefined JavaScript error on form submit

Posted by olip <ol...@googlemail.com>.
Hey Joachim,
Thank you so much!
This works like a charm!

Thanks again for your quick help!

Joachim Van der Auwera (PROGS bvba) wrote:
> 
> Sometimes this is caused by the combine script settings which can give 
> problems in IE when the URL becomes too long. Switching off combine 
> scripts may help.
> 
> Kind regards,
> Joachim
> 
> olip wrote:
>> Found out that on 5.1.0.1 it is still working (tapestry.js is rendered)
>> but
>> 5.1.0.2. it is no longer working
>>
>> olip wrote:
>>   
>>> I have the same problems with T5.1.0.5.  I downgraded to 5.0.18 and the
>>> Tapestry.js reappears in my code again.
>>>
>>>
>>>
>>> Eric Ma wrote:
>>>     
>>>> Howard Lewis Ship wrote:
>>>>       
>>>>> Well, you could verify that with a "view source"; it seems unlikely to
>>>>> me, but that would be a start towards investigating this.
>>>>>
>>>>> Howard M. Lewis Ship
>>>>>
>>>>>         
>>>> Well, I had never had the need to explicitly include tapestry.js, until
>>>> today that is. T5 apparently does its magic behind the scenes.  Plus,
>>>> when
>>>> doing View Source for the pages in which the onsubmit handler works, I
>>>> cannot find tapestry.js.
>>>>
>>>> After explicitly adding
>>>> @IncludeJavaScriptLibrary({"classpath:org/apache/tapestry5/tapestry.js"})
>>>> to the custom component, my problem is now resolved.  Howard, does that
>>>> give you a clue how to solve the problem at the root level?
>>>>
>>>> Eric
>>>>
>>>>
>>>>
>>>>       
>>> -- 
>>> View this message in context:
>>> http://old.nabble.com/-T5.1.0.5--%27Tapestry%27-is-undefined-JavaScript-error-on-form-submit-tp23834056p26840980.html
>>> Sent from the Tapestry - User mailing list archive at Nabble.com.
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>>> For additional commands, e-mail: users-help@tapestry.apache.org
>>>
>>>
>>>
>>>     
>>
>>   
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/-T5.1.0.5--%27Tapestry%27-is-undefined-JavaScript-error-on-form-submit-tp23834056p26844865.html
Sent from the Tapestry - User mailing list archive at Nabble.com.


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


Re: [T5.1.0.5] 'Tapestry' is undefined JavaScript error on form submit

Posted by Donny Nadolny <do...@gmail.com>.
Combine scripts is an optimization that Tapestry can do where it
combines all the javascript files in to one virtual file to minimize
the number of HTTP requests that the browser has to do.

As for your problem, you say you've included jQuery - are you setting
no conflict mode on? http://api.jquery.com/jQuery.noConflict/

Tapestry uses the Prototype javascript library, which uses the dollar
sign for a namespace. So does jQuery, which is what causes this
problem.

You can just open up your jQuery js and add "$.noConflict();" to the end.

On Tue, Dec 7, 2010 at 6:15 AM, rajesh <ra...@gmail.com> wrote:
>
> Hi,
>  I am getting "Tapestry is undefined" error on form submit. I have tried
> both Firefox 3.6.12 and IE 8 (Version: 8.0.6001.18702). On both the
> browsers, I am facing the same error.
>
> Can someone please explain what switching off combine scripts is?
>
> Here are the tapestry/jquery packages that I am using:
>
> tapestry5-annotations-5.1.0.5.jar
> tapestry-ioc-5.1.0.5.jar
> tapestry-core-5.1.0.5.jar
> jquery-1.4.2
>
> Regards
> Rajesh
> --
> View this message in context: http://tapestry.1045711.n5.nabble.com/T5-1-0-5-Tapestry-is-undefined-JavaScript-error-on-form-submit-tp2393118p3295600.html
> Sent from the Tapestry - User mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>

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


Re: [T5.1.0.5] 'Tapestry' is undefined JavaScript error on form submit

Posted by Jonathan Barker <jo...@gmail.com>.
I have hit this before, and I don't have a definitive reason.  But at least
you are not alone.

I have considered it may have something to do with the production setup
where the Tomcat instance sits behind a proxy and uses the AJP connector,
because I don't get it on my development system.



On Tue, Dec 7, 2010 at 6:15 AM, rajesh <ra...@gmail.com> wrote:

>
> Hi,
>  I am getting "Tapestry is undefined" error on form submit. I have tried
> both Firefox 3.6.12 and IE 8 (Version: 8.0.6001.18702). On both the
> browsers, I am facing the same error.
>
> Can someone please explain what switching off combine scripts is?
>
> Here are the tapestry/jquery packages that I am using:
>
> tapestry5-annotations-5.1.0.5.jar
> tapestry-ioc-5.1.0.5.jar
> tapestry-core-5.1.0.5.jar
> jquery-1.4.2
>
> Regards
> Rajesh
> --
> View this message in context:
> http://tapestry.1045711.n5.nabble.com/T5-1-0-5-Tapestry-is-undefined-JavaScript-error-on-form-submit-tp2393118p3295600.html
> Sent from the Tapestry - User mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>


-- 
Jonathan Barker
ITStrategic

Re: [T5.1.0.5] 'Tapestry' is undefined JavaScript error on form submit

Posted by rajesh <ra...@gmail.com>.
Hi, 
 I am getting "Tapestry is undefined" error on form submit. I have tried
both Firefox 3.6.12 and IE 8 (Version: 8.0.6001.18702). On both the
browsers, I am facing the same error.

Can someone please explain what switching off combine scripts is? 

Here are the tapestry/jquery packages that I am using:

tapestry5-annotations-5.1.0.5.jar
tapestry-ioc-5.1.0.5.jar
tapestry-core-5.1.0.5.jar
jquery-1.4.2

Regards
Rajesh
-- 
View this message in context: http://tapestry.1045711.n5.nabble.com/T5-1-0-5-Tapestry-is-undefined-JavaScript-error-on-form-submit-tp2393118p3295600.html
Sent from the Tapestry - User mailing list archive at Nabble.com.

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


Re: [T5.1.0.5] 'Tapestry' is undefined JavaScript error on form submit

Posted by "Joachim Van der Auwera (PROGS bvba)" <jo...@progs.be>.
Sometimes this is caused by the combine script settings which can give 
problems in IE when the URL becomes too long. Switching off combine 
scripts may help.

Kind regards,
Joachim

olip wrote:
> Found out that on 5.1.0.1 it is still working (tapestry.js is rendered) but
> 5.1.0.2. it is no longer working
>
> olip wrote:
>   
>> I have the same problems with T5.1.0.5.  I downgraded to 5.0.18 and the
>> Tapestry.js reappears in my code again.
>>
>>
>>
>> Eric Ma wrote:
>>     
>>> Howard Lewis Ship wrote:
>>>       
>>>> Well, you could verify that with a "view source"; it seems unlikely to
>>>> me, but that would be a start towards investigating this.
>>>>
>>>> Howard M. Lewis Ship
>>>>
>>>>         
>>> Well, I had never had the need to explicitly include tapestry.js, until
>>> today that is. T5 apparently does its magic behind the scenes.  Plus,
>>> when
>>> doing View Source for the pages in which the onsubmit handler works, I
>>> cannot find tapestry.js.
>>>
>>> After explicitly adding
>>> @IncludeJavaScriptLibrary({"classpath:org/apache/tapestry5/tapestry.js"})
>>> to the custom component, my problem is now resolved.  Howard, does that
>>> give you a clue how to solve the problem at the root level?
>>>
>>> Eric
>>>
>>>
>>>
>>>       
>> -- 
>> View this message in context:
>> http://old.nabble.com/-T5.1.0.5--%27Tapestry%27-is-undefined-JavaScript-error-on-form-submit-tp23834056p26840980.html
>> Sent from the Tapestry - User mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>> For additional commands, e-mail: users-help@tapestry.apache.org
>>
>>
>>
>>     
>
>   


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


Re: [T5.1.0.5] 'Tapestry' is undefined JavaScript error on form submit

Posted by olip <ol...@googlemail.com>.
Found out that on 5.1.0.1 it is still working (tapestry.js is rendered) but
5.1.0.2. it is no longer working

olip wrote:
> 
> 
> I have the same problems with T5.1.0.5.  I downgraded to 5.0.18 and the
> Tapestry.js reappears in my code again.
> 
> 
> 
> Eric Ma wrote:
>> 
>> 
>> Howard Lewis Ship wrote:
>>> 
>>> Well, you could verify that with a "view source"; it seems unlikely to
>>> me, but that would be a start towards investigating this.
>>> 
>>> Howard M. Lewis Ship
>>> 
>> 
>> Well, I had never had the need to explicitly include tapestry.js, until
>> today that is. T5 apparently does its magic behind the scenes.  Plus,
>> when
>> doing View Source for the pages in which the onsubmit handler works, I
>> cannot find tapestry.js.
>> 
>> After explicitly adding
>> @IncludeJavaScriptLibrary({"classpath:org/apache/tapestry5/tapestry.js"})
>> to the custom component, my problem is now resolved.  Howard, does that
>> give you a clue how to solve the problem at the root level?
>> 
>> Eric
>> 
>> 
>> 
> 
> -- 
> View this message in context:
> http://old.nabble.com/-T5.1.0.5--%27Tapestry%27-is-undefined-JavaScript-error-on-form-submit-tp23834056p26840980.html
> Sent from the Tapestry - User mailing list archive at Nabble.com.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
> 
> 
> 

-- 
View this message in context: http://n2.nabble.com/T5-1-0-5-Tapestry-is-undefined-JavaScript-error-on-form-submit-tp3012500p4186524.html
Sent from the Tapestry Users mailing list archive at Nabble.com.

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


Re: [T5.1.0.5] 'Tapestry' is undefined JavaScript error on form submit

Posted by olip <ol...@googlemail.com>.
I have the same problems with T5.1.0.5.  I downgraded to 5.0.18 and the
Tapestry.js reappears in my code again.



Eric Ma wrote:
> 
> 
> Howard Lewis Ship wrote:
>> 
>> Well, you could verify that with a "view source"; it seems unlikely to
>> me, but that would be a start towards investigating this.
>> 
>> Howard M. Lewis Ship
>> 
> 
> Well, I had never had the need to explicitly include tapestry.js, until
> today that is. T5 apparently does its magic behind the scenes.  Plus, when
> doing View Source for the pages in which the onsubmit handler works, I
> cannot find tapestry.js.
> 
> After explicitly adding
> @IncludeJavaScriptLibrary({"classpath:org/apache/tapestry5/tapestry.js"})
> to the custom component, my problem is now resolved.  Howard, does that
> give you a clue how to solve the problem at the root level?
> 
> Eric
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/-T5.1.0.5--%27Tapestry%27-is-undefined-JavaScript-error-on-form-submit-tp23834056p26840980.html
Sent from the Tapestry - User mailing list archive at Nabble.com.


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


Re: [T5.1.0.5] 'Tapestry' is undefined JavaScript error on form submit

Posted by Eric Ma <er...@db.com>.

Howard Lewis Ship wrote:
> 
> Well, you could verify that with a "view source"; it seems unlikely to
> me, but that would be a start towards investigating this.
> 
> Howard M. Lewis Ship
> 

Well, I had never had the need to explicitly include tapestry.js, until
today that is. T5 apparently does its magic behind the scenes.  Plus, when
doing View Source for the pages in which the onsubmit handler works, I
cannot find tapestry.js.

After explicitly adding
@IncludeJavaScriptLibrary({"classpath:org/apache/tapestry5/tapestry.js"}) to
the custom component, my problem is now resolved.  Howard, does that give
you a clue how to solve the problem at the root level?

Eric


-- 
View this message in context: http://www.nabble.com/-T5.1.0.5--%27Tapestry%27-is-undefined-JavaScript-error-on-form-submit-tp23834056p23839494.html
Sent from the Tapestry - User mailing list archive at Nabble.com.


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


Re: [T5.1.0.5] 'Tapestry' is undefined JavaScript error on form submit

Posted by Sergey Didenko <se...@gmail.com>.
I created an issue about this problem a few days ago:

https://issues.apache.org/jira/browse/TAP5-712

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


Re: [T5.1.0.5] 'Tapestry' is undefined JavaScript error on form submit

Posted by "Thiago H. de Paula Figueiredo" <th...@gmail.com>.
Em Tue, 02 Jun 2009 14:06:58 -0300, Howard Lewis Ship <hl...@gmail.com>  
escreveu:

> Well, you could verify that with a "view source"; it seems unlikely to
> me, but that would be a start towards investigating this.

This problem can also be cause by some previous Javascript error. Using  
Firebug and/or Web Developer can help to figure out what's happening.

-- 
Thiago H. de Paula Figueiredo
Independent Java consultant, developer, and instructor
http://www.arsmachina.com.br/thiago

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


Re: [T5.1.0.5] 'Tapestry' is undefined JavaScript error on form submit

Posted by Howard Lewis Ship <hl...@gmail.com>.
Well, you could verify that with a "view source"; it seems unlikely to
me, but that would be a start towards investigating this.

On Tue, Jun 2, 2009 at 8:44 AM, Eric Ma <er...@db.com> wrote:
>
>
>
> Howard Lewis Ship wrote:
>>
>> That's odd because I've tested this under IE 7 and it works.  Anyone
>> else seeing this?
>>
>> Howard M. Lewis Ship
>>
>> Creator of Apache Tapestry
>> Director of Open Source Technology at Formos
>>
>
> Thanks for the reply Howard.  One thing I notice is on the page where this
> JS error occurs, the <form> element is in a custom component, not in the
> page directly.  In all other pages with <form> elements, IE 7 is perfectly
> fine with the onsubmit event handler.
>
> So it appears somehow the main Tapestry.js file is not included properly
> with components.
>
> --
> View this message in context: http://www.nabble.com/-T5.1.0.5--%27Tapestry%27-is-undefined-JavaScript-error-on-form-submit-tp23834056p23835288.html
> Sent from the Tapestry - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>



-- 
Howard M. Lewis Ship

Creator of Apache Tapestry
Director of Open Source Technology at Formos

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


Re: [T5.1.0.5] 'Tapestry' is undefined JavaScript error on form submit

Posted by Eric Ma <er...@db.com>.


Howard Lewis Ship wrote:
> 
> That's odd because I've tested this under IE 7 and it works.  Anyone
> else seeing this? 
> 
> Howard M. Lewis Ship
> 
> Creator of Apache Tapestry
> Director of Open Source Technology at Formos
> 

Thanks for the reply Howard.  One thing I notice is on the page where this
JS error occurs, the <form> element is in a custom component, not in the
page directly.  In all other pages with <form> elements, IE 7 is perfectly
fine with the onsubmit event handler.

So it appears somehow the main Tapestry.js file is not included properly
with components.

-- 
View this message in context: http://www.nabble.com/-T5.1.0.5--%27Tapestry%27-is-undefined-JavaScript-error-on-form-submit-tp23834056p23835288.html
Sent from the Tapestry - User mailing list archive at Nabble.com.


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