You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
PHP Fatal error: Uncaught TypeError: array_reverse(): Argument #1 ($array) must be of type array, string given in /www/gossipchi_431/public/wp-content/plugins/seo-by-rank-math/includes/modules/instant-indexing/class-instant-indexing.php:410
#252
Open
slim16165 opened this issue
Oct 12, 2023
· 2 comments
Describe the bug
I'm encountering two critical errors when attempting to save a post in WordPress using the Rank Math plugin. These errors prevent the post from being saved and cause a crash.
To Reproduce
Log into the WordPress admin panel.
Open an existing post or create a new one.
Edit the post and try to save it.
A fatal error occurs, preventing the post from being saved.
Expected behavior
After making edits to the post, I expect the post to save successfully without any errors.
**Additional details on server **
PHP Version: 8.0
WordPress Version: 6.3.1
Rank Math Version: 1.0.203
Additional context
Here are the detailed errors:
Error related to array_reverse():
[error] FastCGI sent in stderr: "PHP message: PHP Fatal error: Uncaught TypeError: array_reverse(): Argument #1 ($array) must be of type array, string given in .../wp-content/plugins/seo-by-rank-math/includes/modules/instant-indexing/class-instant-indexing.php:410
Stack trace:
#0 .../wp-content/plugins/seo-by-rank-math/includes/modules/instant-indexing/class-instant-indexing.php(410): array_reverse('a:100:{i:0;a:5:...')
#1 .../wp-content/plugins/seo-by-rank-math/includes/modules/instant-indexing/class-instant-indexing.php(325): RankMath\Instant_Indexing\Instant_Indexing->api_submit('https://...', false)
#2 .../wp-includes/class-wp-hook.php(310): RankMath\Instant_Indexing\Instant_Indexing->save_post(...)
...
Error related to "rankingKeywords":
[error] FastCGI sent in stderr: "PHP message: PHP Warning: Undefined array key "rankingKeywords" in .../wp-content/plugins/seo-by-rank-math-pro/includes/modules/analytics/class-posts.php on line 92" while reading response header from upstream...
IMPORTANT:
I managed to resolve the bug, and here's the patch in git format for version 1.0.203. However, I'm primarily not a PHP developer, so I would greatly appreciate if you could review my solution. solve issue.zip
IMPORTANT:
I managed to resolve the bug, and here's the patch in git format for version 1.0.203. However, I'm primarily not a PHP developer, so I would greatly appreciate if you could review my solution. solve issue.zip
Describe the bug
I'm encountering two critical errors when attempting to save a post in WordPress using the Rank Math plugin. These errors prevent the post from being saved and cause a crash.
To Reproduce
Expected behavior
After making edits to the post, I expect the post to save successfully without any errors.
**Additional details on server **
Additional context
Here are the detailed errors:
array_reverse()
:IMPORTANT:
I managed to resolve the bug, and here's the patch in git format for version 1.0.203. However, I'm primarily not a PHP developer, so I would greatly appreciate if you could review my solution. solve issue.zip
This is a small part of the dump of the log history:
string(16356) "a:100:{i:0;a:5:{s:3:"url";s:32:"https://gossipchi.it/ariete/202/";s:6:"status";i:200;s:17:"manual_submission";b:0;s:7:"message";s:2:"OK";s:4:"time";i:1695884902;}i:1;a:5:{s:3:"url";s:45:"https://gossipchi.it/colapesce-dimartino/210/";s:6:"status";i:200;s:17:"manual_submission";b:0;s:7:"message";s:2:"OK";s:4:"time";i:1695884945;}i:2;a:5:{s:3:"url";s:35:"https://gossipchi.it/colla-zio/213/";s:6:"status";i:200;s:17:"manual_submission";b:0;s:7:"message";s:2:"OK";s:4:"time";i:1695884961;}i:3;a:5:{s:3:"url";s:42:"https://gossipchi.it/gianluca-grignani/48/";s:6:"status";i:200;s:17:"manual_submission";b:0;s:7:"message";s:2:"OK";s:4:"time";i:1695885005;}i:4;a:5:{s:3:"url";s:42:"https://gossipchi.it/elodie-di-patrizi/42/";s:6:"status";i:200;s:17:"manual_submission";b:0;s:7:"message";s:2:"OK";s:4:"time";i:1695885029;}i:5;a:5:{s:3:"url";s:28:"https://gossipchi.it/lda/96/";s:6:"status";i:200;s:17:"manual_submission";b:0;s:7:"message";s:2:"OK";s:4:"time";i:1695885051;}i:6;a:5:{s:3:"url";s:37:"https://gossipchi.it/sanremo-2023/39/";s:6:"status";i:200;s:17:"manual_submission";b:0;s:7:"message";s:2:"OK";s:4:"time";i:1695885080;}i:7;a:5:{s:3:"url";s:45:"https://gossipchi.it/i-cugini-di-campagna/57/";s:6:"status";i:200;s:17:"manual_submission";b:0;s:7:"message";s:2:"OK";s:4:"time";i:1695885121;}i:8;a:5:{s:3:"url";s:43:"https://gossipchi.it/silvana-giacobini/303/";s:6:"status";i:200;s:17:"manual_submission";b:0;s:7:"message";s:2:"OK";s:4:"time";i:1695885145;}i:9;a:5:{s:3:"url";s:41:"https://gossipchi.it/dorothea-wierer/300/";s:6:"status";i:200;s:17:"manual_submission";b:0;s:7:"message";s:2:"OK";s:4:"time";i:1695885168;}i:10;a:5:{s:3:"url";s:38:"https://gossipchi.it/anna-favella/297/";s:6:"status";i:200;s:17:"manual_submission";b:0;s:7:"message";s:2:"OK";s:4:"time";i:1695885191;}i:11;a:5:{s:3:"url";s:41:"https://gossipchi.it/ana-quiles-boix/291/";s:6:"status";i:200;s:17:"manual_submission";b:0;s:7:"message";s:2:"OK";s:4:"time";i:1695885734;}i:12;a:5:{s:3:"url";s:39:"https://gossipchi.it/jason-
The text was updated successfully, but these errors were encountered: