none
vbscript in htm page RRS feed

  • Question

  • Hi real newbie here.

    Im trying to get VBScript into an existing htm page. What I need it to do is look at a "date" value and make a decision. If "date" is less than "now" then document.write "Contact Admin", or if its greater, redirect this htm page to another page. Any help would be appreciated please, thanks

                   

    <SCRIPT LANGUAGE="VBScript">

    <%

    d= Now()

    e=(CDate("27/01/2016 15:00"))

    if  d > e then

    Response.Write "Contact your Administrator"

    else

    Response.Redirect "index2.asp"

    End if

     %>
    -->

    </SCRIPT>

    Tuesday, February 16, 2016 9:08 AM

Answers