For my website i need floating window

Please support our JavaScript / DHTML / AJAX advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
Reply

Join Date: Nov 2007
Posts: 52
Reputation: kavithakesav is an unknown quantity at this point 
Solved Threads: 2
kavithakesav kavithakesav is offline Offline
Junior Poster in Training

For my website i need floating window

 
0
  #1
Sep 12th, 2008
Hi,
I am working on one website for that i need like floating window. (mean when visitor will open the website that window has to come and it should be timelimit aftr that it has to close atomatically. for that window more and close is required).


Cheersssss,
Kavithakesav
Reply With Quote Quick reply to this message  
Join Date: Aug 2008
Posts: 954
Reputation: essential will become famous soon enough essential will become famous soon enough 
Solved Threads: 131
Featured Poster
essential's Avatar
essential essential is offline Offline
Posting Shark

Re: For my website i need floating window

 
0
  #2
Sep 12th, 2008
Assuming that this your index.html
  1. <html>
  2. <head>
  3. <title>index page</title>
  1. <script type="text/javascript">
  2. <!--
  3. window.onload = function()
  4. {
  5. /* You must replaced this with your own page that you wish to be loaded */
  6.  
  7. window.open('floating.html', targe='_blank', 'toolbar = no, scrollbars = no, location = no, width = 500, height = 500');
  8. }
  9. //-->
  10. </script>
  1. </head>
  2. <body>
  3.  
  4. </body>
  5. </html>

And this will be our floating window, clocked for 10secs and when it reaches its limit this wil automaticaly close!
Enjoy coding...

  1. <html>
  2. <head>
  3. <title>floting page</title>
  1. <script type="text/javascript">
  2. <!--
  3. ////////////////////////////////////////
  4. /////////////By Essential///////////
  5. ////////////////////////////////////////
  6.  
  7. window.onload = clocked; function clocked()
  8. {
  9. x = 10;
  10. var timer = setTimeout('clocked()', 1000);
  11. x = x - timer;
  12.  
  13. document.getElementById('countdown').innerHTML = 'You still have 0' + x + ' sec. remaining before this window close!';
  14. if ( timer == 10 ) { clearTimeout( timer );window.close(); }
  15. }
  16.  
  17. //-->
  18. </script>
  1. </head>
  2. <body>
  3. <p align="center">
  4. <span id="countdown">&nbsp;</span>
  5. <p>
  6. </body>
  7. </html>
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the JavaScript / DHTML / AJAX Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC