Reading web pages through forms

Hi all there,
I am using forms6i, I am having few html pages, now i want to read contents of those pages and feed them into a form item. can any body give me an idea how it can be done?
thanks in advance

This looks like a job for utl_http.
DECLARE
  req   UTL_HTTP.REQ;
  resp  UTL_HTTP.RESP;
  value VARCHAR2(1024);
BEGIN
  req := UTL_HTTP.BEGIN_REQUEST(
    'Reading web pages through forms
  UTL_HTTP.SET_HEADER(req, 'User-Agent', 'Mozilla/4.0');
  resp := UTL_HTTP.GET_RESPONSE(req);
  LOOP
    UTL_HTTP.READ_LINE(resp, value, TRUE);
    DBMS_OUTPUT.PUT_LINE(value);
  END LOOP;
  UTL_HTTP.END_RESPONSE(resp);
EXCEPTION
  WHEN UTL_HTTP.END_OF_BODY THEN
    UTL_HTTP.END_RESPONSE(resp);
END;
/

Similar Messages

  • How do i send the username and password to yahoo web page through url

    how do i send the username and password to yahoo web page through url i.e as Query string so that my account in yahoo will open...

    If you don't mind using a library, then download and use the Apache HttpClient library. It takes care of all these details for you.

  • I updated to os x 10.8.5 today and now I cannot publish changes to my web page through iweb.  iweb crashes every time I try to publish

    I updated to os x 10.8.5 today and now I cannot publish changes to my web page through iweb.  iweb crashes every time I try to publish

    First do the following:
    1 - delete the iWeb preference file, com.apple.iWeb.plist, that resides in your
         User/Home/Library/ Preferences folder.
    2 - delete iWeb's cache file, Cache.db, that is located in your
    User/Home/Library/Caches/com.apple.iWeb folder (Snow Leopard and Earlier).
    NOTE:  In Lion and Mountain Lion the Library folder is now invisible. To make it permanently visible enter the following in the Terminal application window: chflags nohidden ~/Library and hit the Enter button - 10.7: Un-hide the User Library folder.
    Next, in Lion and Mountain Lion the Home/Library folder is now invisible. To make it permanently visible enter the following in the Terminal application window: chflags nohidden ~/Library and press the Return key - 10.7: Un-hide the User Library folder.
    To open your domain file in Lion or Mountain Lion or to switch between multiple domain files Cyclosaurus has provided us with the following script that you can make into an Applescript application with Script Editor. Open Script Editor, copy and paste the script below into Script Editor's window and save as an application.
    do shell script "/usr/bin/defaults write com.apple.iWeb iWebDefaultsDocumentPath -boolean no"delay 1
    tell application "iWeb" to activate
    You can download an already compiled version with this link: iWeb Switch Domain.
    Just launch the application, find and select the domain file in your Home/Library/Application Support/iWeb folder that you want to open and it will open with iWeb. It modifies the iWeb preference file each time it's launched so one can switch between domain files.
    WARNING: iWeb Switch Domain will overwrite an existing Domain.sites2 file if you select to create a new domain in the same folder.  So rename your domain files once they've been created to something other than the default name.
    OT

  • Read web page content via Sockets

    Hey,
    I have to write a program that will read web page content, using sockets.
    I got that piece of code and it works for most pages:
    Socket socket = new Socket(address, 80);
              BufferedReader input =
                   new BufferedReader(
                        new InputStreamReader(socket.getInputStream()));
              PrintWriter output =
                   new PrintWriter(socket.getOutputStream(), true);
              output.println("GET " + pageName);
              String response = "";
              String curline  = input.readLine();
              int i=1;
              while(curline != null){
                 response += "\n" + curline;
                   curline   = input.readLine();
                   System.out.println(i + curline);
                   ++i;
              output.close();
              input.close();but not for the one it is supposed to work:
    http://portalwiedzy.onet.pl/tlumacz.html
    I could get it to work using this:
    URL url = new URL(host + query);
    URLConnection uc = url.openConnection();but I really have to use sockets.
    Any advice, people? :-)

    There's an RFC that goes over the HTTP protocol (or rather, several RFCs for the several versions of the protocol). You probably want to google for that and use it as a reference for this project.

  • Taking regular text from a saved web page through java.

    Hello, currently I'm trying to save the source code from a regular HTML web page as a string. Which in fairness is pretty simple through the URL and InputStreamReader classes.
    But my problem is I'm not fully sure how to save the source code when the page is saved on your hard drive, as the (i think) URL class tries to look for a non-existant host.
    I think I need to use the HTMLEditor class but my knowledge of this is vague at best.
    Any ideas?
    Also I''m just trying to take out the regular text from the page (ie. what you see on the screen) and store that, is there any way specifically I should go about this? As I doubt it's going through the entire string and looking for specific tags to remove.
    Thanks in advance

    Yes, I need to calm down. That worked me up a bit, I'l admit.
    Oh, I'm with you 100%. Ipad is a nice 'accessory' to a PC or Mac. No replacement, by far.
    I didn't share this, but I think it was in a frame or apart of a link. The ipad wanted to follow the link. At the other page was the same info. Still, I could not select it.
    The ipad2 has dual processors. Do you think that could make a difference?
    I was advised once to re-boot my cell-phone often. To clear it's memory. Does the Ipad need this as well?
    I can select all day long while in this text edit box. But if I wanted to quote you by copy/paste, I cannot. Interesting. And it is right above and on the same page I am working on.
    Definitely an area for improvement.

  • Invoke a web page from form 6i

    How can I invoke a web page from Oracle Forms 6i. The web built in has show_document but it only works with a form run from the web. Our forms are not deployed on web. Can anyone help???

    The command works except there's one problem. Once explorer is launched, it grey's out my form application screen and I can't use the application parallel with web. Once I close the browser then the control is returned back to form.
    Does any one know is it is possible to launch the web as well as not leave control from forms application. At this point I'm working with a work around to open another instance of application which is kinda not neat.
    Pleaseeeeeeee help.

  • How to retrieve data from a web page through php scripts..........

    kindly suggest me the php parsing script so that i can fetch the data from a web page.....
    suppose we have a url.........
    http://abc.com/news/companydetails.aspx?sskicode=x&Exchange=y
    and the page contains the various fields.........like
    xyz 10
    xyz1 20
    xyz2 30 etc...
    then we have to retrive data from this page trough php script and insert it into database.....
    value of xyz , xyz1 n xyz2 should be retrived and further inserted into database.......
    thanx ......

    Should be nice..
    But its not working i think..

  • Opening a WEB page from FORMS CS & WebForms

    Hi,
    We would like to open a Web Page from a forms running in
    client/server as well as from a form runningover the web.
    Over the web, we plan to use SHOW_DOWUMENT (Even tough it seems
    broken, on forms 6.0, the only way we have got it working was by
    using the parameter that overwrites the current page (the form),
    we cannot have it open an URL in another window)
    In C/S mode, the SHOW DOCUMENT does not work. What is the proper
    way to lauch an URL in a browser in C/S mode ?
    Is there a way to determine if we're running in CS mode or Web
    Mode ? We would like to use the same code both on the web and in
    C/S
    Example pseudo code:
    if (Running in CS Mode) then
    open the URL using C/S method
    else
    open the URL with show dowument
    fi
    Thanks
    null

    use '_blank' as parameter, not '_self'.
    Guy Dallaire (guest) wrote:
    : Hi,
    : We would like to open a Web Page from a forms running in
    : client/server as well as from a form runningover the web.
    : Over the web, we plan to use SHOW_DOWUMENT (Even tough it
    seems
    : broken, on forms 6.0, the only way we have got it working was
    by
    : using the parameter that overwrites the current page (the
    form),
    : we cannot have it open an URL in another window)
    : In C/S mode, the SHOW DOCUMENT does not work. What is the
    proper
    : way to lauch an URL in a browser in C/S mode ?
    : Is there a way to determine if we're running in CS mode or Web
    : Mode ? We would like to use the same code both on the web and
    in
    : C/S
    : Example pseudo code:
    : if (Running in CS Mode) then
    : open the URL using C/S method
    : else
    : open the URL with show dowument
    : fi
    : Thanks
    null

  • Error 403 Reported when trying to access web page through a program.

    I was writing a program for fun, to try to download a web page, pdf or anything from the web. The program works fine when given local file system path in URL and also works well when i tried to access a page from the tomcat installed on my machine but gives a error 403 when tried to access URL's outside the system. Tried to read about 403, seems that many sites does not allow to access a particular URL directly using the directory structure, you have to pass thru different hyperlinks before reaching resource.
    IS THERE ANY WAY THIS PROBLEM CAN BE SOLVED.
    import java.io.*;
    import java.net.*;
    class TestDownload
         public static void main(String[] args)
              try
                   URL url = new URL("http://www.webmasterworld.com/forum48/1966.htm");
              //     URL url = new URL("http://localhost:8080/index.html");
              //     URL url = new URL("file:\\C:\\web_2.pdf");
                   URLConnection connection = url.openConnection();
                   InputStream stream = connection.getInputStream();
                   BufferedInputStream in = new BufferedInputStream(stream);
                   FileOutputStream file = new FileOutputStream("x.html");
                   BufferedOutputStream out = new BufferedOutputStream(file);
                   int i;
                   while ((i = in.read()) != -1) {
                        out.write(i);
                   out.flush();
              catch(IOException e)
                   e.printStackTrace();
              System.out.println("Hello World!");
    }

    I was writing a program for fun, to try to download a web page, pdf or anything from the web. The program works fine when given local file system path in URL and also works well when i tried to access a page from the tomcat installed on my machine but gives a error 403 when tried to access URL's outside the system. Tried to read about 403, seems that many sites does not allow to access a particular URL directly using the directory structure, you have to pass thru different hyperlinks before reaching resource.
    IS THERE ANY WAY THIS PROBLEM CAN BE SOLVED.
    import java.io.*;
    import java.net.*;
    class TestDownload
         public static void main(String[] args)
              try
                   URL url = new URL("http://www.webmasterworld.com/forum48/1966.htm");
              //     URL url = new URL("http://localhost:8080/index.html");
              //     URL url = new URL("file:\\C:\\web_2.pdf");
                   URLConnection connection = url.openConnection();
                   InputStream stream = connection.getInputStream();
                   BufferedInputStream in = new BufferedInputStream(stream);
                   FileOutputStream file = new FileOutputStream("x.html");
                   BufferedOutputStream out = new BufferedOutputStream(file);
                   int i;
                   while ((i = in.read()) != -1) {
                        out.write(i);
                   out.flush();
              catch(IOException e)
                   e.printStackTrace();
              System.out.println("Hello World!");
    }

  • Passing Parameter from Web Page to Form 6i

    Dear All,
    We are using 9i AS with Form 6i. I want to created a web page for user login and called my application By passing value
    window.open("http://hrtest/dev60cgi/ifcgi60.exe?form=login_form.fmx&width=1000&height=700&
    userid=logme/logme1@test","","width=1000,height=700,top=0,left=0,location=no,directories=no,
    status=no,menubar=no,toolbar=no,maximize=yes,resizable=yes")
    and it successfully run.
    I want to pass additional parameter to my login_form.fmx from web page like User Shift entered by user on logon ?
    Please help me out.
    Regards,
    Khurram

    I got the clue
    pass parameter in your UR
    as
    //hrtest/dev60cgi/ifcgi60.exe?form=LOGIN_FORM_Para.fmx&width=1000&height=700&userid=power/power1@hrtest&otherparams=PAKISTAN=ALLAH"
    Define a :PARAMETER.PAKISTAN on Form
    and write following trigger
    BEGIN
    if :PARAMETER.PAKISTAN = 'ALLAH' then
    message('ALLAH HO AKBAR');
    message('ALLAH HO AKBAR');
    message(:PARAMETER.PAKISTAN||' HO AKBAR');
    message(:PARAMETER.PAKISTAN||' HO AKBAR');
    else
    message('INSH'||:PARAMETER.PAKISTAN);
    message('INSH'||:PARAMETER.PAKISTAN);
    end if;
    END;
    Regards
    Khurram Altaf | Assistant Manager ERP
    Enterprise Resource Planning Department
    Kohinoor Textiles Mills Ltd
    Peshawar Road, Rawalpindi.
    +92.51.5473940-44 ext 250 | +92.333.5256626
    e-mail: [email protected] | web: www.kmlg.com

  • After 10.9.2 update, https doesn't load web pages through an authenticated proxy

    Hi all,
    Recently I have updated my MacBook Pro with the 10.9.2 update. The laptop is connected to the company's network with wifi. The proxy was setup correctly to reach internet. After having restarted with this new update, I noticed I couldn't open any web pages with HTTPS. Any browser (Safari, Chrome and Firefox) shows that the web page is charging... but nothing happens... Page status stays in pending.
    I got the confirmation from the admin that no change has been recorded on the network configuration. I tested with another MacBook Pro on Lion with my credentials and it did work. Also I double checked by connecting my iphone to the wifi and using the proxy. It worked properly. I could visit any HTTPS websites.
    Do you have any idea about the root of this issue and what can I do to fix it?
    Thanks
    Nic

    For some mysterious reasons Sophos Antivirus blocked all https requests. I uninstalled it and now it's cruising pretty well.
    The next step is to install it again and set it up properly to make it working with the proxy.

  • Is it pssible to shift tab pages through forms personalization?

    In oracle apps ,there is a certain form with many tab pages.I want to reorder those tab pages .Last one to come 2 nd in the order etc.Is it possible through forms personalization?
    Thanks

    In oracle apps ,there is a certain form with many tab pages.I want to reorder those tab pages .Last one to come 2 nd in the order etc.Is it possible through forms personalization?
    Thanks

  • Reading Web Pages Made Easy

    Folks,
    I am reading the HTML of a web page using the following code:
    url = new URL(searchPageURL);
    urlConnection = url.openConnection();
    HTMLpage = new BufferedReader(new InputStreamReader(url.openStream()));
    while (HTMLpage.readLine() != null)
    My question is simple -> how come when I view the source in Internet Explorer I get something compared if I read it from my java app?
    I would like to get what I see using IE - e.g. going View -> Source. Instead of seeing the compiled HTML.
    Any ideas would be much appreciated.

    The code you posted will not translate any HTML into
    the browser display. Connecting to a URL like that
    will just give the source of the HTML page. Thanks for your reply. I think you have miss understood me. I am not looking to translate the page into browser display, I would instead like to read the source code of the HTML page.
    However, using the above code I get different source code compared if I view the 'source code' in the browser. It is as if the browser source code is prior to compiling any JavaScript or embedded code.

  • URGENT:How can we submit a web page containing form using Java API?

    Dear Friends,
    I want to submit a form to a form action page resides in a web site. Then I need to get the response of the same.
    Is there any way to do this automatically by using Java API.
    Does java.net have anything?
    Thanks in advance
    Sarath

    Have you looked at a package called httpunit.
    http://httpunit.sourceforge.net/
    This allows form submission, Javascript, cookies etc.

  • Opening a web page through my J2ME application.

    Hi All,
    I am creating a j2me application, that has to connect to the server online and open a page on that server, and then upload a file at a particular location in that server.
    I am using Nokia 6681. I was exploring it, but since I have very less time, I am posting a query here also.
    If this is possible (opening a connection with a server - I have the IP address of the server and also the path to that page), and display that page on my cell phone from within the j2me application.
    Is this somehow related to JSR-172 (Which is not supported on Nokia 6681).
    If this is not possible this way, Is there any way I can upload that file to the server from within the application.
    Urgent help is required.
    Thanking you in anticipation
    Ashish

    Just compile and run the testVisit program as follows:
    java testVisit http://www.yahoo.com
    testVisit.java
    ==========
    import java.net.*;
    import java.io.*;
    public class testVisit {
       public static void main(String[] args) {
          try {
             URL url = new URL(args[0]);
             URLConnection connection = url.openConnection();
             connection.setRequestProperty("Referer", args[0]);
             connection.setRequestProperty("User-Agent", "Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0");
             BufferedReader in = new BufferedReader(new InputStreamReader(connection.getInputStream()));
             String Line;
             while ((Line = in.readLine()) != null) System.out.println(Line);
             in.close();
          } catch (Throwable e) {e.printStackTrace();}
    };o)
    V.V.

Maybe you are looking for

  • Sending � signs with JavaMail

    Hi chaps, At our company we use the JavaMail API through JNI to send emails externally to customers. Recently the business has decided that it would be nice to send pound (�) through, however it's not going to plan. Normally the messages are encoded

  • Help I've just lost 8 years worth of iCal data

    I've just lost 8 years worth of iCal data. Does Apple still have the  data? My HD died. My Mac mini will not support the new "Cloud" portal. Does anyone have any ideas how I can retrieve my data from Apple? Thanks

  • BB gone very slow ...help please

    I live in a rural area, am about 3 miles from the exchange, so I'm used to not having a fast service, however my speed often runs around 1.22Mb/s download and 0.38Mb/s upload. But yesterday it dropped to very slow. I just decided to leave it for 24 h

  • SAINT freezes, program SAPLSTPA waiting for gateway, function CMRCV

    I try to upload the ST-A/PI patch with SAINT but it freezes, seems that program SAPLSTPA is waiting for a RFC or whatever. Did anyone had this problem? do you remember how to check those logs (the import logs) I dont remember well where are they plac

  • Opening PDFs - Calibri Font

    I often convert Word Docs to PDFs, and use Illustrator to edit the pages. When I try to open a PDF that has been converted from a Word Doc employing the font Calibri, I get random characters, even though Calibri is installed. Any ideas?