|
JAVASCRIPTS
INDEX - UPDATED 05/21/2009 - Now Includes All Site Scripts
For a complete list of all free
cut-and-paste JavaScripts on our sites, please see the
JavaScript Index, here.
We've recently updated this to include all scripts from
CodeBrain.com, CodeLifter.com, and CodeBelly.com
Newer scripts are listed below..
|
Easy-To-Use
PopUp Window Code Generator - 032404
Very simple to use, makes popup window code and tests it.
Select some simple options, hit the button, and the code is
ready to be inserted into your html page.
|
Slick
Scrolling Slide Show - 031404
Fill in the parameters and paste the code into your html page,
shoot the files to your server; that's about all there is to
it. Flexible design and layout parameters.
|
Using
IFRAME To Put Pages Within A Layer - 022204
This very easy script can be used to insert an external page
into a layer in your current page -- a great way to include
extra content, especially in crowded pages. Using links within
the "iframed" pages, you can literally include a whole
secondary content vehicle or mini-website.
|
Layer
Menu Uses External HTML Page - 022204
This menu technique is ideal if you have a number of pages on
your site, and may need to frequently change the menu items on
all or many of them. Using an iframe within a floating layer,
the menu items are contained in a single external html page.
Insert the layer code once into each page; so when you must
change the menu, you change *only* a single external HTML
page... with the changes instantly reflected in every page on
your site. No server-side scripting; requires only knowledge of
basic html editing.
|
Floating
Transparent Slide Show - 012004
This script creates a floating layer, within which is a
sophisticated automatic slide show (including fade transitions)
that cycles through the images that you specify. The slideshow
layer can be positioned anywhere on the screen, and it will
float to that position whenever the window is scrolled. If
transparent .gif images are used, the slideshow will run
transparently over the page content.
|
Floating
Email-This-Link Script With URL Auto-Capture - 011804
This script creates a floating layer with an email-this-link
script in it. The layer can be positioned anywhere on the
screen, and it will float to that position whenever the window
is scrolled. Enter the recipient address and click the send
button, and the visitor's email client is opened, complete with
a message in the email body that includes the link for whatever
page in which the script is placed.
|
Instant
Image Zooming Attaches to Any Image - 011604
This easy zoom-in/zoom-out script can be attached to any image in your page. The image size will toggle between two sizes you set whenever the image is clicked. The function can be attached to as many images in the page as you wish.
|
1-Click Easy Drop-Down Menues
- 080603
This simple script creates a drop-down menu that opens pages on a single click when selected from the menu. Pages can open in the same window, a new window, or a target frame. Very easy install, and great for tight spots where you need a menu.
|
Scroll
To Top of Page With JavaScript - 072103
.
Keep
Background Fixed When Page Scrolls - 071703
Call
More Than One Function From An Event - 071703
Make
Window Pop Under - 071703
Set
Window Size - 071703
Set
Window Position - 071703
Make
Window Come To Front - 071703
Stop
Window From Losing Focus - 071703
Close
Window From JavaScript - 071703
Maximize Window From JavaScript - 071703
|
Bring
Window To Front Periodically
- 071703
Prevent
Page Being Captured In Frameset -
071703
Redirect
Page With Or Without JavaScript -
071703
Reload
Page At Given Time Interval -
071703
Put
Scrollbar On Left Instead Of Right -
071703
Stop
Window Scrollbar From Showing -
071703
Attach
Multiple Styles To An Element -
071703
Use
JavaScript Link To Return To Previous Page -
071703
Protect
Page Code - 071703
Rules
For Naming JavaScript Variables - 072403
|
Basic
Window Maximizer - 071603
Place this simple script in the head of your page. When the page is
opened it will reposition and resize to fill the full screen area.
|
Amazing Draggable Slide Show
- 122402
This script implements a draggable slideshow that can be used much like a popup window, but without the usual focus problems popups imply. Simple controls to show or hide the
slideshow are also included, and any number of images can be used. IE browsers show a cross-fade effect between images in the sequence. Compatible with NS4-7 & IE.
|
No-Right-Click Script Opens Popup Window
- 122302
Use this script to launch a popup window whenever the right mouse button is clicked. Useful for
limited protection of page code and images; and the popup window can contain whatever fulmination on
human morals you wish to deliver.
|
Advanced Push-Button Slide Show with Captions & Cross-Fade
- 121902
A push-button controlled slide show with image captions and fader-effect image transitions.
Cross-browser [NS4-7, IE-4&up] cut-and-paste script presents images in a slide show format,
controlled by back, home, and forward buttons. Any number of images and captions can be used. Great
for JavaScript newcomers, but a solid utility script, too. A download kit of the complete code and
images is also available, free, on the site.
|
Access Image URL to TextBox
- 121802
When an image is clicked, this script will show the image URL in a textbox. Useful for cases where
you want others to be able to copy the image address easily for linking... such as for banners, logo
graphics, etc. A single instance of the script can be attached to any number of images in the page.
|
Amazing
Draggable Layer - Use Instead of Popups
- 121602
This script implements a draggable layer that can be used much like a popup window... but without the
usual focus problems that popups often imply. Also included are simple controls to show or hide the
draggable layer. Compatible with NS4-7 & IE.
|
Auto-Sizing Image Popup Window Script
- 121602
Use this script to launch a popup window that automatically loads an image and resizes itself to fit
neatly around that image. The script also places a title you set in the titlebar of the popup
window. Any number of images can be launched from a single instance of the script.
|
NewsMaker - Smooth News-Ticker Reads From File
- 062502
NewsMaker is a smooth-scrolling news ticker-scroller that reads its items and links from a text file. Comes with free
software tool to make message-and-link file. Supports background images and sound. Automatic headlining,
auto-wrapping, text justification, and more.
|
Advanced Slide Show with Captions & Cross-Fade
- 061902
Slide show with image captions and fader-effect image transitions. Easy, short, cross-browser cut-and-paste script presents images in a continuous slide show format with accompanying captions. Any number of images and captions can be used, and timing is adjustable. Great for JavaScript newcomers, but a solid utility script, too.
|
Background
Image Scroller - 041202
Use this script for to create a stunning page effect by
scrolling the background image underneath your page content.
Includes variable scroll speed, and is very simple to install.
|
Changing TextArea Background Images on MouseOver
- 012902
Use this script to apply a background image to a textarea, and change the image on mouseover. The script can also change the text color in response to the mouseover event. An eye-catching effect, and a very easy install.
|
E_Cloaker
2.0 Email Address Cloaker
- 012502
E_Cloaker 2.0 converts email addresses and text into
browser-readable Unicode, making it more difficult for spam
extractor 'bots to harvest email addresses from your web page.
Using Unicoded addresses throughout your site significantly
reduces the amount of spam you receive. Free.
|
|
Invoking The SaveAs Dialog From A Web Page
- 010702
IE4+ browsers provide a document.execCommand() that can call certain system dialogs. This script demonstrates calling the SaveAs dialog to save a web page. The script includes onload interlocking and alternate alert messaging for non-IE browsers.
|
|
Formatting Background, Font, and Sticky Selection in Dropdowns
- 010402
This script sets font face, size, color, style and background color in dropdowns. Optionally, you may set sticky selection, which changes the
action of the dropdown slightly. Great for getting larger fonts for emphasis or for the visually impaired -- or just to dress up otherwise bland dropdowns.
|
|
Disabling The MyImage Toolbar in IE6+
-122801
IE6+ incorporates a new feature called the MyImage Toolbar, which, if enabled on
Tools > Internet Options > Advanced > Enable Image Toolbar, provides the user with a popup menu over images that allows the user to instantly save, print, or email any image in a page. This technical note shows how to disable or enable this feature.
|
|
Adding A Background Image To A TextArea
- 121901
Quick, easy way to add an image to the background of a textarea... a great way to dress up an otherwise bland browser page. Stunning effect!
|
|
Active Image Resizing With Drag
- 121101
This script allows you to resize one or more images on a page by clicking and dragging on the image(s). A single left-click will also reset the image to a default size. Any number of images may be used.
|
|
Blocking
JavaScript Errors - 121001
Place this simple
script in the <head> ... </head> of the page to
block JavaScript errors in the page. We've found this
useful with page material from sources other than our own that
may contain errors (ad banners, automated news feeds, etc.).
|
|
Accept Focus Until Closed
[Window Control] - 071801
This is a simple technique, but one that is asked for very often. When you open a window and wish to keep it 'on top' of all others until closed, all you need do is add this small snippet to the body tag. Demo included.
|
|
2-Way Background Images SlideShow
- 070401
Unusual script creates an image slideshow in the *background* of the page, underneath the page content. In the first method, the images are discretely positionable in the page space, just like a regular slideshow. In the second method, the slideshow runs with full page-space presentation. An easy install.
|
|
|
|
4-Flasher Background Color Effect
- 070401
When the page opens, this script rapidly cycles the page background through four different colors and then to the page fixed color. A striking page-opener effect that does *not* depend on MSIE transitions. Easy.
|
Background
Image-Change on MouseOver or Link
- 070301
Use this script to change the background image used by the page,
from a clicked link or on mouseOver. Any number of images can be
used. Shows how to attach to a regular (clicked) link, or how to
activate the background image change on a mouseOver. Easy.
|
|
Background Color-Change from Link or MouseOver
-070201
Use this script to change the color of the page background from a clicked link or on mouseOver. Any number of colors can be used. Shows how to attach to a regular (clicked) link, or how to activate the color change on a mouseOver. Easy.
|
|
Change
Style Sheets On-The-Fly from Page Links
- 070101
Use this script to allow visitors
to change a page style sheet on-the-fly, by clicking on a link
in the page. The script works by switching the active style
sheets. You can use any number of style sheets, which are
automatically detected by the script. Optional alerts are
included. Setup is easy and straightforward. Comes as a complete
kit, as well as in the usual listings format..
|
|
Access
Control by Screen Size - 062501
With an increasing number of standard screen resolutions in use, it's often necessary to do separate designs for each. Use this script to control access and redirect to separate pages based on 640, 800, 1024, or larger screen sizes. The script includes optional alert messages, which can be enabled or disabled via a script variable. Thorough instructions are in the script, and set-up is easy.
|
|
Accent JavaScript Web-Based Browser
[Web-Based JavaScript FullScreen Browser Script Kit] - 062301
The Accent JavaScript browser is a complete, basic, fullscreen web-based browser implemented in a JavaScript script set, including the core controls (Location Box with Go button, and Home, Back, Stop, Forward, and Close Buttons). Clean, simple, slick design, this is a solid starting point for building your own site-based browser, and a good demo of basic techniques. Easy to 'rebrand' to your own site. Full code listings are provided, as well as a download 'kit' with all code, ready to run, with no modification needed. Freeware.
|
|
Closing
Windows From JavaScript - Six Methods - 052301
This set of short, easy scripts shows six
different ways to close a window from JavaScript, including closing
windows from a clicked link, a clicked image, or a clicked form
button. Special instructions are also included for closing
windows comprised of frameset pages.
|
|
Flying
Focused Window Ad Script
- 050401
The Flying Focused Ad Window script creates a popup window when
the launch page loads. The popup slides first down, then
across, then up the screen, then back to its starting point.
The window maintains focus throughout. Only closing the
window returns focus to the launching window. Great for
drawing special attention to announcements or banner ads!
|
|
Boinger
Window - 050901
The Boinger Window script set
launches a popup window that continually switches back and forth
between two settable sizes. The cycle time is settable.
The screen location is also settable and may switch back and
forth in the timing cycle. Cool effect, super for making sure
visitors don't miss a special announcements or important banner
ads!
|
|
Title
Bar Message Ticker - 051101
The Title Bar Ticker script shows changing text in a multi-message ticker-type display in the browser title bar. Any number of message lines may be used, and a moving, attention-getting slide box draws the eye to the messages.
|
|
Highlighting Form Text Areas on Mouse Click
- 052301
This simple script set shows how
to highlight (select) the text in a form's textarea by clicking on a link.
Useful for code listings, order form information, or other
material the visitor may wish to copy to the clipboard with
Control+C.
|
|
|