Results 1 to 4 of 4
  1. #1
    Join Date
    May 2005
    Location
    Nevada, USA
    Posts
    2,888
    Provided Answers: 6

    Unanswered: Value not carrying forward correctly

    I've got a reservation form that is pretty much working properly, but has a quirk. I've got a couple of lines like this:

    <p>Name of party:&nbsp; <input type="text" name="PassName" size="50" value = <% = request.form("Passname") %> > * </p>

    The purpose (forgive me if I'm stating the obvious) is to carry forward the user's input if validation fails and they come back. It's working to a degree, but the quirk is that it will truncate the user input at the first space. In other words if I type

    blah blah

    and something causes the form to fail validation (they forgot to enter something else), I'll end up with

    blah

    in that field. I can type something longer, and it will still drop everything after the first space ("blahblahblah blah" will come back as "blahblahblah"). If the form submits correctly, the user input will go into the table correctly, so my assumption is that the problem is with the "value=..." bit.

    Any ideas on why this is happening?

    TIA
    Paul

  2. #2
    Join Date
    Mar 2003
    Location
    The Bottom of The Barrel
    Posts
    6,102
    Provided Answers: 1
    Are you urlencoding your value? Depending on how your validation works, you might be choking on seeing " " where you need %20.

    How does this validation of yours work?
    oh yeah... documentation... I have heard of that.

    *** What Do You Want In The MS Access Forum? ***

  3. #3
    Join Date
    Oct 2006
    Location
    CA
    Posts
    210
    What happens when you put quotes around your ASP variable.

    <p>Name of party:&nbsp; <input type="text" name="PassName" size="50" value = "<% = request.form("Passname") %>" > * </p>

  4. #4
    Join Date
    May 2005
    Location
    Nevada, USA
    Posts
    2,888
    Provided Answers: 6
    I'm weak in html/asp, so bear with me. By the way, one thing I've noticed in testing is that the 4 input textboxes like that one all do this, but a textarea box does not.

    Well, vich saved me having to paste my validation code. The quotes worked!

    Thanks guys
    Paul

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •