Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New Coder
    Join Date
    May 2006
    Posts
    29
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question preg pattern question

    say i have:
    <input name="test1" id="test2" type="test3" />

    but:
    1) not all fields are required
    2) they can be in any order.

    i can easily make a pattern that matches them in that order,and i can add a "?" to the end of each to make it so that they arent required. but what about order? how do i make it so that the order dosn't matter.

    so that like i can have it like:
    <input type="test1" name="test2" />
    or
    <input id="test1" type="test3" id="test2" />

    and it will still match

  • #2
    Regular Coder
    Join Date
    Mar 2006
    Posts
    187
    Thanks
    5
    Thanked 0 Times in 0 Posts
    your attributes are screwed up check out http://www.w3schools.com/tags/tag_input.asp the name and id should be the same as in javascript, ie uses name and mozilla uses id! (I found out the hard way)

  • #3
    New Coder
    Join Date
    May 2006
    Posts
    29
    Thanks
    0
    Thanked 0 Times in 0 Posts
    dude yes i completely made that up as an example!!! i am not actually using that.
    now can someone please help me?


  •  

    Posting Permissions

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