mirror of
https://github.com/PostgreSQL-For-Wordpress/postgresql-for-wordpress.git
synced 2025-07-29 17:27:13 +02:00
Replace split() with explode() for PHP 7
It appears that the split function, which has been deprecated since PHP 5.3.0, has finally been removed in PHP 7. Since it is being used to split on a literal string, use explode() instead. Fixes #1 Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
This commit is contained in:
@ -525,7 +525,7 @@
|
||||
$pattern = '/INSERT INTO (\w+)\s+\([ a-zA-Z_"]+/';
|
||||
preg_match($pattern, $sql, $matches);
|
||||
$GLOBALS['pg4wp_ins_table'] = $matches[1];
|
||||
$match_list = split(' ', $matches[0]);
|
||||
$match_list = explode(' ', $matches[0]);
|
||||
if( $GLOBALS['pg4wp_ins_table'])
|
||||
{
|
||||
$GLOBALS['pg4wp_ins_field'] = trim($match_list[3],' () ');
|
||||
|
Reference in New Issue
Block a user