Web Browser close button javascript - browser

Working on web application and need to write some code in a web-browser close button, how can we do that in Javascript.
for Chrome, IE, and FireFox.
Just wants to override Close button code

Related

Chrome Extension - Open popup from contentScript file

I'm trying to open a popup page from DOM event in content script js file.
I Tried to send message to background page and in the background listener to use:
chrome.browserAction.openPopup() but apparently it's not the way cause browserAction not defined in that context.
The extension is for audio streaming, so while browsing that the audio will keep playing in background.
I managed to make the audio playing work in the simple way: when clicking the extension icon => open's the popup => some event in the popup interact with the from the background and play's the music.
I want to make it work in the following way:
Content script will add button to the user web page(any page).
done
Clicking this button will open the popup, and from there, same logic.
The issue is that I don't know how to open the popup from the content script.
It's actually to trigger to extension icon click from code.
Any ideas?

Robot framework: How to Log out from web application and close chrome browser using selenium webdriver?

My Robot framework Execution hangs after clicking on log out.
Here is my sample Code:
Wait Until Page Contains Element //a[contains(text(),'Log Out')]
Click Link //a[contains(text(),'Log Out')]
Close Browser
Open Webpage ${browser} ${user} &{Login}[${user}] ${Url_Link}
Maximize Browser Window
This Code works on Firefox, But with Google Chrome the execution is Hanging at the Below step.
Click Link //a[contains(text(),'Log Out')]
Clicking on the Logout is successful, But the execution Hangs in the same step and it doesn't go the next step. However this works fine with Firefox.
Request to help me with any suggestions.

Chrome Extension: Make window attach to side of browser and always on top?

I want to create a popup window that appears on the side of browser and attaches itself without disappearing under the browser window when it's maximized. Is this possible?

XMLHttpRequest stops when my panel loses focus in google chrome

I am sending a xmlhttprequest from my google chrome ui after a button is pressed in the popup.html. This code works fine as long as the popup.html remains open. But the moment the popup.html closes(bu clciking the mouse outside popup.html area) the xmlhttprequest automatically aborts and stops. This causes my program to stop execution. I want to know if there is any way in which i can continue the xmlhttprequest even if the windows gets hidden and loses focus.
Your AJAX request should be done by a background script. Execution of this script can not be stopped easily by the user.
You should modify your extension like this:
user clicks something in the popup
popup calls a function from a background page
(from this place on popup is no longer needed to be open)
background page sends an AJAX call and retrieves the answer
(background page may ignore/store the answer form AJAX call or pass it to some content script/popup script etc.)

Richfaces showModalPanel function not working in IE when called from Iframe

I am having a richfaces app where pages would show a modal panel with a "Pls wait" message whenever some ajax processing is done. This works fine in IE and Firefox if used in separate web apps, but when I try to embed one web app into another webapp(like portals) and do the processing, it works only until a point where only ajax calls are submitted from the page. The moment a non-ajax call is invoked, the modal panel doesnt appear on the screen until screen refresh using F5. Specially this happens only in IE and works fine in FFox.

Resources