After login close the login window and open home page in new window

Hi guys,
I want to go to a new window for the "home page" without browser back button etc. after login validation.
And also close the login window at the same time.
Here is the code I used after the login validation.
ExtendedRenderKitService erks =Service.getRenderKitService(FacesContext.getCurrentInstance(),ExtendedRenderKitService.class);
StringBuilder script = new StringBuilder();
script.append(" params = 'width='+screen.availWidth-10;\n" +
" params += ', height='+screen.availHeight-50;\n" +
" params += ', top=0, left=0'\n" +
" params += ', fullscreen=yes';\n" +
" params += ', scrollbars=1';\n" +
" params += ', resizable=1';\n" +
" params += ', status=1';\n" +
"window.close();\n" +
"'home.jspx','xxxxxxxxx', params);\n" +
" if (window.focus) {newwin.focus()}");
erks.addScript(FacesContext.getCurrentInstance(), script.toString());
This successfully opens a new window. I want to close the current login window at the same time.
Please help me with this.
Regards !

on the 'Submit' onclick event add some JavaScript code: = '_blank';

Similar Messages

  • Everytime I click on one of my app tabs it removes it form that brower window and opens it in a new window! how do I get it to work right?

    Clicking on an app tab shouldn't remove it from that browser window but it does, seems to sort of defeat the purpose of App Tabs in my opinion. then I have to drag the new tab back into the other browser window and then it works for a little while correctly.
    Thanks in advance for all your help!

    Make sure that you do not drag a tab in the browser window.<br />
    Firefox 3.5 versions and later have a feature called tear-off tabs.<br />
    You can detach a tab from the current window and open it in a new window by dragging a tab in the browser window.<br />
    You can drag that tab back to the tab bar in the original window to undo that detaching.<br />
    bug489729 (Disable detach and tear off tab):

  • After upgrade to v6, while surfing, Firefox opens active tab in new window few times in hour... why?

    I am using laptop. When I click on some link or in some text field or when I start typing on in search box... Firefox opens new window with the currently active TAB. This is very anoying and I thought that it will be OK but now it started to happen on PC also. It is not happening always with the same actions and is hardly reproduced.

    Make sure that you do not drag a tab in the browser window.<br />
    Firefox 3.5 versions and later have a feature called tear-off tabs.<br />
    You can detach a tab from the current window and open it in a new window by dragging a tab in the browser window.<br />
    You can drag that tab back to the tab bar in the original window to undo that detaching.
    bug489729 (Disable detach and tear off tab):

  • Running Windows XP service pack 3. Updated Firefox from 8.0 to 9.0. Now when Firefox opens "The URL is not valid and cannot be loaded" is displayed in a window and no home page appears. What's wrong?

    Running Windows XP service pack 3. Updated Firefox from 8.0 to 9.0. Now when Firefox opens "The URL is not valid and cannot be loaded" is displayed in a window and no home page appears. What's wrong?

    That issue can be caused by an extension that isn't working properly.
    Start Firefox in <u>[[Safe Mode]]</u> to check if one of the extensions or if hardware acceleration is causing the problem (switch to the DEFAULT theme: Firefox (Tools) > Add-ons > Appearance/Themes).
    *Don't make any changes on the Safe mode start window.

  • HT1918 My Apple ID (email address) is somehow registered to the US store even though I live in the UK. Can I close the US account and open a UK one with the same ID/email?

    My Apple ID (email address) is somehow registered to the US store even though I live in the UK. Is there any way I can close the US account and open a UK one with the same ID/email?

    No, but you can change the country of your iTunes Store account. Sign into your iTunes Store account and click the "change country" link. You'll need a valid UK credit card to complete the change. If you have any credit balance remaining, you'll need to contact the iTunes Store to clear that for you before you'll be able to change the country.
    Note that if you purchased anything from the US iTunes Store, you probably will not be able to re-download it nor update apps once you change the country. So you may prefer to set up a new email address so you can create a new account in the UK iTunes Store. You can change the email address to which receipts and other notices are sent to your actual email address, if you prefer.

  • Close the current UI and open another one

    Hello everyone,
    I've got the following code and I want to close the current window and open another one. When i use "System.exit(1);" it closes everything when I use "this.dispose()" it doesn't close anything what could I try to get this to work? any suggestions?
    the code is:
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    import java.util.*;
    //public class Equip_or_Job implements ActionListener {
    public class Equip_or_Job extends Frame implements ActionListener {
        JFrame dFrame;
        JPanel jePanel;
        JButton choice;
        JComboBox jeqid = new JComboBox();
        public Equip_or_Job() {
            //Create and set up the window.
            dFrame = new JFrame("Work with Jobid or Equipid");
            //Create and set up the panel.
            jePanel = new JPanel(new GridLayout(2, 1));
            dFrame.getContentPane().setLayout(new BorderLayout());
            //Add the widgets.
            //Set the default button.
            //Add the panel to the window.
            dFrame.getContentPane().add(jePanel, BorderLayout.CENTER);
            //Display the window.
    Create and add the widgets.
        private void addWidgets() {
             //Create widgets.
              jeqid.addItem("Chose by Job");
              jeqid.addItem("Chose by Equipment");
              choice = new JButton("Chose");
                //Listen to events from the Convert button.
        public void actionPerformed(ActionEvent event) {
              String sel = (String) jeqid.getSelectedItem();
            if("Chose by Job".equals(sel)){
                   InsertNewDates inj = new InsertNewDates();
              else if("Chose by Equipment".equals(sel)){
                   InsertNewDates ineq = new InsertNewDates();
    Create the GUI and show it.  For thread safety,
    this method should be invoked from the
    event-dispatching thread.
        private static void createAndShowGUI() {
            //Make sure we have nice window decorations.
            try {
              catch (Exception e) { }
            Equip_or_Job eorj = new Equip_or_Job();
        public static void main(String[] args) {
            //Schedule a job for the event-dispatching thread:
            //creating and showing this application's GUI.
            javax.swing.SwingUtilities.invokeLater(new Runnable() {
                public void run() {
    thanks in advance :o)

    I'm not exactly sure what you want to do, but...:
    dFrame.setVisible(false) hides the current Frame and the application is still running
    Best reagrds, Marco

  • I used to open, bbc radio 2, with a left click on the 'listen' tab? this now longer responds, I have to now right click the mouse button and open link in a new tab? whats wrong

    I used to be able to open BBc Radio 2 via the 'Listen' link with a left click of the mouse button, this nolonger works, I now have to right click the link and 'open link in a new tab'
    I must have disabled something?
    If you can help then please make it easy for me to understand.

    2 Solutions found in []
    the user cor-el has a method that does not require any add-ons. He States
    This code in userChrome.css will move "Open Link in New Window" to the top of the context menu.
    <pre>@namespace url("<a href=""></a>"); /* only needed once */
    #contentAreaContextMenu &gt; * { -moz-box-ordinal-group: 2; }
    #context-openlink { -moz-box-ordinal-group: 1 !important; }</pre>
    the user jay_ff shows how to do it using the Menu Editor Add-on
    1. Install the Menu Editor add-on from .
    2. After the installation, go to Firefox> add-ons (or simply use Ctrl+Shift+A)
    3. Go to the Menu Editor "Options"
    4. In the "Main context menu," simply grab the "Open link in New Tab" and place it below the "Open Link in New Window"
    5. and Voila! You may also change other menu options if you want to!
    I tried jay_ff method first and found that indeed changing the Main Context Menu did cause the hotlink context menu to change as well.

  • Won't open web page in new window

    Ever since the 5.0 upgrade when I click on a tab to open in a new window firefox just opens a blank new window. This is driving me crazy. So if I have 5 tabs going and say I want to watch a youtube video on my other monitor while I'm doing something else, I right click on the tab and click on open in new window and i just get a blank window. So I have to copy and paste the address in the new blank window. I am about to switch to google chrome its very inconvenient.
    Cindy Jervis

    There are some Flash objects on the web page.
    * "Clear the Cache": Tools > Options > Advanced > Network > Offline Storage (Cache): "Clear Now"
    * "Remove the Cookies" from sites that cause problems: Tools > Options > Privacy > Cookies: "Show Cookies"
    Start Firefox in [[Safe Mode]] to check if one of the add-ons is causing the problem (switch to the DEFAULT theme: Tools > Add-ons > Themes).
    * Don't make any changes on the Safe mode start window.
    * [[Troubleshooting extensions and themes]]

  • My Firefox.exe process remain open after I close the browser.If I open it it's says to open a new window.I need to close the process manualy(Ctrl+Alt+del).What can I do?Thanks .

    Need to close the process.

    It does take Firefox a while to shut down; it has to update some databases. But it should take less than a minute.
    In the support article, this problem is called a "hang at exit" because Firefox hangs when shutting down. Maybe something here will help:
    Also, sometimes open Firefox windows disappear from the Task Bar. You can use Alt+Tab to switch to them if they remain open.

  • When I click on an open tab sometimes it closes that tab and opens it in a new window. Why?

    Sometimes when I have multiple tabs open and click on one it closes and opens in a new window. Sometimes I like this behavior, but have no idea how it happens.

    Hello khoopes, how often is that ? do you have it soon enough , like one time in ten clicks on a tab ? can you check it in safe mode ?
    '''Try Firefox Safe Mode''' to see if the problem goes away. Safe Mode is a troubleshooting mode, which disables most add-ons.
    ''(If you're not using it, switch to the Default theme.)''
    * You can open Firefox 4.0+ in Safe Mode by holding the '''Shift''' key when you open the Firefox desktop or Start menu shortcut.
    * Or open the Help menu and click on the '''Restart with Add-ons Disabled...''' menu item while Firefox is running.
    ''Once you get the pop-up, just select "'Start in Safe Mode"''
    '''''If the issue is not present in Firefox Safe Mode''''', your problem is probably caused by an extension, and you need to figure out which one. Please follow the [[Troubleshooting extensions and themes]] article for that.
    ''To exit the Firefox Safe Mode, just close Firefox and wait a few seconds before opening Firefox for normal use again.''
    ''When you figure out what's causing your issues, please let us know. It might help other users who have the same problem.''
    thank you

  • Why the hell you've now decided to change the order of the "Open link in a new window" and "Open link in a new tab" options on the link menu???????????????

    Why, oh why have you now decided to change the order of the link menu options? People were so used to it that I bet nobody even look at the menu, they just go for it as I do and many of my friends does!! Why change something that works so fine and has been since ever??

    I like the new arrangement because I open new tabs much more often than I open new windows. It makes much more sense than the old way.

  • Open Dynamic Page in New Window after Submission

    I need to open a "success" dynamic page in a new window when redirected from a form in Portal The go('<url>'); method does not appear to allow opening the page in a new window. Is there a way to do this? Thanks, in advance.

    on the 'Submit' onclick event add some JavaScript code: = '_blank';

  • Opening OA page in new window using Image Bean

    Hi All,
    We have a requirement to open a new window in one of our application. It is working when I use a link but I am not able to achieve the same functionality with an image bean. Is it possible to achieve this using an image bean?
    Thanks in advance,

    If you wanna use imagebean, you would have to attach action using bound values API and open secondary window in OAF.Here is the same ple code:
    OAImageBean btn= (OAImageBean)webBean.findChildRecursive("<item id of image icon bean>");
    //page url
    String page1 = "/xx/oracle/apps/XX/webui/XXPg&retainAM=Y";
    String destURL = APPS_HTML_DIRECTORY + OAWebBeanConstants.APPLICATION_JSP + "?"+ OAWebBeanConstants.JRAD_PAGE_URL_CONSTANT+ "=" + page1;
    OABoundValueEmbedURL jsBound = new OABoundValueEmbedURL(btn,"openWindow(self, '", destURL, "' , 'longTipWin', {width:"+900+", height:"+500+"}, true); return false;");
    btn.setAttributeValue(oracle.cabo.ui.UIConstants.ON_CLICK_ATTR, jsBound);
    I received your mail, and replied the same in the mail too.

  • How do I open a page in new window using af:commandLink?

    I have a requirement where I need to open the page in a new window on clicking the af:commandLink.
    I could use af:goLink, but I cannot as I have to invoke the URL using http POST method. If I use af:goLink, all the parameters will be displayed in the URL. I do not want that.
    I have the below code for the commandLink:
    <af:commandLink text="Open new window" id="cl199bk"
    useWindow="true" windowHeight="400"
    windowWidth="800" immediate="true"/>
    When I click the commandLink, the page gets opened but in the same window. I have the below controlflow-case in my taskflow:
    <control-flow-case id="__71">
    <from-outcome id="__133">dialog:openNewWindow</from-outcome>
    <to-activity-id id="__72">openNewWindow</to-activity-id>
    Please let me know what to do to have the page opened in new window/tab.
    Thanks in advance!

    Hi Frank,
    I tried that too and the page always opened in the same page even with dialog:action set and useWindow set to true. I had the navigation rule in adfc-config as well.
    I got it done using the url-view activity.
    I have created a new bounded task flow with the url-view activity as the default activity. I called this new task flow from the actionListener bean method on commandLink. Set the new task flow to url-invoke-allowed.
    I have my parameters set in the url-view activity. With this the parameters are not shown in the URL.
    That did the trick for me.

  • Opening Dashboard Page in New Window While Passing Prompt Values

    Currently it is not possible to open a dashboard page in a new window AND have the prompt values from a prior page pass to this page. I see one or the other can be accomplished but not both. Is there a way this can be acheived somehow or is there a workaround for this?

    You are correct. The "Link or Image" object does not pass the dashboard prompt values, though it allows the destination dashboard to be opened up in a window.
    Here is a workaround.
    1) Place the link in a "Guided Nav. Link" object and set the destination dashboard and desired report. With the prompt set up correctly (i.e., dashboard scope, set to PV, destination report column filtered to receive the PV), the destination report will be filtered on the prompt as desired.
    2) I noticed (and maybe this is why you wish the "new window"), there is no "return" link on the destination report. To fix this, in the destination dashboard, add a Text object to the dashboard. In the properties, paste the code below and make sure to check off "Contains HTML markup." This will produce a "Return" button on the dashboard.
    <input type="button" value="Return" onclick="history.back();">
    Now, when the user selects the prompt and clicks on the link, the prompt is passed to your second dashboard. When the user wishes to return, he/she can click on the "Return" button and return to the primary dashboard.

Maybe you are looking for

  • Incident management error: You are not assigned a Business Partner

    Hi I am facing a problem while creating message as below error: You are not assigned a Business Partner I created the BP. which has clear identification too. Even this BP is maintained as Employee too. Expecting ur valuable suggestions. Regards, Siva

  • Decimal filed in ALV

    Hi Abaper, I am showing one field in ALV of likp LGMNG which is using refrence of data element LGMNG (QUAN     13     3). it is displaying with 3 decimal places. I want to display the value of LGMNG with 2 decimal place, how? Thanks, Rajesh.

  • How to repair the oracle8.1.7

    I have once installed oracle8.1.7 in windows2000 professional.because the virus destruction I formatted the c drive and reinstalled the windows2000 professional.the oracle8.1.7 is located at e drive.I tried to reinstall the oracle.but I don't know ho

  • Got error when create new category

    Hello, when I wanted to create a category problematically, I saw this error: atg.repository.RepositoryException: createItem called with id of valid item: category:6552:1      at atg.adapter.gsa.GSARepository.findItemToUndelete(

  • CRM order replication

    Dear Experts, I have established middleware setup between ECC 6.0 and CRM 2007. I have created the order in CRM which has got replicated to ECC succesfully, problem is we are able to see the order in the display mode for the  delivery process it  has