How to show an HTML page in a new browser window

Hi Everyone,
I am trying to show a page generated by some servlet in a new browser window when the button is clicked on the applet. I can accomplish that by using AppletContext as in:
myApplet.getAppletContext().showDocument(servletUrl, "_blank");
The only problem with this is that I don't have any control over how the new browser window is displayed. Using JavaScript I can set size, hide toolbar and address bar, etc. But how can I hide address bar on a new browser window generated in this scenario?
I tried to call intermediate servlet from my applet which in turn generates a new window by writing out JavaScript code. This way I lose my previous page with the applet even though a new window is displayed the way I wanted but I want this new browser window to act as a pop-up box and my applet page stay on screen. Also, is there a way to send a POST request from an applet by using AppletContext.showDocument() method?
Any help will be greatly appreciated!
Thanks in advance,
Y.M.

Did you ever figure out a solution for this? I too would like to open a new browser window to act as a pop-up box and my applet page stay on screen. If anyone has any thoughts on how to do this, please post! thanks.

Similar Messages

  • How to show an html page using JEditorPane in applet.

    I have never use jeditorpane with applet so i dont know how to show a html page.if you have some code or any example then please posted that.Thanks

    public class MyApplet extends JApplet{
        private JTextPane textPane = null;
        public void init(){
        HTMLEditorKit editorKit = new HTMLEditorKit();
        HTMLDocument  htmlDoc   = (HTMLDocument)editorKit.createDefaultDocument();
        textPane  = new JTextPane();
        textPane.setEditable(false);
        textPane.setEditorKit(editorKit);
        textPane.setContentType("text/html");
        textPane.setDocument(htmlDoc);
        Container c = getContentPane();
        c.add(new JScrollPane(textPane),    BorderLayout.CENTER);
        c.add(buttonPanel,                  BorderLayout.SOUTH);
        c.add(Box.createVerticalStrut(5),   BorderLayout.NORTH);     
        c.add(Box.createHorizontalStrut(5), BorderLayout.EAST);     
        c.add(Box.createHorizontalStrut(5), BorderLayout.WEST);
        public void setHtml(String html){
            // you should check the textpane's document to detrmine if there
            // is already text in there..if so, then clear the textpane text and then
            // set the new html...Note: JTextPane only show basic Html ..
            // not like a full blown browser
            textPane.setTextt(html);
            textPane.setCaretPosition(0);
    }

  • How to show a html page in a swing applet -- URGENT!!!

    Hi All,
    I'm trying to show a html page inside a swing applet... is it possible to do that?? if so is there any built-in classes available for that?? If anyone have some examples, plz help me with that....
    Thanks,
    Ragu

    i havent tested.. but this should work. i am no expert on these either, just to give you an example.. :-)
    JEditorPane ePane = new JEditorPane();
    HTMLEditorKit html = new HTMLEditorKit();
    ePane.setEditorKit(html);
    HTMLDocument htmld = new HTMLDocument();
    try{
    URL url = new URL("http://hcs.harvard.edu/~undercon/");
    InputStream ins = url.openStream();
    ePane.setDocument(htmld);
    html.read(ins,htmld, 0);
    this.getContentPane().add(new JScrollPane(ePane),BorderLayout.CENTER);
    catch(Exception e)
    e.printStackTrace();
    }

  • How to force external links to open in new browser window/tab?

    Greetings. I'm here because searching elsewhere kept coming up with references to javascript. I've created an interactive PDF with both internal and external links. It works just fine when viewed in either Acrobat or Reader. However, it is being downloaded to users' browsers and when they access the external URLs, the new sites replace the existing page in the same window.
    Is there a simple way for me to include an action in the PDF prior to distribution that will force it to open external URLs in a new browser window or tab?
    And for the record, I barely know how to spell Javascript, much less how to write or implement it. So if there is a simple solution, I hope you can also help walk me through the steps to implement it.
    Thanks a ton.

    There are two issues here:
    - How to do it using JS
    - How to do it in a non-Adobe browser plugin
    The first is pretty straight forward. You use a code like this, replacing the dummy URL with your own:
    app.launchURL("http://www.example.com", true);
    The second issue is more problematic, and in fact there isn't really a solution to it. If the plugin used supports this method then it will work, if not, then you're out of luck. Unfortunately, outside of the Adobe software I don't think that any other plugin supports it.

  • Link to another page in a new browser window

    Hey Guys,
    I wanted to know how to set up a link to another page that loads up in a new browser window.
    This what my code looks like:
    <!--
    htp.print('<center>' || :P1_11 );
    htp.print('
    --!>
    This works but the problem is that it goes straight to the login window and asks the user to login again and then it goes to the desired page. Is there a way to set up the link so it goes directly to the new page in a new browser without having the user to log in again?

    Have you tried using the #SESSION# substitution string in the URL instead of hard-coding the session ID into the link?
    By the way, why is so much of your stuff in anonymous blocks/procedures? Just curious.
    Earl

  • How to invoke a html file in a new browser

    how to invoke a new html file to be opened from an applet
    any help urgent

    hi,
    do the following
    URL url = null;
    try
         url = new URL("http://www.xyz.com");
    catch (MalformedURLException e)
          System.out.println("URL not correct " + e.toString());
    if (url != null)
           getAppletContext().showDocument(url,"_blank"); //shows the page in a new unnamed top level browser instance.
    }hope that helpz
    cheerz
    ynkrish

  • Making a hyperlink open the linked page in a new browser window

    Does anyone know if iWeb allows a way to create a hyperlink such that it will open a new browser window rather than navigating away from your site?
    Thanks for any and all help.
    Brian
    www.productionmax.com

    I've scoured the forums. It's just not in the software as of yet. This is best solution I could find:
    http://discussions.apple.com/thread.jspa?messageID=1629842&#1629842

  • How to fix bookmark icons from reappearing in new browser windows despite having bookmark deiconizer enabled (Mac Snow Leopard/Firefox 20.0).

    Ever since Firefox upgraded to 20.0, my enabled deiconizer doesn't work when I open a new browser window. Using Mac/Snow Leopard.
    I want those bookmark toolbar icons to disappear permanently! They are nothing but clutter.

    Thanks for the suggestions. I think my next move is to contact Mozilla/FireFox to complain about this change and see if it can be fixed. If not, then I'll probably just switch to Safari. I lose patience with companies/programmers who do things like this. When I had programmers reporting to me (before I retired a few years ago), I would never let them get away with this sort of nonsense. User flexibility was a requirement.

  • Opening remote page in new browser window

    Hi there,
    my applet used the browser window as its frame, that means there is nothing else but the applet. I need to call a page from the same server as the applet resides, but to display the page in a new browser window. The following code could do the job, but caused the browser to block the popup.
    applet.getAppletContext().showDocument(new URL
                            ("http://mydomain/mypage.jsp"),"_blank");I'm wondering whether I could access a servlet from my applet and let the servlet accomplish this and how to.
    It would be also of interest whether it is possible to do the same with a page from a remote server and triggering the client to display the page in a new window.
    Any help is highly appreciated.
    Thanks in advance.
    Stephan

    Sorry, mixed up my versions a bit. The following code doesn't open a new window.
    try {
                JSObject window;
                window = JSObject.getWindow(this);
                URL url = new URL(this.getCodeBase(), "mydomain/mypage.jsp");
                window.eval("window.open(" + url +")");
            catch (Exception e) {
                e.printStackTrace();
    }It doesn't do anything, instead I'm getting the following output in the trace:
    liveconnect: the url of the applet is http://localhost:29080 and the permission is = false
    liveconnect: JavaScript: UniversalBrowserRead enabled
    liveconnect: JavaScript: UniversalJavaPermission enabled
    liveconnect: JSObject::eval(window.open(http://localhost:29080/mydomain/mypage.jsp))
    liveconnect: the url of the applet is http://localhost:29080 and the permission is = falseI'm testing this code on Linux, FIrefox 1.5.0.3 and JDK1.5.0_07.
    What I'm doing wrong?
    Thanks.
    Stephan

  • Drill to link - How can integrate the new browser window inside the report

    Hi, I'm using Discoverer Plus/Viewer 10.1.2.48.18 and I just created successfully a "Drill to Link to an Internet Page" related to my field "Ticket Id"
    So, when, from Viewer, I select the link, a new tab from a new browser session is opend and I see all the details related to the Ticket Id chosen.
    This is right because on the manual is written:
    Discoverer behaves as follows: if you drill out to an Internet page, Discoverer displays the Internet page in a new browser window.
    Now my question is this: is there a way or a workaround to integrate the new browser window's content inside my report ?
    In other words, instead to see the all the Ticket id details (graphs included) in a new browser window, my customer asked me to see these details inside the same report, just below the field with the link.
    Any help will be appreciated
    Thanks
    Alex

    Hi, I'm using Discoverer Plus/Viewer 10.1.2.48.18 and I just created successfully a "Drill to Link to an Internet Page" related to my field "Ticket Id"
    So, when, from Viewer, I select the link, a new tab from a new browser session is opend and I see all the details related to the Ticket Id chosen.
    This is right because on the manual is written:
    Discoverer behaves as follows: if you drill out to an Internet page, Discoverer displays the Internet page in a new browser window.
    Now my question is this: is there a way or a workaround to integrate the new browser window's content inside my report ?
    In other words, instead to see the all the Ticket id details (graphs included) in a new browser window, my customer asked me to see these details inside the same report, just below the field with the link.
    Any help will be appreciated
    Thanks
    Alex

  • How to create a html page

    Hello,i am very new to dreamweaver 8,and i have searched
    everwhere possible on how to create a html page.My website has a
    navegation bar.And on the navegation bar it has links,like
    forums,your accounts,and etc,but thats already integrated with the
    website.Now i have an option in the admin area,wher i can create a
    new category so that it would show up in the navegation bar,and i
    have a drop down menu where i cans select what to put in that
    category.But also i have an option to put a external url,so that
    when they click on it,it will take them to where that link is
    directed.The point is that i asnt to make a category in the
    navigation menu that says Lirics.So that i can put lirics of songs
    and etc,and that when users click on that link it will take them to
    the lirics page..Do you guys understand?Sorry for the bad english,i
    am now quite good with it..

    The most eloquent description will do nothing for us. To get
    a solution to
    your problem, we must see your code. Can you upload the file
    and post a
    link to it, please?
    Murray --- ICQ 71997575
    Adobe Community Expert
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    http://www.dreamweavermx-templates.com
    - Template Triage!
    http://www.projectseven.com/go
    - DW FAQs, Tutorials & Resources
    http://www.dwfaq.com - DW FAQs,
    Tutorials & Resources
    http://www.macromedia.com/support/search/
    - Macromedia (MM) Technotes
    ==================
    "don_playboy" <[email protected]> wrote in
    message
    news:eaadi9$kjf$[email protected]..
    > well what i am trying to say is that i created a Folder
    named
    > Liricas(which is
    > lirics in spanish),on my ftp.Now since i created that
    folder in my ftp,it
    > will
    > show on my navegation menu control panel.But it will be
    blank since it has
    > nothing on it.Now what i want to do is,sicne i created
    that folder,and i
    > go to
    > my nav meny control panel and select it as a category it
    will show on my
    > navegation menu(the Liricas that is),but when u click it
    it has
    > nothing,since
    > it has no html or anything in the category.Now i want to
    create a html
    > page so
    > that i can put albums names,and under those albums name
    i want to create a
    > link
    > or category thats for lirics.So all this will be stored
    on the ftp.and
    > when
    > users click on the Liricas category on my navigation
    menu,it will take
    > them to
    > the liricas index page,which will show all the lirics...
    >
    >
    >
    >

  • In latest version of MF there`s missing button, which was in previous version: between buttons back/forward and the typing bar there used to be little flash, which showed few last pages I have just browsed. How can I restore it?

    In latest version of MF there`s missing button, which was in previous version: between buttons back/forward and the typing bar there used to be little flash, which showed few last pages I have just browsed. How can I restore it?

    If you mean the drop marker then you can still get the History of the Back and Forward buttons if any by either Left-Click and hold for a second or by Right-Clicking them.
    If you still want the drop mark there also then there is this Extension at https://addons.mozilla.org/en-US/firefox/addon/backforward-dropmarker/
    Also the abbreviation for Firefox is '''Fx'''

  • To show a html page from java application

    hi everyone,
    I am trying to show a html page through java application. What i tried is Runtime.getRuntime().exec("start url"); this shows it opens default browser. It works fine for win Nt but does not work on win98 or linux.
    Is there any other way of achieving the same?
    can anyone help me in this regard. I am in urgent need of it. any reply will appreciate.

    I hope this works.
    String urlName = "http://forum.java.sun.com";
    String browser = "iexplore "; //EXE file name --> for iexplore.exe
    Runtime.getRuntime().exec(browser+urlName);

  • How to create a HTML page like iView, thanks in advance!

    How to create a HTML page like iView, thanks in advance!
    I'm a newcomer, would you please tell me how to create a HTML page in WebDynpro ? In fact, i want create one welcome page which use html format and include some javascript.
    thanks again.

    jakinapallykrishna , thank you very much for you reply.
    The pdf file is a simple application, but i want know how create a view in HTML format (<HTML>... </HTML>), maybe use HTMLB control, i don't sure it.
    In fact, I need create a view in portal, some pictures in it, once mouse over one picture, it need change another picture replace old one. I don't know how to do it, just know it can be handled in HTML page. So, i need help.
    Thanks.

  • How to open a new browser window from a JSP page?

    Hi,
    I am picking up records from the database and displaying each record in a seperate text area field using the JSP code. I should be able to display the content ( available in the text area) in a seperate window if the user clicks on one icon.
    Is it possible to open a new browser window using JSP? If yes, how can I write information on the new browser window?
    Thanks in advance.

    Is it possible to open a new browser window using JSP?a JSP page is also an HTML page, this is client side stuff, you can do it with JavaScript.

Maybe you are looking for

  • Text and some images together in a scrolling effect

    Hi. All the tutorials I find about scrolling effects are just with simple text. And all the tutorials about images don't say anything about applying it together with text. I have a rather simple scrolling credits at the end of my video and wanted to

  • Oracle on Linux PPC

    Hi does anyone know of any plans to port Oracle to Linux on PPC? I have Mandrake 9.1 running on Apple XServers which I was considering using Collaboration Suite on.

  • Quick and easy 1 time lan file transfer [resolved sorta]

    I'm looking for a painless way to transfer files from a dead windows computer (that is now running knoppix) to an arch box that with an external USB.  I've looked at various howtos, and I know that there is plenty of reading material, but this is a o

  • IPhoto keyword don't seem to be working

    I've got some photos in iPhoto from vacations. They've got keywords of where they're from. If I type in "Myrtle" in spotlight, I get all of the pics from our trip to Myrtle Beach. I recently took a trip to Cunningham falls State Park in Maryland. I i

  • Wrong serial number lion upgrade

    already two days uptodate program tells me that my serial number is not suitable for a free upgrade to a lion, Imac was purchased on June 11. how long to wait when it's working?