Finding Values and More with Web Page Dialog Boxes
In this conclusion to a five-part series, we'll wrap up our discussion of what you can do with web page dialog boxes. Among other things, we include some tips you'll need to keep in mind when you include web page dialog boxes in your commercial projects.
Finding Values and More with Web Page Dialog Boxes - Commercial Project (Page 4 of 4 )
If you are carrying out such a project for commercial purpose, then there are certain things you will have to take into consideration.
First of all, let us see how to close a window. The statement to close the current window (the window JavaScript resides in) is:
window.close();
For a window to close another window, use the following statement:
winRef.close();
where winref is the reference to the other window.
To know whether a window is closed, use the following statement:
winRef.closed
This statement returns true if the window is closed; otherwise, it returns false. You can use it in an if-block as follows:
If (winRef.closed)
{
//do something
}
You can add code such that all the windows can be closed from the main window. You can also add code such that no intermediate dialog box is closed unless it is at the bottom end of the chain. I have given you the principles to do these.
Projects like this often involve a database. You can add code such that data can be sent from any dialog box to the database.
Conclusion
We are in the era of web development. Web development involves a database at one end, the Internet and the browser in the client computer at the other end. Depending on your project, you will need dialog boxes for a web (browser) window. The principles I have outlined here will lead you through.
DISCLAIMER: The content provided in this article is not warranted or guaranteed by Developer Shed, Inc. The content provided is intended for entertainment and/or educational purposes in order to introduce to the reader key ideas, concepts, and/or product reviews. As such it is incumbent upon the reader to employ real-world tactics for security and implementation of best practices. We are not liable for any negative consequences that may result from implementing any information covered in our articles or tutorials. If this is a hardware review, it is not recommended to open and/or modify your hardware.