[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

popup window

Posted on 1998-06-06
1
Medium Priority
?
214 Views
Last Modified: 2010-04-09
I was visiting a site and it had a small pop-up window that said welcome and then it went away after a few seconds. I tried looking at the page source but could not find out how he did that as I would like to put that on my site to notify everone when I am on vacation. How can this be done?
With example code please, thanks.
0
Comment
Question by:dtucker
[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
1 Comment
 
LVL 4

Accepted Solution

by:
martinag earned 200 total points
ID: 1844118
Put this at your home page:
<SCRIPT LANGUAGE="JavaScript">
<!--
newWindow = window.open('','nW','width=300,height=100,scrollbars=0');
newWindow.location.href = 'welcome.htm';
// -->
</SCRIPT>

Then you'll have to create the pop-up document, welcome.htm:
<HEAD>
<TITLE>Welcome!</TITLE>
</HEAD>
<BODY BGCOLOR="FFFFFF" ONLOAD="setTimeout('self.close()', 3000);">
<H1 ALIGN="CENTER">Welcome!</H1>
</BODY>
</HTML>

At the BODY-row, we tell the browser to close the window after 3 seconds (= 3000 ms).
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Building a website can seem like a daunting task to the uninitiated but it really only requires knowledge of two basic languages: HTML and CSS.
When crafting your “Why Us” page, there are a plethora of pitfalls to avoid. Follow these five tips, and you’ll be well on your way to creating an effective page.
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).

650 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