I am trying to invoke a Java servlet from PHP. When I access the servlet from a browser I always get the results. But when I access it from a pHP script. I am not getting the results properly. Sometimes I dont get the results at all.
If servelt's get method is implemented then you may request a Servlet url in PHP code by setting href of anchor tag or set action attribute of form tag.
<a href="http://example.com/myservlet">Test</a><form method='GET' action='http://example.com/myservlet'>
If POST method is implemented in servlet class then use form tag. Set method='POST' and action='http://example.com/myservlet'.
加载中,请稍侯......
精彩评论