You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Łukasz Budnik <lu...@gmail.com> on 2007/12/29 11:23:43 UTC
Tomahawk 1.1.7-SNAPSHOT - MyFaces javascript not found
Hi!
I'm using Tomahawk 1.1.7 with MyFaces 1.2.0
previously I was using Tomahawk 1.1.6 and MyFaces 1.1.5.
When running my application I get an error:
MyFaces special javascript could not be retrieved from request-map.
any ideas how to fix it?
best regards
Łukasz
this is my web.xml (most of it is copy&paste from MyFaces web page):
<filter>
<filter-name>MyFacesExtensionsFilter</filter-name>
<filter-class>org.apache.myfaces.webapp.filter.ExtensionsFilter</filter-class>
<init-param>
<description>Set the size limit for uploaded files.
Format: 10 - 10 bytes
10k - 10 KB
10m - 10 MB
1g - 1 GB
</description>
<param-name>maxFileSize</param-name>
<param-value>20m</param-value>
</init-param>
</filter>
<!-- extension mapping for adding <script/>, <link/>, and other
resource tags to JSF-pages -->
<filter-mapping>
<filter-name>MyFacesExtensionsFilter</filter-name>
<!-- servlet-name must match the name of your
javax.faces.webapp.FacesServlet entry -->
<servlet-name>Faces Servlet</servlet-name>
</filter-mapping>
<!-- extension mapping for serving page-independent resources
(javascript, stylesheets, images, etc.) -->
<filter-mapping>
<filter-name>MyFacesExtensionsFilter</filter-name>
<url-pattern>/faces/myFacesExtensionResource/*</url-pattern>
</filter-mapping>
<!-- extension mapping for adding <script/>, <link/>, and other
resource tags to JSF-pages -->
<filter-mapping>
<filter-name>MyFacesExtensionsFilter</filter-name>
<url-pattern>*.jsf</url-pattern>
</filter-mapping>
<servlet>
<servlet-name>Faces Servlet</servlet-name>
<servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>Faces Servlet</servlet-name>
<url-pattern>*.jsf</url-pattern>
</servlet-mapping>
Re: Tomahawk 1.1.7-SNAPSHOT - MyFaces javascript not found
Posted by Łukasz Budnik <lu...@gmail.com>.
Hi!
I see now!
MyFaces javascripts are inserted into Tomahawk schedule component, but
on pages where I use <t:dataTable> there are no javascripts appended!
For example in generated sort header HTML I have:
for example:
<th class="standardTable_Header"><a href="#"
onclick="clear_contacts();document.forms['contacts'].elements['contacts:_link_hidden_'].value='contacts:data:j_id_id68';if(document.forms['contacts'].onsubmit){document.forms['contacts'].onsubmit();}document.forms['contacts'].submit();return
false;" id="contacts:data:j_id_id68">Nazwa↑</a></th>
but when I click "Nazwa" header I get:
JavaScript Error: clear_contacts is not defined
Error: clear_contacts is not defined
Source File: http://localhost:8080/student/contacts/contactsList.jsf
Line: 1
any other idea?
best regards
Łukasz
On 29/12/2007, simon <si...@chello.at> wrote:
>
> On Sat, 2007-12-29 at 11:23 +0100, Łukasz Budnik wrote:
> > Hi!
> >
> > I'm using Tomahawk 1.1.7 with MyFaces 1.2.0
> >
> > previously I was using Tomahawk 1.1.6 and MyFaces 1.1.5.
> >
> > When running my application I get an error:
> >
> > MyFaces special javascript could not be retrieved from request-map.
> >
> > any ideas how to fix it?
>
> I think these two are redundant, ie you should have of them but not
> both:
>
> <filter-mapping>
> <filter-name>MyFacesExtensionsFilter</filter-name>
> <servlet-name>Faces Servlet</servlet-name>
> </filter-mapping>
>
> <filter-mapping>
> <filter-name>MyFacesExtensionsFilter</filter-name>
> <url-pattern>*.jsf</url-pattern>
> </filter-mapping>
>
> Regards,
>
> Simon
>
>
Re: Tomahawk 1.1.7-SNAPSHOT - MyFaces javascript not found
Posted by simon <si...@chello.at>.
On Sat, 2007-12-29 at 11:23 +0100, Łukasz Budnik wrote:
> Hi!
>
> I'm using Tomahawk 1.1.7 with MyFaces 1.2.0
>
> previously I was using Tomahawk 1.1.6 and MyFaces 1.1.5.
>
> When running my application I get an error:
>
> MyFaces special javascript could not be retrieved from request-map.
>
> any ideas how to fix it?
I think these two are redundant, ie you should have of them but not
both:
<filter-mapping>
<filter-name>MyFacesExtensionsFilter</filter-name>
<servlet-name>Faces Servlet</servlet-name>
</filter-mapping>
<filter-mapping>
<filter-name>MyFacesExtensionsFilter</filter-name>
<url-pattern>*.jsf</url-pattern>
</filter-mapping>
Regards,
Simon