You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by nanini <na...@ich-habs-ja-gleich-gesagt.de> on 2008/11/12 17:27:14 UTC
Re: MyFaces is inserting JS that's causing JS errors
I am facing the same problem. Aren't there any answers yet?
laredotornado wrote:
>
> Hi,
>
> I'm noticing this behavior on PC Firefox. I'm using MyFaces 1.1.6 with
> Tomahawk 1.1.7 on WebLogic 9.2.2 On a page I have inputCalendar objects,
> and I notice this is getting added to the top of my page:
>
> <script type="text/javascript"
> src="/nps_history_gui/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/12234745/prototype.PrototypeResourceLoader/prototype.js"><!--
>
> //--></script>
> <script type="text/javascript"
> src="/nps_history_gui/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/12234745/calendar.HtmlCalendarRenderer/date.js"><!--
>
> //--></script>
> <script type="text/javascript"
> src="/nps_history_gui/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/12234745/calendar.HtmlCalendarRenderer/popcalendar.js"><!--
>
> //--></script>
> <script type="text/javascript"
> src="/nps_history_gui/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/12234745/inputTextHelp.HtmlTextHelpRenderer/inputTextHelp.js"><!--
>
> //--></script>
>
>
> but upon loading my page, I get this JS error:
>
> invalid array length this.length--; prototype.js (line 464)
>
>
--
View this message in context: http://www.nabble.com/MyFaces-is-inserting-JS-that%27s-causing-JS-errors-tp19879993p20463827.html
Sent from the MyFaces - Users mailing list archive at Nabble.com.
Re: MyFaces is inserting JS that's causing JS errors
Posted by laredotornado <la...@gmail.com>.
Hi Simon,
To answer your question, yes, the scripts load for me if I do what you said
in (a). At least in my case, the error I'm getting (seen in Firebug:
http://screencast.com/t/NcCMlp52iC)
invalid array length
this.length--;
refers to this block of code in prototype.js
shift: function() {
var result = this[0];
for (var i = 0; i < this.length - 1; i++)
this[i] = this[i + 1];
this.length--;
return result;
},
So clearly prototype.js is loading, but something is not gelling with
"this.length", whatever that means. - Dave
Simon Kitching wrote:
>
> Are the referenced scripts getting correctly loaded?
> (a) if you paste that url into a new browser window, do you see the
> script?
> (b) if you enable firebug in firefox, can you see the javascript?
>
> If not, then you probably have the Tomahawk ExtensionsFilter incorrectly
> configured.
>
> If the script is being loaded, then I can't think what the problem would
> be. Those are the latest versions of myfaces1.1x and tomahawk, so they
> should be compatible (we would have had lots of problem reports if not,
> including problems with the tomahawk example pages that use
> inputCalendar). Weblogic can be weird sometimes, but I can't see it
> causing this sort of issue.
>
> Are you using other libraries (richfaces, trinidad, etc)?
>
> If not, then you'll probably have to debug a little more on your
> environment...
>
> Regards,
> Simon
>
> nanini schrieb:
>> I am facing the same problem. Aren't there any answers yet?
>>
>>
>> laredotornado wrote:
>>
>>> Hi,
>>>
>>> I'm noticing this behavior on PC Firefox. I'm using MyFaces 1.1.6 with
>>> Tomahawk 1.1.7 on WebLogic 9.2.2 On a page I have inputCalendar
>>> objects,
>>> and I notice this is getting added to the top of my page:
>>>
>>> <script type="text/javascript"
>>> src="/nps_history_gui/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/12234745/prototype.PrototypeResourceLoader/prototype.js"><!--
>>>
>>> //--></script>
>>> <script type="text/javascript"
>>> src="/nps_history_gui/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/12234745/calendar.HtmlCalendarRenderer/date.js"><!--
>>>
>>> //--></script>
>>> <script type="text/javascript"
>>> src="/nps_history_gui/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/12234745/calendar.HtmlCalendarRenderer/popcalendar.js"><!--
>>>
>>> //--></script>
>>> <script type="text/javascript"
>>> src="/nps_history_gui/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/12234745/inputTextHelp.HtmlTextHelpRenderer/inputTextHelp.js"><!--
>>>
>>> //--></script>
>>>
>>>
>>> but upon loading my page, I get this JS error:
>>>
>>> invalid array length this.length--; prototype.js (line 464)
>>>
>>>
>>>
>>
>>
>
>
>
--
View this message in context: http://www.nabble.com/MyFaces-is-inserting-JS-that%27s-causing-JS-errors-tp19879993p20481644.html
Sent from the MyFaces - Users mailing list archive at Nabble.com.
Re: MyFaces is inserting JS that's causing JS errors
Posted by Simon Kitching <sk...@apache.org>.
Are the referenced scripts getting correctly loaded?
(a) if you paste that url into a new browser window, do you see the script?
(b) if you enable firebug in firefox, can you see the javascript?
If not, then you probably have the Tomahawk ExtensionsFilter incorrectly
configured.
If the script is being loaded, then I can't think what the problem would
be. Those are the latest versions of myfaces1.1x and tomahawk, so they
should be compatible (we would have had lots of problem reports if not,
including problems with the tomahawk example pages that use
inputCalendar). Weblogic can be weird sometimes, but I can't see it
causing this sort of issue.
Are you using other libraries (richfaces, trinidad, etc)?
If not, then you'll probably have to debug a little more on your
environment...
Regards,
Simon
nanini schrieb:
> I am facing the same problem. Aren't there any answers yet?
>
>
> laredotornado wrote:
>
>> Hi,
>>
>> I'm noticing this behavior on PC Firefox. I'm using MyFaces 1.1.6 with
>> Tomahawk 1.1.7 on WebLogic 9.2.2 On a page I have inputCalendar objects,
>> and I notice this is getting added to the top of my page:
>>
>> <script type="text/javascript"
>> src="/nps_history_gui/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/12234745/prototype.PrototypeResourceLoader/prototype.js"><!--
>>
>> //--></script>
>> <script type="text/javascript"
>> src="/nps_history_gui/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/12234745/calendar.HtmlCalendarRenderer/date.js"><!--
>>
>> //--></script>
>> <script type="text/javascript"
>> src="/nps_history_gui/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/12234745/calendar.HtmlCalendarRenderer/popcalendar.js"><!--
>>
>> //--></script>
>> <script type="text/javascript"
>> src="/nps_history_gui/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/12234745/inputTextHelp.HtmlTextHelpRenderer/inputTextHelp.js"><!--
>>
>> //--></script>
>>
>>
>> but upon loading my page, I get this JS error:
>>
>> invalid array length this.length--; prototype.js (line 464)
>>
>>
>>
>
>