-
1. Re: Seam and PHP ??
jimk1723 Feb 21, 2008 1:01 AM (in response to samdoyle)I don't see why not. The Seam Remoting stuff is all Javascript on the client-side; you're not rendering any JSF views to call remoted server methods.
You may be thinking of Ajax4JSF which is tied to using JSF.
-
2. Re: Seam and PHP ??
thejavafreak Feb 21, 2008 3:40 AM (in response to samdoyle)Wow cool. I never thought of PHP connecting to Seam via Seam remoting. I think I'm gonna learn about this Seam remoting.
Thanks
-
3. Re: Seam and PHP ??
samdoyle Feb 21, 2008 3:44 AM (in response to samdoyle)
James Kelly wrote on Feb 21, 2008 01:01 AM:
I don't see why not. The Seam Remoting stuff is all Javascript on the client-side; you're not rendering any JSF views to call remoted server methods.
You may be thinking of Ajax4JSF which is tied to using JSF.So basically you doing what DWR does but gaining the ability to invoke Seam components on the backend. I thought however to make use of Seam Remoting there was required metadata that is populated in the requests. I remember looking at some of the requests before and it contained a substantial amount of metadata. I'm not sure if this will just work like this.
Can someone from the Seam team clarify?
-
4. Re: Seam and PHP ??
samdoyle Feb 21, 2008 5:54 PM (in response to samdoyle)Can someone confirm if just the JavaScript based Remoting capability can work on its own in a similar fashion DWR does?
-
5. Re: Seam and PHP ??
jimk1723 Feb 21, 2008 6:50 PM (in response to samdoyle)Yah, it's very DWR-ish. Assuming you've set up your Seam environment correctly to support remoting, the only thing you're sourcing on the client-side is remoting framework and your component stubs, e.g.
<script type="text/javascript" src="seam/resource/remoting/resource/remote.js"></script>
...and...
<script type="text/javascript" src="seam/resource/remoting/interface.js?customerAction"></script>
Now, Seam has a JSF tag to simplify sourcing the component stubs, but you don't need to use it.
Take a look at the examples/remoting/hellowold application. You can actually install that and then call the remote methods from a PHP script, static HTML, whatever. The only hurdle will be to get around the cross site scripting issues. You can set up a proxy redirect in apache with a .htaccess like...
RewriteEngine on RewriteRule ^seam-helloworld/seam/resource(.*)$ http://YOURJBOSSHOST/seam-helloworld/seam/resource$1 [P]
With the proxy directive, I could copy the static HTML from the HelloWorld exmaple to my htdocs directory and it worked fine.
-