HTTP Form Post

Hi,
I need to emulate an HTTP form post from ALSB 2.5.
I have the business service defined as Text for both the Request and Response message types. I have a proxy that routes to the business service and sets the Content-type to 'application/x-www-form-urlencoded'.
But what I'm not clear on is how can I specify the form data set (name/value pairs) in the outbound HTTP request?
Thx in advance for the guidance!

You can do it from anywhwere in the pipeline. You can use an assign action and modify the content of $body. Don't modify the whole variable.
If it still does not work, here is what I would do. Write a simple html file containing a submit and point to a service bus dummy proxy service. Inside the dummy service use a log action to log the content of $body so you have an idea how it should exactlty looks like.
Gregory Haardt
ALSB Prg. Manager
[email protected]

Similar Messages

  • Xml over http form post and response example

    can some one point me to http form post/get  syntax to send and receive xml...let me know

    Use the cfhttp tag. For example, suppose the xmlDoc is already defined. Then you could post the document using
    <cfhttp url="the_url" method="post">
        <cfhttpparam type="header" name="content-type" value="text/xml">
        <cfhttpparam type="header" name="content-length" value="#len(xmlDoc)#">
        <cfhttpparam type="header" name="charset" value="utf-8">
        <cfhttpparam type="xml" name="message" value="#xmlDoc#">
    </cfhttp>

  • HTTP form post from Web Dynpro Java Application without opening new window

    Hi Experts,
    We are trying to submit form data to an external URL from Web Dynpro Java application. We are achieving this with the following piece of code.
      try
       strPrintContent="<html>"+
         "<head>"+
         "<script type=\"text/javascript\">"+   
         "function myfunc () "+
         "{"+
         "var frm = document.getElementById(\"paymentForm\");"+
         "frm.submit();"+
         "}"+
         "</script>"+
         "</head>"+
         "<body onLoad=myfunc()>"+
         "<form id=paymentForm  method=post action=\""+merchantURLPart+"\">"+
         "<INPUT type=hidden name=username value="+userName+">"+
         "<INPUT type=hidden name=pass value="+passWord+">"+
         "<INPUT type=hidden name=senderid value="+senderID+">"+    
         "<INPUT type=hidden name=dest_mobileno value="+mobile+">"+
         "<INPUT type=hidden name=message value='"+msg+"'>"+
         "<INPUT type=hidden name=response value="+response+">"+
         "</form>"+
         "</body>"+
         "</html>";    
      IWDWebResource webResource = WDWebResource.getWebResource(strPrintContent.getBytes(),WDWebResourceType.HTML);
      IWDWindow window = wdComponentAPI.getWindowManager().createNonModalExternalWindow(webResource.getAbsoluteURL(),"WBSEDCL");
      window.show();
      catch(Exception e)
      wdComponentAPI.getMessageManager().reportException("Error : "+e.toString(),false);
    But it opens another window. We dont need that. We have to stay on the same window.  Please suggest what can be done.

    Hi,
    You can create a HTML file with the request post parameters and the external URL something like this:
    public java.lang.String GetRedirecturl( )
    // External URL
    String html = "<html><head></head><body onload=\"load()\"> " +
    "<form id=\"form1\" action=\"https://www.abc.com/xyz.jsp\" method=\"POST\">" +
    // Post Parameters
    "<INPUT TYPE=\"HIDDEN\" NAME=\"Param1\"VALUE=\""+Param1Value+"\">"+
    "<input name=\"sap-wd-resumeurl\" type=\"hidden\"/>" +
    "</form> " +
    "" +
    "<script>" +
    "function load(){" +
    "var loc = window.location.search.substring(1);" +
    "var queryString = loc.split(\"sap-wd-resumeurl=\");" +
    "if(queryString.length > 0)" +
    "{" +
    "var resumeURL = queryString[1].split(\"&\");" +
    "if(resumeURL.length >= 0)" +
    "{" +
    " document.forms['form1'].elements['sap-wd-resumeurl'].value= unescape(resumeURL[0])" +
    "}" +
    "}" +
    "document.getElementById('form1').submit();" +
    "}" +
    "</script>" +
    "</body> </html>";
    String redirectUrl = "";
    byte[] byteArrayHtmlData = null;
    try {
      byteArrayHtmlData = html.getBytes("UTF-8");
    } catch (UnsupportedEncodingException e) {
      wdComponentAPI.getMessageManager().reportException("Internal error occurred. Please try after some time",true);
    IWDResource htmlResource = WDResourceFactory.createCachedResource(new ByteArrayInputStream(byteArrayHtmlData), "Redirect.html", WDWebResourceType.HTML, true);
    redirectUrl = htmlResource.getUrl(WDFileDownloadBehaviour.AUTO.ordinal());
    return redirectUrl;
    Hope this will be helpful.
    Regards,
    Anurag

  • HTTP Submit & FORM Post

    Where can I find an example of how to submit form data in a format used by HTML forms (URL-encoded Data - HTTP post)?
    Im just learning Acrobat 7.xand Form designer 7.x and cant figure out how to attach code to the Submit HTTP button. A client has a generalized forms post decoder/foward as e-mail program. The url would be, for example:
    http://www.ourwebsite.org/cgi-win/deField.exe method="POST"
    and it needs the Acrobat form to have the hidden field:
    femail=[email protected]   (email address to send form info to)
    What we really want to do is:
    1.     Use an interactive Acrobat form to collect and validate data from users over the Internet (by querying a database) as they fill in the form
    2.     Merge both user-entered data, and user-specific data pulled from the db, into the pdf form
    3.     Returned the completed form to the user for printing at their location,
    4.     And capture the full data into our database.
    .Ive scoured the product literature and the dev user forums and seen some limited FAQs and advice but its pretty murky. Any help will be greatly appreciated.

    <[email protected]> ha scritto nel messaggio <br />news:[email protected]...<br />> Where can I find an example of how to submit form data in a format used by <br />> HTML forms (URL-encoded Data - HTTP post)?<br />> I'm just learning Acrobat 7.xand Form designer 7.x and can't figure out <br />> how to attach code to the Submit HTTP button. A client has a generalized <br />> forms post decoder/foward as e-mail program. The url would be, for <br />> example:<br />><br />> <a href=http://www.ourwebsite.org/cgi-win/deField.exe> method="POST"<br />><br />> and it needs the Acrobat form to have the hidden field:<br />><br />> [email protected]  (email address to send form info to)<br />><br />><br />> What we really want to do is:<br />><br />> 1.    Use an interactive Acrobat form to collect and validate data from <br />> users over the Internet (by querying a database) as they fill in the form <br />> .<br />> 2.    Merge both user-entered data, and user-specific data pulled from the <br />> db, into the pdf form .<br />> 3.    Returned the completed form to the user for printing at their <br />> location,<br />> 4.    And capture the full data into our database.<br />><br />><br />><br />> .I've scoured the product literature and the dev user forums and seen some <br />> limited FAQs and advice but it's pretty murky. Any help will be greatly <br />> appreciated.<br /><br />Maybe I don't understand your question well and so my answer can be of no <br />help for you, but the first two points can be easily done with Designer and <br />a web service that send the data retrieved from a specific request (i.e. <br />your customer inserts his userid and automatically some data appears in the <br />form). You simply have to create a button that retrieves data from this <br />webservice (first you have to create a data connection to your webservice).<br />The third point can be achieved using a print button (that is ready to use <br />in the library). Remember that you can making all the operations you want to <br />do without re-loading the PDF, but simply by doing the call to your <br />webservice after the user filled in the form.<br />The forth point can be achieved using a submit botton that has the <br />controltype set to submit, then you can send your data in the format that <br />you choose. Of course, in the submit URL you can specify an email.<br /><br />Sorry if I don't understand your request :)<br /><br />Ciao,<br />Alessio<br /><br />Bye,<br />Alessio

  • Retrieve POST variables just like in a normal HTTP forms

    Hi All :D
    Can anyone tell me how to retrieve POST variables just like
    in a normal HTTP form?
    I have 2 flex applications. One will send the POST variables
    and I would like the other to retrieve
    these variables. How to implement this?
    Thanks :D

    "JuggerOgre" <[email protected]> wrote in
    message
    news:g92bce$kgf$[email protected]..
    > Hi All :D
    >
    > Can anyone tell me how to retrieve POST variables just
    like in a normal
    > HTTP
    > form?
    > I have 2 flex applications. One will send the POST
    variables and I would
    > like
    > the other to retrieve
    > these variables. How to implement this?
    Flex is a client side application. You could send them from
    one client and
    then request them from the other client, or you could use
    something like
    BlazeDS to "push" the information.
    HTH;
    Amy

  • SSO with a website using Apache Httpclient form post

    Hi ,
    I am trying to obtain, SS0 with a website, that accepts the user information via post.
    I tried using app Integrator, but the website sends a cookie in first request, and redirects to another URL. App Integrator is only catching the first response.
    Thus i tried implementing this Form post using Apache HTTPClient class inside the Abstractportacomponent, as shown..
    The login is taking place. But, When i click on any link on the page, It is redirecting to the login page again, I am wondering where should i give the Cookie, so the portal request will include that cookie in its subsequent requests, so that i wont be prompted for login agian..
    thank you,
    chiranjeevi.
    public void doContent(IPortalComponentRequest request, IPortalComponentResponse response)
        {try
                      String url = "http://www.xxxxxxxxxxxxx.com/gold_online/validate.asp";
                      //Here, calling the timberline comes into place.
                       HttpClient client = new HttpClient();
                        PostMethod method = new PostMethod (url);
                        method.setFollowRedirects(false);
                        method.addParameter( "code","xxxxxxx");
                        method.addParameter( "upass", "xxxxxx" );
                                  int statusCode = client.executeMethod( method );
                        if( statusCode != -1 ) {
                             // The Status code for this first request is 302..which is a redirect with the redirect path
                             Header locationHeader = method.getResponseHeader("location");
                             Header cookie = method.getResponseHeader("set-cookie");
                             String redirectedURL = locationHeader.getValue();
                             String host = "http://www.xxxxxxxxxxxxxx.com/gold_online/";
                             redirectedURL = host+redirectedURL;
                             GetMethod method2 = new GetMethod (redirectedURL);
                             method2.setFollowRedirects(false);
                             method2.setRequestHeader("cookie",cookie.getValue());
                             method2.addRequestHeader("Accept", "image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, /");
                             int statuscode2 = client.executeMethod( method2);
                             String contents  = method2.getResponseBodyAsString();
                             // Converting the Relative URLs to Absolute URLs
                             contents = replace (contents,"src=\"","src=\""+host);
                             contents = replace(contents,"href=\"","href=\""+ host);
                             Cookie ck = new Cookie("cookie", cookie.getValue()) ;
                             //adding the cookie to the response...
                             response.addCookie(ck);
                             response.write(contents);
                          method.releaseConnection();

    Hi Manish,
    first, welcome on SDN! About your question:
    The URL iView in SP9++ has been reported quite instable from different sides (just do a look on "URL iView" within this forum). The alternative for the aim you have is to use the good "old" application integrator iView, which behaves very stable and will do what you want without hesitating...
    Also see URL iView and HTTP System - SSO to web app
    Hope it helps
    Detlev
    PS: Please consider to reward point for helpful answers on SDN. Thanks in advance!

  • Protocol 'form-post' not available

    We have developed a webservice using Weblogic Workshop 8.1 service pack 2. It has
    been working very well. It's been in production for a couple of months now. We
    are moving to a new environment where everything is clustered. I have changed
    nothing on my ear, but I now get back the following error when I try to call the
    service.
    Any Idea's?
    <?xml version="1.0" encoding="utf-8" ?>
    <error>
    <faultcode>JWSError</faultcode>
    <faultstring>java.lang.RuntimeException: Protocol 'form-post' not available on
    this operation.</faultstring>
    <detail>
    java.lang.RuntimeException: Protocol 'form-post' not available on this operation.
    </detail>
    </error>

    Hi Lomeus,
    There is a "How do I" [1] on setting up the cluster that may be of
    value. RU using the cluster name? Also see the docs here [2].
    HTH,
    Bruce
    [1]
    http://edocs.bea.com/workshop/docs81/doc/en/workshop/guide/deployment/howClusterDeployment.html
    [2]
    http://e-docs.bea.com/wls/docs81/cluster/setup.html
    Lomeus Cloete wrote:
    >
    We have developed a webservice using Weblogic Workshop 8.1 service pack 2. It has
    been working very well. It's been in production for a couple of months now. We
    are moving to a new environment where everything is clustered. I have changed
    nothing on my ear, but I now get back the following error when I try to call the
    service.
    Any Idea's?
    <?xml version="1.0" encoding="utf-8" ?>
    <error>
    <faultcode>JWSError</faultcode>
    <faultstring>java.lang.RuntimeException: Protocol 'form-post' not available on
    this operation.</faultstring>
    <detail>
    java.lang.RuntimeException: Protocol 'form-post' not available on this operation.
    </detail>
    </error>

  • Policy agent 2.1 in iis 5 and win 2000 form post

    hi,
    i am facing a typical issue with policy agent 2.1 in windows 2000 iis 5..here is the problem:-
    when ever we try to do a html form post, we get a http 200 response back with a blank screen "ok" written on it.
    there is nothing interesting in the logs ... when i completely uninstall the agent it works fine...even if i put the not_enforced_list=* it has the same issue...
    any help is highly appreciated.

    changed the notificationenabled=true which resolved the problem

  • Cannot read any form posted data

    I create a web server :
    import java.io.BufferedReader;
    import java.io.InputStream;
    import java.io.InputStreamReader;
    import java.net.ServerSocket;
    import java.net.Socket;
    public class TestWeb extends Thread {
        Socket soc;
        ServerSocket server;
        InputStream is;
        BufferedReader br;
        public void run() {
            try {
                while (true) {
                    soc = server.accept();
                    if (soc!=null)
                    is = soc.getInputStream();
                    br = new BufferedReader(new InputStreamReader(is));
                    String line = "";
                    while (line!=null) {
                        line = br.readLine();
                        if (line==null) continue;
                        System.out.println(line);
            } catch (Exception ex) {
                System.out.println(ex.toString());
        public TestWeb() {
            try {
                server = new ServerSocket(80);
            } catch (Exception ex) {
                System.out.println(ex.toString());
        public static void main(String[] arg) {
            try {
                new TestWeb().start();
                System.in.read();
            } catch (Exception ex) {
                System.out.println(ex.toString());
    }It can read the header when someone connect to this server
    However, it cannot read any form posted data.
    Does anybody have any idea?
    The following is the html source that i use in a browser to connect to the test server
    <HTML><BODY>
      <CENTER><H1><FONT COLOR=BLUE><B>Test</B></FONT></H1></CENTER>
      <HR>
      <FORM METHOD="POST" ACTION="http://127.0.0.1">
        <INPUT TYPE=TEXT VALUE="abcde">
        <SELECT>
          <OPTION VALUE="1">1</OPTION>
          <OPTION VALUE="2">2</OPTION>
        </SELECT>
        <INPUT TYPE=SUBMIT>
      </FORM>
    </BODY></HTML>

    I would expect the form data posted to be received. For example, the user chooses the option value and the text input value.
    This test is hang just after receiving the header information and no parameters collected.

  • How to do simple form post to payment gateway from SharePoint 2010 list form OR InfoPath 2010 Web Form?

    Working on a SharePoint 2010 Ent extranet site where parents of students can submit field trip permission forms and make payment at same time (optionally if fees involved).  Was wondering if someone could advise (or point me to resource on) best way
    to do a simple form post to an external payment gateway?  Would be from InfoPath web form OR SharePoint 2010 list form.
    Any guidance would be appreciated.
    Trevor

    you may create a custom visual web part for this:
    http://www.codeproject.com/Articles/152280/Online-Credit-Card-Transaction-in-ASP-NET-Using-Pa

  • Portal URL's and Form Posting

    When I use the following url in a form POST method, I receive a "page cannot be found" error when I click submit, but if I go directly to the page by entering the url in my browser, it works. Why is that?
    http://matrix0.dynamex.com:7778/pls/portal/url/page/dxnet_jsps/cr_submit?test=1
    How do I call another page in Portal through a form POST method using JSP?

    Hello Angela,
    you should find everything you need in :
    - the pdk-java sample 'event form' (eventform.jsp and publicparam.jsp)
    - the pdk articles
    http://portalstudio.oracle.com/pls/ops/docs/FOLDER/COMMUNITY/PDK/ARTICLES/ADDING.PARAMETERS.EVENTS.TO.PORTLETS.HTML
    (explained source code of the event form sample)
    http://portalstudio.oracle.com/pls/ops/docs/FOLDER/COMMUNITY/PDK/ARTICLES/primer.portlet.parameters.events.html
    (what to do in portal once your jsp-application is running)
    For your jsps, you'll know how to create the events, th event's parameters, how to call the htmlFrormActionLink() method, and finally get back the params from the request.
    Else, to create a link to a page, use the constructEventLink() in the EventUtils class (see API DOC deployed with JDPK on your OC4J)
    Hope this helps.
    Jean-Roch

  • How do I clear the parameter after form post?

    Hi. I am learning my first JSP and was trying to do a form post. However, I found that after successfully submit to the database. If I press F5 (Refresh) from browser, the data will be re inserted into database. How could I clear the parameter (action) after data insert. My code structure is as follow.
    Thank you.
    <%@ page import="java.sql.*" %>
    <%! Connection conn;
    PreparedStatement stmtInsert;
    public void jspInit() {
    try{ ... }catch(SQLException e){}
    catch(ClassNotFoundException e){}
    public void jspDestroy() {...}
    %>
    <% if (request.getParameter("action") == null ) { %>
    <H2>Data Entry:</H2>
    <FORM METHOD="post" ACTION="<%= request.getRequestURI() %>">
    <INPUT TYPE="submit" NAME="Submit" VALUE="Submit">
    <INPUT TYPE="reset" NAME="Reset" VALUE="Reset">
         <INPUT TYPE="hidden" NAME="action" VALUE="insert">
    </FORM>
    <% } else if (request.getParameter("action").equals("insert")) { %>
    <%
    try{
    synchronized(stmtInsert){
    stmtInsert.executeUpdate();
    out.print("<br> Room has been inserted successfully");
    // once successful...how could I change the action to null?
    } catch (SQLException e){
    %>

    http://forum.java.sun.com/thread.jsp?forum=45&thread=78925

  • Xsql:delete-request key-columns has to be form posted data?

    I am trying to link a hyperlink "delete" on a table to a page "jobs-list-delete.xsql?jobnumber={JOBNUMBER}". When I use:
    <form method="post" action="jobs-list-delete.xsql?jobnumber={JOBNUMBER}">
    <input type="submit" value="delete"/>
    </form>
    it worked fine. but I want to use "delete" as a hyperlink instead of a button, so I tried the following:
    Delete
    unfortunately, it didn't work with the above hyperlink.
    I would like to know if xsql:delete-request key-columns value has to be form posted data instead of a query string in an URL from a hyperlink. Is there any way to work around this?
    The code I used in jobs-list-delete.xsql is as follows:
    <xsql:delete-request key-columns="jobnumber" table="jobs" transform="request-to-InsertJob.xsl"/>
    Thanks...
    Wenqi Dwyer

    <xsql:delete-request> works with a posted XML request or a POST'ed HTML form.
    To delete things with a simple HTTP GET, you can use <xsql:dml> and a DELETE statement.

  • Read of HTTP Request POST parameters failed:Read timed out

    Hi !
    Any one seen this exception . any ideas of the cause?
    java.lang.RuntimeException: Read of HTTP Request POST parameters failed: Read timed out
    at org.apache.catalina.connector.HttpRequestBase.parseParameters(HttpRequestBase.j ava:665)
    at org.apache.catalina.connector.HttpRequestBase.getParameterValues(HttpRequestBase.java :737)
    at org.apache.catalina.connector.RequestFacade.getParameterValues(RequestFacade.java:170 )
    Thanks,

    Assuming there is nothing wrong with
    org.apache.catalina.connector.HttpRequestBase.parseParameters
    I can only think of 2 things:
    1. The timeout is set for an extremely short time in the Apache settings (server.xml&#51032;)
    2. The client application is sending the POST verry slow or incorrect. For example the
    client says that the POST is 500 long than sends 200 and leaves the connection open.
    You can try and post the following:
    request.txt:
    POST /somePath/somefile.js HTTP/1.1
    Host: localhost:44
    User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7.5) Gecko/20041217
    Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
    Accept-Language: en-us,en;q=0.5
    Accept-Encoding: gzip,deflate
    Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
    Keep-Alive: 300
    Connection: keep-alive
    Content-Type: application/x-www-form-urlencoded
    Content-Length: 45
    depreciatedButWontPostWithoutAName=some+valueThe client sending the request:
    import java.io.*;
    import java.net.*;
    import java.io.DataOutputStream;
    import java.applet.Applet;
    public class appTest extends Applet implements Runnable {
         public static final int HTTP_PORT = 80;
         public static final String hostName = "localhost";
         public void run() {
              try{
                   InetAddress addr = InetAddress.getByName(hostName);
                   Socket s = new Socket(addr,HTTP_PORT);
                   BufferedWriter wr = new BufferedWriter(new OutputStreamWriter(s.getOutputStream(), "UTF8"));
                   s.setSoTimeout(2000);
                   File fileToSend = new File("request.txt");
                   FileInputStream fleHTML = new FileInputStream(fileToSend);
                   StringBuffer sbHTMFile = new StringBuffer();
                   int b = fleHTML.read();
                   while(b!=-1){
                        sbHTMFile.append((char) b);
                        b = fleHTML.read();
                   wr.write(sbHTMFile.toString());
                   wr.flush();
                   BufferedReader rd = new BufferedReader(new InputStreamReader(s.getInputStream()));
                   String line;
                   while ((line = rd.readLine()) != null) {
                        System.out.println(line);
                   wr.close();
                   rd.close();
                   } catch (Exception e) {
                        e.printStackTrace();
         public void init(){
              new Thread(this).start();
         public appTest(){
              new Thread(this).start();
         // main program
         public static void main(String argv[]) throws Exception {
              new appTest();
    }In appTest.java change HTTP_PORT to the port you need and hostName to the
    hostname you need.
    In request.txt change the /somePath/somefile.js to the location you desire.
    And change Host: localhost:44 to the hostname and post you desire.

  • HTTP Status 405 - HTTP method POST is not supported by this URL

    dear all
    can u solve my problem.am getting the *"HTTP Status 405 - HTTP method POST is not supported by this URL"* msg from the browser when i press the search button in my form.plz suggest me the solution for my fault.these are the following html,xml,class files:
    search.html*
    <html>
    <head>
    <title>Search Page</title>
    </head>
    <body>
    <p align="center"><font size="6" color="#0000FF"><b>Search Module</b></font></p>
    <p align="center"> </p>
    <center>
    <form method="POST" action="./emp">
    <table border="1" width="43%">
    <tr>
    <td width="50%">
    <p align="right">Employee Name</td>
    <td width="50%"><input type="text" name="empname" size="36"></td>
    </tr>
    <tr>
    <td width="100%" colspan="2">
    <p align="center"><input type="submit" value="Search" name="B1"></td>
    </tr>
    </table>
    </form>
    </center>
    </body>
    </html>
    web.xml*
    <web-app>
    <servlet>
    <servlet-name>jdbc</servlet-name>
    <servlet-class>searchModule</servlet-class>
    <init-param>
    <param-name>driver</param-name>
    <param-value>sun.jdbc.odbc.JdbcOdbcDriver</param-value>
    </init-param>
    <init-param>
    <param-name>url</param-name>
    <param-value>jdbc:odbc:first</param-value>
    </init-param>
    <init-param>
    <param-name>user</param-name>
    <param-value>scott</param-value>
    </init-param>
    <init-param>
    <param-name>pass</param-name>
    <param-value>tiger</param-value>
    </init-param>
    </servlet>
    <servlet-mapping>
    <servlet-name>jdbc</servlet-name>
    <url-pattern>/emp</url-pattern>
    </servlet-mapping>
    <welcome-file-list>
    <welcome-file>search.html</welcome-file>
    </welcome-file-list>
    </web-app>
    SearchModule.java*
    import java.util.*;
    import java.io.*;
    import java.sql.*;
    import javax.servlet.*;
    import javax.servlet.http.*;
    public class searchModule extends HttpServlet
    Connection con;
    public void init() throws ServletException
    String d=getInitParameter("driver");
    String u=getInitParameter("url");
    String us=getInitParameter("user");
    String pwd=getInitParameter("pass");
    try
    Class.forName(d);
    con=DriverManager.getConnection(u,us,pwd);
    catch(ClassNotFoundException e)
    System.out.println(e);
    catch(SQLException e)
    System.out.println("Unable to establish the connection");
    }//init
    public void doGet(HttpServletRequest req,HttpServletResponse res) throws ServletException,IOException
    String empname=req.getParameter("empname");
    res.setContentType("text/html");
    PrintWriter pw=res.getWriter();
    try
    pw.println("<html><body><center>");
    Statement st=con.createStatement();
    String sql="select * from employee where empname="+empname;
    ResultSet rs=st.executeQuery(sql);
    if(rs.next())
    pw.println("<h2>Employee Details</h2>");
    pw.println("<table border=1>");
    pw.println("<tr><th>Employee No.</th>");
    pw.println("<th>Employee Name</th>");
    pw.println("<th>Designation</th>");
    pw.println("<th>Department</th>");
    pw.println("<th>Salary</th>");
    pw.println("</tr><tr>");
    pw.println("<td>"+rs.getInt(1)+"</td>");
    pw.println("<td>"+empname+"</td>");
    pw.println("<td>"+rs.getString(3)+"</td>");
    pw.println("<td>"+rs.getString(4)+"</td>");
    pw.println("<td>"+rs.getInt(5)+"</td>");
    pw.println("</tr></table>");
    else
    pw.println("<h2>Employee Record Not Found</h2>");
    pw.println("</center></body></html>");
    pw.close();
    rs.close();
    st.close();
    catch(SQLException e)
    System.out.println(e);
    }//doPost
    public void destroy()
    if(con!=null)
    try
    con.close();
    catch(Exception e)
    System.out.println("Connection Closed");
    }//destroy
    }//searchModule
    in control panel i selected System DNS and created the name as first and driver as Microsoft ODBC for Oracle
    plz suggest me the solution where i committed mistake.

    <form method="*POST*" action="./emp">
    public void doGet (HttpServletRequest req,HttpServletResponse res) throws ServletException,IOException
    HTTP method POST is not supported by this URL

Maybe you are looking for

  • How to deal with LONG data type in RTF template

    Hi, I'm developing a PO request report in which I should print some attachments. The attachments are stored in the database in table fnd_attachments_long_text in column long_text which data type is LONG. In my case the content of the column long_text

  • M93p problem Display Port

    Dear all, i've purchase a M93p pc and when i try to connect it to a monitor or tv with the adapter cable DP - HDMI the monitor/tv says "no input signal", but works if i connect the vga port. The M93 has the Intel HD 4600 videocard. Thanks in advance

  • Rescuing Corrupt .mov file

    My Mac had a kernel panic TWO DAYS into rendering a flythrough. Even though the application I'm using saves the .mov frame-by-frame, the resultant .mov can't be opened: "Error Opening Movie: The movie could not be opened". The file is 240MB, so I'm a

  • Software error in Adobe Reader when printing

    When printing a scan from a book (A3 format horisontal) the Print dialog offers a preview where I can see the selection to be printed. Left side of the horisontal A3 (which is a vertical A4). When rotating the page 180º I can turn the right side of t

  • Where can I download Flex Builder 3 installer?

    My installation of Flex Builder 3 has somehow become corrupt and now I can't import web service (WSDL) files, it returns the error: Unable to load the file /.metadata/.plugins/com.adobe.flexbuilder.webservices/wsdl.xml I guess that this will probably