From: [EMAIL PROTECTED]
Operating system: Linux/NT
PHP version: 4.0.4pl1
PHP Bug Type: *Regular Expressions
Bug description: Function ereg array results
I'm not sure, if it's really an error or "feature" :). I would like to get $regs[10]
value, but the output is always empty.
<script language="php">
$string = "1234567890";
ereg( "^(.)(.)(.)(.)(.)(.)(.)(.)(.)(.)", $string, $regs);
echo "Whole string: " . $regs[ 0 ] . "<br>";
for ( $i = 1; $i <= 10; $i++ )
{
echo "<br>" . $i . " -> " . $regs[$i];
}
</script>
--
Edit Bug report at: http://bugs.php.net/?id=10154&edit=1
--
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]