What code would I give to a button so that when I click it it launches lol.html in a new window at a fixed size of 900x440. A bit like habbo does with their launch the hotel button. +Rep to whoever knows it.
Printable View
What code would I give to a button so that when I click it it launches lol.html in a new window at a fixed size of 900x440. A bit like habbo does with their launch the hotel button. +Rep to whoever knows it.
Put this in the head section:
and this around the image of your button:Code:<script language="JavaScript">
function popUpWindow(URL) {
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=900,height=440');");
}
</script>
Code:<a href="javascript:popUpWindow('lol.html')"></a>
:S Should work :S
I tested it before I posted it, what browser are you using?
I'm perfectly aware of that, don't insult my intelligence. I was just asking which browser so I could try it out when I get home.
Obviously it's a very weird thing to happen as a result of the code I gave, so I was going to have a look and see why it did that.
Permission to continue doing so, sir?