I'm trying to create a popup window that displays the browser toolbar and allows the URL to be edited just like a normal browser window. This is for a link in the backend of a custom CMS to enable the user to view a mobile formatted website. I understand that the default behavior for window.open() is toolbar=yes, location=yes and menubar=yes, however when using Chrome I'm getting a popup has a URL field that can't be edited and does not have the back, forward, reload buttons regardless of settings I use. Works fine in Firefox and Safari.
Here's the code I'm using:
<script>
function popupwindow(url, title, w, h) {
var left = (screen.width/2)-(w/2);
var top = (screen.height/2)-(h/2);
return window.open(url, title, 'toolbar=yes, location=yes, directories=no, status=no, menubar=yes, scrollbars=yes, resizable=no, copyhistory=no, width='+w+', height='+h+', top='+top+', left='+left);
}
</script>
<a href="/?format=mobile" onclick="popupwindow('/?format=mobile', 'Mobile App', 336, 480); return false;">
Launch App
</a>