0 Replies Latest reply on Mar 5, 2009 4:23 AM by zzuli

    Problem of using ajax with jseam remoting


          I'm, studying ajax in jseam with remoting, but got stuck with a little demo.
           The java code:
      public interface HelloLocal {
        public String sayHello(String name);

      public class HelloAction implements HelloLocal {
        public String sayHello(String name) {
          return  name;

           The xhtml page:
        <script type="text/javascript"
                      <s:remote include="helloAction" />

                      <script type="text/javascript">
              function sayHello() {
                var name = 'zwz';
                Seam.Component.getInstance("helloAction").sayHello(name, sayHelloCallback);
              function sayHelloCallback(result) {

                      <button onclick="javascript:sayHello()">
                              Say Hello

          But when deployed and ran, it always warn javascript error "Seam method not defined", and there's no exception.
          In fact the demo is copy from jseam examples.
          I use jseam2.1.1 , JBoss AS 5.0 , ie7.
          Could anyone help me?
          Or if anyone has some runnable simple demo, could please send me a copy? zw_z7@hotmail.com
          Thanks very much.