Announcement

Collapse
No announcement yet.

anyone wanna write me 6 regex's??? pleeease?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • anyone wanna write me 6 regex's??? pleeease?

    hey im devloping a page and i want to validate data for entry into a data base using regular expressions....

    i've spent hours trying to write the expressions myself but i cant get them to work reliably, if anyone could post regular expressions which will test for:

    six digits only
    seven digits only
    eight to ten digits
    255 or less alphanumeric charcters
    255 or less letters
    an email address

    i would be very gratefull and probably regrow most of my hair in no time....

  • #2
    i can't but this sort of thing must be used as examples in any php book or beginners guide is it not? i know that email checking will be in most scripts, including vbulletin!
    Christopher Padfield
    Web Based Helpdesk
    DeskPRO v3.0.3 Released - Download Demo Now!

    Comment


    • #3
      [0-9]{6}
      [0-9]{7}
      [0-9]{8,10}
      [a-z0-9]{1,255}
      [a-z]{1,255}
      ^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,3})$

      Usefull article

      There you go

      Comment


      • #4
        thanks heaps man

        Comment

        Loading...
        Working...
        X