Skip to content

Instantly share code, notes, and snippets.

View danieleremin's full-sized avatar

Daniel Eremin (aka Hackerboi) danieleremin

View GitHub Profile
@danieleremin
danieleremin / Open_New_Window.js
Last active December 6, 2020 00:26
How to open a new window in front of the current one using JavaScript. Values can be changed for desirable result.
function NewWindow() {
window.open('page.html','about:blank','resizable=yes,scrollbars=yes,status=0,width=600,height=620');
}
// Call the function when a button is clicked.
// NOTICE: This will not work on mobile devices. On mobile devices this would function the same way target _blank on <a> HTML tag would. (Opens in new tab)