This question already has answers here:
How can we open a link in private browsing mode
(2 answers)
Closed 3 years ago.
I have no idea if this is even possible, but I figured I'd ask.
I have the need to open a new InPrivate browser window from within a webpage, on a button click. I'd like to navigate to a webpage, but it has to be an InPrivate session due to issues with session state being messed up if it is not an InPrivate session. Does anyone know if this is possible?
I'm using C#, JQuery 1.11.2, and IE11.
Thank you!
you can't force a user to open a window in private mode
Related
This question already has answers here:
Open a new tab with javascript but stay on current tab
(4 answers)
Closed 4 years ago.
I've tried jquery window.open, but all focus will be shifted to new tab, and i dont want that, onclick should open new tab without shifting focus from current tab, also tried window.blur() and window.focus(), but doesn't fit my requirement.
tab behaviour is controlled by the browser.
You wont have any way of controlling it from javascript.
Being able to control that kind of behaviour would be a serious security concern.
This question already has answers here:
Communication between tabs or windows
(9 answers)
Closed 5 years ago.
I have 2 open tabs from same application and same domain: tab1 and tab2, they are not opened from each other I mean I can not use win.open(....) and win.reload() So is there any way to find the tab by name and refresh it. The objective is from tab1 find the tab2 and refresh it automatically. any idea?
I see 2 solutions to your problem:
check if your document focus has changed. You only need to refresh it when tab gets visible again.
register open tabs in a session array and flag them with ajax calls or with server side code if they need to refresh. each page (tab) can check it's flag, refresh itself if needed and clear flag. I will need to know what might trigger the need to refresh for a better approach.
This question already has answers here:
Open a URL in a new tab (and not a new window)
(33 answers)
Closed 8 years ago.
I have mined deep in the web, but still I cannot find a solution for this problem, i.e., when you manually click a link in the webpage, it will open a new tab in Chrome, but when you click it by invoking link.click() in JS, it will open a new window.
Is it possible to find a way for that?
You can't get this behavior programmatically, this behavior set by user inside browser configuration :(
This question already has answers here:
Closed 12 years ago.
Possible Duplicate:
Close /Kills the seesion when close the browser or tab
Is there a solution for cross browser event. I need to check if user closes their window and to throw an ajax request to my database to sign them out.
I've looked everyone but most cases its not working in all browsers. Anyone have a solution? Or Alternative on how to do this perhaps a conditional statement depending on the browser?
Thanks!
I don't think such a thing exists. You can try an onunload, but that also fires when you refresh the page. This question has been the bane of many that want to do what you're asking for.
This question already has answers here:
Closed 13 years ago.
Possible Duplicate:
Disabling Back button on the browser
Hi Guys,
I need to disable the backbutton of browser window.When I click on backbutton,I need to show one message using alert or other means.Any one can help me
you can't make the user stay on your page, but you can give a yes/no prompt first, though.
read around Is there a way to determine that the browser window was closed?
Short answer: don't.
There's something wrong with the design if you have to do this.
I HATE it when web pages do this.
I'd suggest another way of approaching the usability of your page first.