note 31618 deleted from function.ereg by kennyt

From: Date: Wed, 26 Jan 2005 03:48:38 +0000
Subject: note 31618 deleted from function.ereg by kennyt
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-83966@lists.php.net to get a copy of this message
Note Submitter: mel AT the DASH eend DOT org ---- To match an IPv4 address, the following should work (untested): '^ ([0-9]{1,2}|[01][0-9]{2}|2[0-4][0-9]|25[0-5])\. ([0-9]{1,2}|[01][0-9]{2}|2[0-4][0-9]|25[0-5])\. ([0-9]{1,2}|[01][0-9]{2}|2[0-4][0-9]|25[0-5])\. ([0-9]{1,2}|[01][0-9]{2}|2[0-4][0-9]|25[0-5]) $' Without the line breaks, obv. Each segment should match any number less than 256 (including zero) with 1-3 digits, including leading zeroes.

« previous php.notes (#83966) next »