This will be just some short examples of ASP code


<%   %>
Whatever you put in these tags will be read as ASP

response.write
This is how you write something to the page

'
Comment line

include virtual="file.inc"
Goes at the top of the page

=date
Displays the date in number values

=time
Displays the time the code was produced by the server

=hour(now)
Produces the Hours

=minute(now)
Produces the Minutes

=second(now)
Produces the seconds

=now
Goes by the format (YYYY/MM/DD)

=month(now)
Gives you the number of the month

=monthname(month(now))
Actual name of the month

And now for the more complicated stuff

randomize()
randomize is required for randomising numbers for some reason

DIM r2,randNum,Ray(10)
just loading the variables

Ray(0)=round(rnd()*50)
Ray(1)=round(rnd()*50)
Ray(2)=round(rnd()*50)
Ray(3)=round(rnd()*50)
Ray(4)=round(rnd()*50)
Ray(5)=round(rnd()*50)
Ray(6)=round(rnd()*50)
Ray(7)=round(rnd()*50)
Ray(8)=round(rnd()*50)
Ray(9)=round(rnd()*50)
Ray(10)=round(rnd()*50)

making the array

for i=0 to 10
response.write(i &" number is " &Ray(i) &"<br>")
next

just telling the script to give the array different numbers

randNum=rnd()
response.write("<br>" &randNum &"<br>")

A Random number

r2=round(randNum)
response.write(r2 &"<br>")

the next line is a rounded random number

randNum2=round(rnd()*10)
if randNum2=5 then
response.write("<b>5")
else
if randNum2>6 then
response.write(randNum2 &" is more than 5")
else
response.write(randNum2 &" is less than 5")
end if
end if

A random number that determines if it is greater or less than 5, if it is 5, then it writes that it is 5.