home *** CD-ROM | disk | FTP | other *** search
/ Chip 1998 February / CHIP_2_98.iso / software / pelne / optionp / iis4_03.cab / iislider.asp < prev    next >
Text File  |  1997-11-12  |  1KB  |  53 lines

  1. <%@ LANGUAGE=VBScript %>
  2. <% Option Explicit %>
  3. <% Response.Expires = 0 %>
  4.  
  5. <% 
  6.  
  7. Dim quote, prop, numstops, width, selnum
  8.  
  9. quote=chr(34)
  10. prop=Request.QueryString("prop")
  11. numstops=Request.QueryString("stops")
  12. width=Request.QueryString("width")
  13. selnum=int(Request.QueryString("selnum"))
  14.  
  15. function writeSlider()
  16.  
  17.     Dim slidestr, i
  18.     
  19.     slidestr="<IMG SRC='images/sliderend.gif' WIDTH=1 HEIGHT=26 BORDER=0>"
  20.     for i=0 to numstops-2
  21.         slidestr=slidestr & drawStop(i) 
  22.         slidestr=slidestr & "<IMG SRC='images/slidersp.gif' WIDTH=" & width & " HEIGHT=26 BORDER=0>"
  23.     Next
  24.     slidestr=slidestr & drawStop(i)
  25.     slidestr=slidestr & "<IMG SRC='images/sliderend.gif' WIDTH=1 HEIGHT=26 BORDER=0>"
  26.     writeSlider=slidestr
  27. end function 
  28.  
  29. function drawStop(curr)
  30.  
  31.     Dim slidestr
  32.     
  33.     slidestr="<A HREF='javascript:parent.moveSlider(parent.document.userform." & prop & ", " & quote & prop & quote & "," & curr & ")'>"
  34.     if curr=selnum then
  35.         drawStop=slidestr & "<IMG SRC='images/slideron.gif' WIDTH=11 HEIGHT=26 BORDER=0></A>"
  36.     else
  37.         drawStop=slidestr & "<IMG SRC='images/slideroff.gif' WIDTH=11 HEIGHT=26 BORDER=0></A>"
  38.     end if
  39. end function 
  40.  
  41.  %>
  42.  
  43. <HTML>
  44. <HEAD>
  45.  
  46.     <TITLE></TITLE>
  47. </HEAD>
  48.  
  49. <BODY BGCOLOR="#CCCCCC" TOPMARGIN=0 LEFTMARGIN=0 STYLE="font-face: Helv,Arial; font-size:10pt;">
  50.     <%= writeslider() %>
  51. </BODY>
  52. </HTML>
  53.