Title: More PHP issues
Last modified: November 30, 2023

---

# More PHP issues

 *  [malteme](https://wordpress.org/support/users/malteme/)
 * (@malteme)
 * [2 years, 5 months ago](https://wordpress.org/support/topic/more-php-issues/)
 * I’m seeing the following errors related to `json_decode`. Based on the other 
   threads about PHP 8 compatibility, this shouldn’t be an issue anymore? I tried
   switching my site back to PHP 7.4 but I’m still seeing a similar error there.
 * Zotpress Plugin Version: 7.3.7
   WordPress Version: 6.4.1
 * **With PHP 7.4.33:**
   AH01071: Got error ‘PHP message: PHP Warning: json_decode()
   expects parameter 1 to be string, object given in /path/to/httpdocs/wp-content/
   plugins/zotpress/lib/shortcode/shortcode.request.php on line 340PHP message: 
   PHP Warning: count(): Parameter must be an array or an object that implements
   Countable in /path/to/httpdocs/wp-content/plugins/zotpress/lib/shortcode/shortcode.
   request.php on line 403’, referer: [https://domain.de/wp-admin/admin.php?page=Zotpress](https://domain.de/wp-admin/admin.php?page=Zotpress)
 * **With PHP 8.1.26:**
   AH01071: Got error ‘PHP message: PHP Fatal error: Uncaught
   TypeError: json_decode(): Argument #1 ($json) must be of type string, WpOrg\Requests\
   Utility\CaseInsensitiveDictionary given in /path/to/httpdocs/wp-content/plugins/
   zotpress/lib/shortcode/shortcode.request.php:340\nStack trace:\n#0 /path/to/httpdocs/
   wp-content/plugins/zotpress/lib/shortcode/shortcode.request.php(340): json_decode()\
   n#1 /path/to/httpdocs/wp-includes/class-wp-hook.php(324): Zotpress_shortcode_request()\
   n#2 /path/to/httpdocs/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters()\
   n#3 /path/to/httpdocs/wp-includes/plugin.php(517): WP_Hook->do_action()\n#4 /
   path/to/httpdocs/wp-admin/admin-ajax.php(188): do_action()\n#5 {main}\n thrown
   in /path/to/httpdocs/wp-content/plugins/zotpress/lib/shortcode/shortcode.request.
   php on line 340’, referer: [https://domain.de/wp-admin/admin.php?page=Zotpress](https://domain.de/wp-admin/admin.php?page=Zotpress)
 * The same thing happens if I view the relevant frontend page. I’m not actually
   sure when this problem started as I only noticed it after clearing the cache 
   in the plugin settings. Apparently it was happily using the cached data up until
   now.
 * The shortcode I’m using:
   `[zotpress userid="12345" collection="1234ABCD" sortby
   ="date" order="desc" cite="yes" target="new"]`

The topic ‘More PHP issues’ is closed to new replies.

 * ![](https://ps.w.org/zotpress/assets/icon-256x256.png?rev=1995512)
 * [Zotpress](https://wordpress.org/plugins/zotpress/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/zotpress/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/zotpress/)
 * [Active Topics](https://wordpress.org/support/plugin/zotpress/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/zotpress/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/zotpress/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [malteme](https://wordpress.org/support/users/malteme/)
 * Last activity: [2 years, 5 months ago](https://wordpress.org/support/topic/more-php-issues/)
 * Status: not resolved