[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

how to make windows appear?

Posted on 2000-04-11
8
Medium Priority
?
252 Views
Last Modified: 2010-04-09
i want to know if anyone knows how to make small avertisment windows appear but after they appear make them minimize automatically.
0
Comment
Question by:fritolero
[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
8 Comments
 

Expert Comment

by:Le_Ron
ID: 2704075
The JavaScript 'alert("string");' will show a little dialog box containing the text "string" with an OK button, but i don't know how to make it minimize automatically.

Example for a button :

<input type=button name="MyBtn" value="Push Me" onClick="alert('This is an warning')">

Or if you want to show it when the page is loaded :

<html>
<head>
<script>
function showMsg()
{
   alert("this is the message");
}
</script>
</head>
<body onLoad="showMsg()">
....
....
</body>
</html>

Hope this helps
0
 
LVL 33

Expert Comment

by:knightEknight
ID: 2704419
This will open an add page:
 
<SCRIPT language='javascript'>
  var mywin=window.open("myAdd.html","myPopup","width=200,height=200");
</script>


Making it minimize, I don't know, but you can close it automatically like this:

mywin.close();
0
 
LVL 1

Expert Comment

by:Smacked
ID: 2706373
i think mywin.blur() will deselect the window
0
Independent Software Vendors: 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!

 
LVL 4

Expert Comment

by:rafistern
ID: 2706816
This
    onload="opener.focus()"
would focus the opening window
or
    onload="setTimeout('opener.focus()',5000)"
would focus the opening window after 5 seconds...
0
 
LVL 4

Expert Comment

by:rafistern
ID: 2706821
Also
    onload="window.resizeTo(0,0)"
will minimize in IE but will ignored by Netscape.
0
 

Expert Comment

by:drew_moffat
ID: 2717264
This is a little off topic, but for the browser detection part, try this link, it's pretty damn cool:

<http://www.dansteinman.com/dynduo/>

He is a god....heh

Drew
0
 

Expert Comment

by:drew_moffat
ID: 2717275
Damn, ignore that post, I thought I was in another question...sorry folks, but it's a cool link (sheepish grin)..

Drew
0
 
LVL 4

Accepted Solution

by:
dreamvb earned 2000 total points
ID: 2766895
Only thing I can find that might be any good is this hope it helps

Put in Head

<script>
function winopen(){
        win = window.open("YOUR PAGE NAME", "newWin", "toolbar=yes,location=yes,directories=no,status=no, menubar=yes,scrollbars=yes,resizable=no,copyhistory=yes,width=400,height=260")
        startTime()
}

function startTime(){

        var time= new Date();
        hours= time.getHours();
        mins= time.getMinutes();
        secs= time.getSeconds();
        closeTime=hours*3600+mins*60+secs;
        closeTime+=3; // Amount of time that the window stays open in seconds
        Timer();

}

function Timer(){
        var time= new Date();
        hours= time.getHours();
        mins= time.getMinutes();
        secs= time.getSeconds();
        curTime=hours*3600+mins*60+secs
        if (curTime>=closeTime){
                if (win.closed == false){
                        win.close()}}
        else{
                window.setTimeout("Timer()",1000)}
}
</script>

and into the Body

onLoad="winopen()"

0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

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.
This article demonstrates how to create a simple responsive confirmation dialog with Ok and Cancel buttons using HTML, CSS, jQuery and Promises
In this tutorial viewers will learn how add a scalable full-width header using CSS3. Create a new HTML document with an internal stylesheet. Set a tiled background.:  Create a new div and name it Header. Position it with position:absolute at the top…
The viewer will receive an overview of the basics of CSS showing inline styles. In the head tags set up your style tags: (CODE) Reference the nav tag and set your properties.: (CODE) Set the reference for the UL element and styles for it to ensu…

649 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