Professional Web Applications Themes

eregi Help Needed - PHP Development

Can someone please tell me why this function always evaluates to true regardless of what I enter? Thanks... if (!eregi ("A-Za-z", $frm_member_name)) { // invalid characters $php_login_status = "not ok"; }...

  1. #1

    Default eregi Help Needed

    Can someone please tell me why this function always evaluates to true
    regardless of what I enter?

    Thanks...


    if (!eregi ("A-Za-z", $frm_member_name))
    {
    // invalid characters
    $php_login_status = "not ok";
    }

    Ralph Freshour Guest

  2. #2

    Default Re: eregi Help Needed

    "Ralph Freshour" <ralphprimemail.com> wrote in message
    news:4m34lvstklrr9pppqmfsr7v80hak72rp9s4ax.com...
    > Can someone please tell me why this function always evaluates to
    true
    > regardless of what I enter?
    >
    > Thanks...
    >
    >
    > if (!eregi ("A-Za-z", $frm_member_name))
    > {
    > // invalid characters
    > $php_login_status = "not ok";
    > }
    >
    if (!eregi ("^[a-z]+$", $frm_member_name))
    {
    // invalid characters
    $php_login_status = "not ok";
    }



    powerboy Guest

Similar Threads

  1. eregi question
    By Peter in forum PHP Development
    Replies: 7
    Last Post: December 17th, 05:25 PM
  2. Eregi() to extract author meta tag?
    By Jane Doe in forum PHP Development
    Replies: 5
    Last Post: October 17th, 09:48 PM
  3. #25669 [Fbk]: eregi() vs. 8-bit chars in regex
    By sniper@php.net in forum PHP Development
    Replies: 0
    Last Post: September 26th, 01:20 PM
  4. #24902 [Opn->Bgs]: eregi matching incorrectly
    By edink@php.net in forum PHP Development
    Replies: 0
    Last Post: August 1st, 01:25 PM
  5. Help with eregi & eregi_replace
    By fartsniff in forum PHP Development
    Replies: 1
    Last Post: August 1st, 07:10 AM

Bookmarks

Posting Permissions

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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139