No announcement yet.

Submit to web ASP

  • Filter
  • Time
  • Show
Clear All
new posts

  • Submit to web ASP

    Anyone have a working example of an ASP submit to web that they would care to share. I'm trying to build a product activation feature. I have the database and DSN set, I'm just too tired right now to figure out the VB script code I need to match the format in the help file. All I really need is to see an ASP page used in a submit to web that writes to a database and returns a value. I can recode it to meet my needs. Thanks..

    P.S. If for some reason I figure out how to do this myself, I will post my code...

  • #2
    Re: Submit to web ASP

    This ASP page works with the Submit to Web Action (I used POST, but GET should work). The MAJOR caveat with ASP is the use of the % in the variable name. It pretty much can't be done. The problem is your fist TAG <%UserName%> uses the <% and %> which are ASP directives. No matter how I tried to encode it I could not get it to work. The good news is that the variables work without the %% around them. The problem with this script is that anywhere in your project that the word UserName appears becomes a variable. The solution I used in my project was to use a strangely worded variable then read it into a regular %% encased variable. Worked fine.

    I left out all the backend processing in determining the AuthorizedToInstall value, and would add more varabiles, but that is just window dressing...

    <!-- register.asp -->

    AuthorizedToInstall = "TRUE"
    if Name = "" then
    Name = "TestUser"
    end if

    <input type = "text" name = "Name" value = "<%= Name %>" size="20">
    <input type = "submit" value = "Submit">



    <UserName><%= Name %></UserName>

    <AuthorizedToInstall><%= AuthorizedToInstall %></AuthorizedToInstall></p>