Two probably easy ones.....

Results 1 to 2 of 2

Thread: Two probably easy ones.....

  1. #1
    Join Date
    Dec 1969

    Default Two probably easy ones.....

    I am writing a small script that does some error checking. The Q&#039;s are:<BR><BR>1) Say I have a variable called myname how do I say "If myname is not alphanumeric, at least 2 chars long and not any special characters ( &#039; is allowed) Then mynameerror = True"<BR><BR>2) If you have found an error and you want to pass all of the original information back to the first page I could send it all in the quesrystring. However I would like to add it to a form and auto submit the form - can this be done?

  2. #2
    Join Date
    Dec 1969

    Default RE: Two probably easy ones.....

    1. Research VBScript&#039;s or JScript&#039;s string functions, or better still, regular expressions.<BR><BR>2. Yes, build a form with the appropriate values then use JavaScript to submit the form in an onLoad event handler (document.forms[0].submit()). This will have to happen on the client so you are assuming that their browser supports JavaScript.

Posting Permissions

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