"sherkan777" wrote : | My Firefox browser throws me an error: "Seam is not defined" | at line: Seam.Component.getInstance("helloAction").sayHello(name, sayHelloCallback); |
I got this same problem, here was the problem I was having when I was using remoting on a view in a subdirectory of WebContent (say "subdir"). The documentation (http://docs.jboss.com/seam/latest/reference/en/html/remoting.html#d0e9752 )says to include javascript libraries like so: | <script type="text/javascript" src="seam/resource/remoting/resource/remote.js"></script> | <script type="text/javascript" src="seam/resource/remoting/interface.js?customerAction"></script> | However, the seam resource servlet is mapped at the root of the application: | <servlet-mapping> | <servlet-name>Seam Resource Servlet</servlet-name> | <url-pattern>/seam/resource/*</url-pattern> | </servlet-mapping> | So my javascript includes were looking for files like: http://hostname/context/subdir/seam/remoting/interface.js When I should be looking in: http://hostname/context/seam/remoting/interface.js So I just changed my script tags in my views to this: | <script type="text/javascript" src="../seam/resource/remoting/resource/remote.js"></script> | <script type="text/javascript" src="../seam/resource/remoting/interface.js?customerAction"></script> | You might have to adapt this depending on the structure inside your web directory, but that's the basic idea. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4062169#4062169 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4062169 _______________________________________________ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user