Forum Moderators: open
window.open looks like the thing for you!
It is of the format:
window.open(URL, title, features)
For example:
More details here [javascript.about.com], including features use.
HTH
another confirm ...
I've used:
<script language="JavaScript">
<!-- hide me
function plainWindowF()
{
plain_window =
window.open("form.html","plain","width=470,height=452");
}
// end hide -->
</script>
AND THEN CALL IT WITH:
<input type="submit" value="write to us" class="botun" onClick="plainWindowF();">
INSTEAD OF THIS I CAN WRITE SIMPLY:
<input type="submit" value=" scriveteci " class="button" onClick="window.open('form.html','form','width=470,height=452,left=10,top=163,location=no, menubar=no,status=no,toolbar=no,scrollbars=no,resizable=yes');">
WITHOUT USING THE FUNCTION? RIGHT?
thanks again
You can open the window directly from the onClick without the need for a function.
Although, a function would make your code neater!
Don't forget that if you are using javascript to link to another page, to put the url in an href:
This keeps the link search engine friendly and the page accessible. The return false in the onClick tells the browser to ignore the default action (opening the link in the current window) and use the javascript commands instead.
HTH