maybe you should just use firefox?

are you using eclipse or netbeans?

gwt php in eclipse:

suppose your apache's webroot is "c:\www"
and you created your project in "c:\www\apps\"
and your project name is "mytest"

so your project is gonna have these directories:
c:\www\apps\mytest\src
c:\www\apps\mytest\test
c:\www\apps\mytest\war

you place your php files in the war folder

test.php:

<?php
   echo "hello";
?>

and in your java code, let's say you have this method to test:

public void testphp(){
        try
    {
        RequestBuilder builder = new
RequestBuilder(RequestBuilder.POST, GWT.getHostPageBaseURL()
+"test.php");
        builder.setHeader("Content-Type", "application/x-www-form-
urlencoded");
        builder.sendRequest("", new RequestCallback()
        {
            @Override
            public void onError(Request request, Throwable ex)
            {
                Window.alert(ex.toString());
            }

            @Override
            public void onResponseReceived(Request request, Response
response)
            {
                Window.alert("PHP output: " +
response.getText());
            }
        });
    }
    catch (RequestException e)
    {
        Window.alert(e.toString());
    }
}

in the project explorer of eclipse, right click your project and
choose properties.
click Run/Debug Settings.
choose your project and click edit.
remove the check in run built-in server and change the port to 80.

run the project. copy the link in the "development mode" window and
paste it in the browser's address bar.
when you open the link, it will display a page not found error.
because you really don't have a mytest.html in
the root of your www folder.

the link looks like this:
http://127.0.0.1/mytest.html?gwt.codesvr=127.0.0.1:9997

copy "?gwt.codesvr=127.0.0.1:9997" from the link

mytest.html is really in:
http://localhost/apps/mytest/war/mytest.html

paste the end of the previous link to the new link so it looks like
this:
http://localhost/apps/mytest/war/mytest.html?gwt.codesvr=127.0.0.1:9997

now you can simply refresh the page to view any changes made to your
java and php code.
no need to compile or run.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.

Reply via email to