PHP Warning: preg_split() expects parameter 2 to be string, array given
-
Hi Jeff,
I reported this issue a while ago with another one here. That second problem was fixed, but this one persists even with version 2.5 of the plugin.
Full message in Apache’s
error.log
:preg_split() expects parameter 2 to be string, array given in /wp-content/plugins/prismatic/inc/prismatic-core.php on line 56
and
PHP Warning: count(): Parameter must be an array or an object that implements Countable in /wp-content/plugins/prismatic/inc/prismatic-core.php on line 57
This is what line 56 of
prismatic-core.php
looks like:$split = preg_split("/(\[prismatic_encoded.*\].*\[\/prismatic_encoded\])/Us", $text, -1, PREG_SPLIT_DELIM_CAPTURE);
Apparently, the variable
$text
may contain an array in certain cases.Note: as indicated in my earlier post, this might occur in conjunction with ACF Pro.
- The topic ‘PHP Warning: preg_split() expects parameter 2 to be string, array given’ is closed to new replies.