4 Replies Latest reply: May 6, 2010 12:04 AM by Hari_639 RSS

    APEX API to get page HTML

    Hari_639
      Hi All,

      Is there any APEX API to get HTML for a page if we provide page number, session and application id?

      I have tried with "f" and "apex_030200.f" but its giving following error!
      no function with name 'F' exists in this scope ORA-06550
      Any hints/help would be much appreciated.

      Regards,
      Hari
        • 1. Re: APEX API to get page HTML
          jariola
          Hi,

          What you like do with HTML ? Download it, store it to table ...

          Basically region pull method you can get other page HTML. I do not know how to get some other session page HTML, if you need to that

          Br,Jari
          • 2. Re: APEX API to get page HTML
            Hari_639
            Jari,

            I'm trying to implement "Pop-up overlay modal". I have searched lot of available jquery plug-ins over internet but there are failing to meet our requirements. So I have started to create my own.

            For this I need to get the page content using AJAX (from the same session) and insert this into div and display the div as pop-up overlay. The page content would be dynamic. So I can't store it in database table and fetch it.

            I tried displaying iframes in div but again I'm getting some problems with scroll bars, height and width of frame.

            Thanks,
            Hari
            • 3. Re: APEX API to get page HTML
              jariola
              Hi,

              Check Carl's region pull demo.
              You can pull whole page HTML
              http://apex.oracle.com/pls/otn/f?p=11933:48

              Br,Jari

              Edited by: jarola on May 5, 2010 8:54 PM

              I did sample to pull whole page
              http://apex.oracle.com/pls/otn/f?p=40323:49
              It pull page 1

              In sample page HTML header
              <script type="text/javascript">  
              function dhtml_GetPage(p){
               if(!p){p=1}
               var a=new htmldb_Get(null,$v('pFlowId'),null,p);  
               var r=a.get(null,'<body>','</body>');  
               a=null;  
               $x('ReportDrop').innerHTML=r;  
               return;  
              }  
              </script> 
              HTML region source
              <div id="ReportDrop"></div>
              Button URL target
              javascript:dhtml_GetPage()
              Hope this helps

              Br,Jari
              • 4. Re: APEX API to get page HTML
                Hari_639
                Thanks Jari!

                Cheers
                Hari