From an HTML/JavaScript perspective I'm currently aware of 2 methods to spawn a new browser tab (or window).
- An HTML form
<form>
or anchor<a>
with a target attribute e.g.target="_blank"
- A JavaScript call to
window.open(url, name, features);
Note: I'm intentionally ignoring the IE-only showModalDialog & showModelessDialog methods.
However I recently encountered a very buggy scenario where I was able to spawn multiple tabs (actually endless) without clicking a link, submitting a form, or calling window.open() in Internet Explorer ONLY just by loading a page.
Since this bug was causing a terrible user experience (essentially browser lockup) I quickly mitigated the issue by blocking direct access to this screen - but I'm baffled as to how the other tabs could even spawn (regardless of the actual bug) if none of the options mentioned above were triggered.
Sadly the screen in question involves some SSO/security related login code so I can't post the details here but I'd love to know if there are any other ways to spawn new tabs that I might have overlooked so that I can dig into the code to see if there is a resolution.
e.g. Are there any HTTP Headers that might trigger a new tab?