| is a special regex char and you would need to escape it to use it in a
literal sense.  However, if you are splitting on a simple single char like
that, using split() is very inefficient.  Use explode() instead, and since
explode() doesn't use regular expressions you wouldn't have to escape the
| with explode().

-Rasmus

On Sun, 30 Sep 2001, Big5ive wrote:

> Hi folks!
>
> Warning: unexpected regex error (14) in C:\WINDOWS\Profiles\Flo\My
> Documents\Projekte\www.big5ive.homeip.net\BBB\control\members_edit.php on
> line 18
>
> members_edit.php :
> <html>
>  <head>
>   <title>Members verwalten</title>
>  </head>
>  <link rel="stylesheet" href="big5ive.css" type="text/css">
>  <body onMouseOver="self.status='Members verwalten'">
>   <p><h1 align=center>Members verwalten</h1></p><br><br><br>
>   <table>
>    <tr align=left>
>     <th>Benutzername</th>
>     <th>Status</th>
>     <th>Registriert seit</th>
>    </tr>
>    <?php
>     $memberlist="http://big5ive.homeip.net/BBB/members/members.txt";;
>     $fp=fopen("$memberlist","r");
>     $user=fgets($fp, 4096);
>     $list = split("|",$user, 3);
>     echo "<tr
> align=left><td>$list[0]</td><td>$list[1]</td><td>$list[2]</td></tr>";
>    ?>
>    </table>
>  </body>
> </html>
>
> How can i fix this error?
> Content of members.txt is
> Big5ive|Admin|24.09.2001
>
> The script should read the text file and split the content by | and write it
> in a table.
> Any help would be amazing!
>
> --
> Big5ive
>
>
>
>


-- 
PHP General 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]

Reply via email to