?
Solved

message box?

Posted on 1999-01-06
3
Medium Priority
?
142 Views
Last Modified: 2010-04-09
How would i go about making a popup message box for such things as a disclaimor with a "OK" and "CANCEL" button. When the person clicks ok the page will load up but if they click cancel they will be transported somewhere else.
0
Comment
Question by:scorp010699
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 2

Expert Comment

by:seahpc
ID: 1841387
Try this :

<Script Language = "Javascript">
reply = confirm("Are You Sure ?")
if (reply = true)
       // something  
else
       // something
</Script>
0
 

Author Comment

by:scorp010699
ID: 1841388
what would go in the fields where you put "something" & something else???
0
 
LVL 2

Accepted Solution

by:
seahpc earned 120 total points
ID: 1841389
Hope this is what you want :

<Script Language = "Javascript">
reply = confirm("Are You Sure ?")
if (reply = true)
       self.location = "1.htm" ;
else
       self.location = "2.htm" ;
</Script>

0

Featured Post

WordPress Tutorial 1: Installation & Setup

WordPress is a very popular option for running your web site and can be used to get your content online quickly for the world to see. This guide will walk you through installing the WordPress server software and the initial setup process.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article discusses four methods for overlaying images in a container on a web page
Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
In this tutorial viewers will learn how to position items using CSS's three positioning types Create a new HTML document with an internal stylesheet.: Create another div in CSS and name it Absolute : Type "position:absolute;" and "top:10px; left:50p…
In this tutorial viewers will learn how to style elements, such a divs, with a "drop shadow" effect using the CSS box-shadow property Start with a normal styled element, such as a div.: In the element's style, type the box shadow property: "box-shad…
Suggested Courses

765 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question