About US
          Contact Us

Popup Windows

Chapter - 11 : Using Additional Frames / Windows (Popup Windows): (Page 5/6)

(Cotinued from previous page)

All values can be written as 'no' / 'yes' or '0' /'1' and it will produce the same result. In this case as soon as visitor clicks on 'Price List', price.html page will popup in new window of size 250 * 250.

Important: Write all the above command in continuation, without using a line brake (or Enter Key). If due to window size, some letters / word automatically get shifted to next line, then it does not matter.

This command will have a popup similar to FIG 11.3 with no scroll bar, status bar etc.
Popup  in htmlWindows in html Lets us change two parameter 'menubar' and 'scrollbars' to '1' and see the result. The new window will have menubar and scrollbar as shown in FIG - 11.4

Similarly you may try by changing other values.

ii) Method - 2: In this method the command is written in two step. First the value will be defined in the 'head' section and then the link will be defined in 'body' section'
The following to be written within <head> and </head> tag.

<script language="JavaScript"> function popup(url) { eval("page" + " = window.open(url, '" + "', toolbar=0,scrollbars=0,location=0, statusbar=0,menubar=0,resizable=0,width=250, height=250');"); } </script>

And following is to be written at required place in between 'body' tag.

<a href="javascript:popup('price.html')">Price list</a>
The advantage / disadvantage of this method is that all the popup will have same value.
The different values of popup window can be changed as explained in method - 1.

(Cont......... to next page (Pg-6))

Popup Windows © funandhobby.com (Popup Windows)