Hi All, I've written a inifile class and was trying to improve it but got stuck trying to read all the sections:
[Section 1] name=value [Section 2] name=value $Inifile is the inifile read into an array but the following doesn't work: $Sections = preg_grep("/(?<=^\[)([^\[\]]+)(?=\]$)/i", $IniFile); It always includes the [ ] brackets. Don't look behinds/aheads work with preg_grep? Or am I doing something wrong. Thanks. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php