$line = "30,[CVS Core] server dot cvsignore file should be considered by client (1GCC6MB),[email protected],expert,[email protected]";
list($bugId,$bugText,$dupId,$submitId,$submitExpert,$bugFixerId) = split(",", $line);
echo $bugId.",";
echo $submitId.",";
echo $submitExpert.",";
echo $bugFixerId.",";
echo $bugText;
Here's my php code but I don't know why it shows that Undefined offset: 5
and here's the result
30,expert,[email protected],,[CVS Core] server dot cvsignore file should be considered by client (1GCC6MB)
I don't know what happened.
Thanks
This function has been DEPRECATED as of PHP 5.3.0. Relying on this feature is highly discouraged.Useexplode(',', $line);!var_dump(explode(",", $line));you will see that you only get five parts, but you are trying to list them to six variables.