Title: Warning: Illegal string offset &#8216;terms&#8217;
Last modified: January 12, 2021

---

# Warning: Illegal string offset ‘terms’

 *  [tictok](https://wordpress.org/support/users/tictok/)
 * (@tictok)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/warning-illegal-string-offset-terms/)
 * Hi Aurorata
 * I’ve been using your excellent plugin for a while now and it’s been working great
   for us.
 * However today any category I visit displays a bunch of PHP warnings (below).
 * I’m trying to troubleshoot it. I updated a few plugins today, which included 
   WooCommerce to 4.9.0. However just downgraded that back to 4.8.0 but the warnings
   still persists.
 * It’s obviously something to do with categories (terms)… any idea where I should
   look to troubleshoot?
 * Many thanks
 *     ```
       Warning: Illegal string offset 'terms' in /plugins/reorder-post-within-categories/public/class-reorder-post-within-categories-public.php on line 130
   
       Warning: count(): Parameter must be an array or an object that implements Countable in /plugins/reorder-post-within-categories/public/class-reorder-post-within-categories-public.php on line 130
   
       Warning: Illegal string offset 'terms' in /plugins/reorder-post-within-categories/public/class-reorder-post-within-categories-public.php on line 130
   
       Warning: count(): Parameter must be an array or an object that implements Countable in /plugins/reorder-post-within-categories/public/class-reorder-post-within-categories-public.php on line 130
   
       Warning: Illegal string offset 'terms' in /plugins/reorder-post-within-categories/public/class-reorder-post-within-categories-public.php on line 130
   
       Warning: count(): Parameter must be an array or an object that implements Countable in /plugins/reorder-post-within-categories/public/class-reorder-post-within-categories-public.php on line 130
       ```
   

Viewing 7 replies - 1 through 7 (of 7 total)

 *  Thread Starter [tictok](https://wordpress.org/support/users/tictok/)
 * (@tictok)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/warning-illegal-string-offset-terms/#post-13899380)
 * Just want to report that I decided to hide PHP warnings for now, but the re-ordering
   doesn’t actually work on the front end.
 * However downgrading your plugin back down to 2.9.0 (from the recent 2.9.1 update)
   fixed the issue for me. PHP warnings gone and re-ordering works again.
 *  Plugin Author [Aurovrata Venet](https://wordpress.org/support/users/aurovrata/)
 * (@aurovrata)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/warning-illegal-string-offset-terms/#post-13916073)
 * thank for reporting this. I notice a small bug which could be at the origin of
   these warnings.
 * I am releasing a fix shortly, v2.9.2. Let me know if it fixes it.
 *  Thread Starter [tictok](https://wordpress.org/support/users/tictok/)
 * (@tictok)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/warning-illegal-string-offset-terms/#post-13924713)
 * Hi there – thanks for the bug fix!
    Unfortunately there are still issues 🙁
 * The `Warning: count(): Parameter must be an array or an object` warnings are 
   now all gone, so that’s good.
 * However the `Warning: Illegal string offset 'terms' in /plugins/reorder-post-
   within-categories/public/class-reorder-post-within-categories-public.php on line
   130` warning remains and the sorting doesn’t work. (I can sort in the back end,
   but changes don’t display on the front end, and the PHP warnings are visible).
 * I’ve tried with nothing other than the default 2021 theme, WooCommerce and your
   plugin. Nothing else installed or active, just the two plugins.
 * Back to 2.9.0 for me. Just thought I’d let you know!
    Thanks
 * Screenshots:
    [https://snipboard.io/3HwFBN.jpg](https://snipboard.io/3HwFBN.jpg)
   [https://snipboard.io/sjTaQX.jpg](https://snipboard.io/sjTaQX.jpg)
    -  This reply was modified 5 years, 4 months ago by [tictok](https://wordpress.org/support/users/tictok/).
    -  This reply was modified 5 years, 4 months ago by [tictok](https://wordpress.org/support/users/tictok/).
 *  Plugin Author [Aurovrata Venet](https://wordpress.org/support/users/aurovrata/)
 * (@aurovrata)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/warning-illegal-string-offset-terms/#post-13926134)
 * > Warning: Illegal string offset ‘terms’
 * shouldn’t be triggered, unless you have a non-std way of building your queries.
 * Can you tell me how you are building your queries which are triggering this warning?
 *  Thread Starter [tictok](https://wordpress.org/support/users/tictok/)
 * (@tictok)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/warning-illegal-string-offset-terms/#post-13926489)
 * Hi there Aurovrata –
 * In the example yesterday there was nothing out of the ordinary. No special queries(
   un-modified/fresh templates), no plugins, default wordpress theme, empty functions.
   php.
 * I wonder if your plugin no longer works with WooCommerce product categories, 
   but I believe they’re really just a standard custom taxonomy.
 * A couple of the product categories do have hierarchy… i.e a few categories are
   children of a parent category.
 * I’ll test again on a fresh install today.
 * Like I mentioned though, everything works perfectly in 2.9.0 (sorting works as
   expected, no php warning) – something changed in more recent versions.
 * Many thanks
 *  Plugin Author [Aurovrata Venet](https://wordpress.org/support/users/aurovrata/)
 * (@aurovrata)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/warning-illegal-string-offset-terms/#post-13927577)
 * > I wonder if your plugin no longer works with WooCommerce product categories
 * shouldn’t be the case, warning messages are not errors per say. Are you not able
   to see your products ranked properly?
 * I will try to run some test on a WooCommerce setup
 *  Plugin Author [Aurovrata Venet](https://wordpress.org/support/users/aurovrata/)
 * (@aurovrata)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/warning-illegal-string-offset-terms/#post-14549216)
 * are you still facing this issue?

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘Warning: Illegal string offset ‘terms’’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/reorder-post-within-categories_c18d38.
   svg)
 * [ReOrder Posts within Categories](https://wordpress.org/plugins/reorder-post-within-categories/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/reorder-post-within-categories/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/reorder-post-within-categories/)
 * [Active Topics](https://wordpress.org/support/plugin/reorder-post-within-categories/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/reorder-post-within-categories/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/reorder-post-within-categories/reviews/)

 * 7 replies
 * 2 participants
 * Last reply from: [Aurovrata Venet](https://wordpress.org/support/users/aurovrata/)
 * Last activity: [4 years, 11 months ago](https://wordpress.org/support/topic/warning-illegal-string-offset-terms/#post-14549216)
 * Status: not resolved