DHTML script
 

SimplytheBest
Scripts

ASP scripts
PERL scripts
PHP scripts
JavaScripts & Ajax
Snippets
Online scripts

Ajax, DHTML
& JavaScripts

Animation
Background
Bookmarks
Buttons
Calculators
Cookies
Data handling
E-mail
Enhancements
Forms
Image rotation
Menus
Messages
Miscellaneous
Music
Password protection
Redirection
Scrollers
Tables
Time & date
Windows

Publishers
Add script
Account login
Publisher list



 

Home > Scripts > DHTML scripts & JavaScripts > Messages > Slide-in information box

 

Slide-in information box

AUTHOR: Submitted by Ron Grafe
TYPE: Freeware
BROWSERS: IE 4+, IE 5+, IE 6+, NS 4+, NS 6+

This slide-in box script can be used as an ad box or information box. It slides-in a text information box from the bottom of the page. You supply the text in an onMouseOver event in whatever tag you like. When you hold your mouse over the tag the text will slide in from the bottom. Even if you scroll down, the info box will stay on the bottom of the page.


EXAMPLES

SimplytheBest DHTML Scripts (with link, using default settings)

Information box (no link, overriding defaults)

As a box ad (with link, overriding defaults)


1)
Insert this script in the <HEAD> section of the page.

then copy (CTRL-C) & paste (CTRL-V)

 

2) Insert the following code inside the <BODY> section of the page.

then copy (CTRL-C) & paste (CTRL-V)

3) Insert the onMouseOver event inside the <A> </A> tag of any link on your page:

a) with URL link and default settings:

<a onmouseover="setObj(1)" onmouseout="clearTimeout(openTimer);stopIt()"  
href="scripts/dhtml_scripts.html">SimplytheBest DHTML Scripts & Javascripts</a>

copy (CTRL-C) & paste (CTRL-V)

b) without URL link and with defined height and width:

<a href="Javascript:Void(0)" onmouseover="setObj(2,'override',300,200)"
onmouseout="clearTimeout(openTimer);stopIt()"
>Information box (no link)</a>

copy (CTRL-C) & paste (CTRL-V)

4) Define the content to appear inside the slide-in boxes in this section of the script (make sure to use single quotes inside double quotes):

textArray[1]="<font face='Arial' size='2'><strong>SimplytheBest DHTML Scripts &amp; Javascripts</strong><br>A collection of the best DHTML scripts &amp; javascripts on the Internet.</font>"

textArray[2]="<font face='Arial' size='2'><h2>Information</h2>Using it this way would allow you to enter any type of help/text information.</font>"

5) Define the style of the box windows in this section of the script (in the BODY section):

<layer name="nsviewer" bgcolor="#EAFFF4" style="border-width:thin;z-index:1"></layer>
<script language="JavaScript1.2">
if (iens6){
document.write("<div id='viewer' style='background-color:#EAFFF4;marginleft:0;visibility:hidden;position:absolute;width:0;height:0;z-index:1;overflow:hidden;border:2px ridge white'></div>")


For more information you can also visit
Ron Grafe's web site.


[BACK] [TOP]

 


Copyright © 1997-2009 SimplytheBest Inc. Terms of Use and Legal Disclaimer.
All copyrights are acknowledged. All rights reserved.