使用preg_split而不是split

I'm using FPDF v. 1.53. Now I switched to a newer PHP version. The function split is now deprecated. I had on line 108 the following code in fpdf_eps.php:

$lines = split ("
|[
]", $data);

I wanted to change it to preg_split

$lines = preg_split ("
|[
]", $data);

but than the script seems to have an error and I only get the message page not found (I always get this if a script has an error). What is wrong? The regexp?

When using regular expressions with preg, you should contain your regex inside slashes. Your regex should look like this:

$lines = preg_split ("/
|[
]/", $data)
                      ^           ^

You've missed the trailing / aswell as the one in front of the pattern:

 $lines = preg_split ("/
|[
]/", $data);
                       ^           ^