KidsLovePC Contact Us
  Home   PHP  Graphics ASP  JavaScript   J2EE  HTML  JAVA   Swing   Webtip  Forums  Lyric  Free sheet music  Ringtones

The Ad Rotator Component

The Ad Rotator displays a different graphic/url each time a visitor accesses a page. The graphic is usually a .jpg or .gif. The rotator utilizes a schedule file to set up it's environment.

The schedule file includes the names of each of the image files,, the sizes they are to be displayed at, and the relative percentage of times each one should be displayed. The file is divided into two parts, which are separated by a line containing only an asterisk *

The format of Schedule File:

WIDTH width
HEIGhT height
BORDER border

URL is the virtual path and name of the program or ASP file that implements the redirection.
width and height define the size of the advertisement on the page in pixels. The default is 440*60
border specifies the width of the border around the advertisement in pixels. The default is 1. Use 0 for no border.

The first section is optional, and sets the default values that apply to all the advertisements in the schedule. If we omit one or more of these optional parameters, it will use its own default values.But the asterisk * could not be omitted.

The second part-after the asterisk--may not be omitted. The following parameters are required :

adURL is the virtual path and filename of the advertisement image file

adHomeURL is the URL to jump to for this advertisement. A hyphen(-) indicates there is no link for this advertisement.

text is the text for display if the browser doesn't support graphics.

impressions is an integer indicating thee relative display time for this advertisement.

The following is an example of schedule file:

border 4
height 50
width 400


WebSite 1 Software -- Tomorrow's Technology Today.


Tech tools for programmers
World of ATL

Ad Rotator Properties


Border: Integer. The thickness of the border around the advertisement in pixels. If not set, the value in first section of the schedule file is used.
Clickable: boolean, Specifies whether the advertisement image should be displayed as a hyperlink. The default is true.

TargetFrame: String. The name of the frame in which to display the advertisers page is the user clicks the image. If omitted, the pages is loaded into the current browser window. Or this value could be set to one of the followings: _top, _new,_child,_self,_parent, or _blank.

Ad Rotator Method

GetAdvertisement(schedule_file): Uses the information in the specified schedule_file to create and return a string containing the HTML HTML required for inserting the next appropriate image into the page.

Use Ad rotator example

Dim varAD, objAD
Set objAD=Server.CreateObject("MSWC.ADRotator")
Response.Write varAD

ASP tutorial
What is ASP
Install IIS
VBScript or JScript
ClientSide vs ServerSide scripting
ASP execution order
Dealing with Form
More Form example
Variable &Variant
Local variable
Global variable
Use if_then_else
Use Select Case
For_Next loop
Do_while loop
Subroutine vs Function
Request Object
Count Keyword
Using QueryString
Application, Method, Events
Create Virtual Directory
Save array in Application
Session, Method, Events
Using Cookie
Server Object
Ad Rotator
Content Linker
Dictionary object
Filesystemobject Object




Best books about ASP & ASP.Net from Amazon
Beginning Dynamic Websites : with ASP.NET Web Matrix (Programmer to Programmer) (Paperback) Build Your Own ASP.NET Website Using C# & VB.NET (Build Your Own) (Paperback) Professional Active Server Pages 3.0 (Programmer to Programmer) (Paperback) ASP.NET Cookbook (Paperback) ASP.NET Kick Start (Paperback)


Printer Inkjet A Z lyricsLearn ChineseHome|PHP|Swing|HTML|JavaScript|ASP|JAVA|Forum|WebTip|Contact Us
Copyright © All rights reserved(new). Privacy|Copyright
designed by

Please help us cover the web site maintenance fee.
barcode scanner Thermal Printer credit card machine bar code printer