Title: PHP Warnings Trying to access array offset&#8230;
Last modified: April 5, 2022

---

# PHP Warnings Trying to access array offset…

 *  Resolved [fdanell](https://wordpress.org/support/users/fdanell/)
 * (@fdanell)
 * [4 years, 1 month ago](https://wordpress.org/support/topic/php-warnings-trying-to-access-array-offset/)
 * Hi,
    I’m getting a lot of warnings in php.error.log
 * `Trying to access array offset on value of type bool in /home/xxxx6/public_html/
   wp-content/plugins/restrict-content/legacy/includes/shortcodes.php on line 44`
 * About 100 warnings per day. I haven’t noticed any lost functionality however.

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

 *  Plugin Contributor [Israel Barragan](https://wordpress.org/support/users/reedyseth/)
 * (@reedyseth)
 * [4 years, 1 month ago](https://wordpress.org/support/topic/php-warnings-trying-to-access-array-offset/#post-15601267)
 * Hi [@fdanell](https://wordpress.org/support/users/fdanell/) thank you for reporting
   this issue. I will be glad to help on this. Is this error happening using the
   shortcodes or without using them?
    -  This reply was modified 4 years, 1 month ago by [Israel Barragan](https://wordpress.org/support/users/reedyseth/).
 *  Plugin Contributor [Israel Barragan](https://wordpress.org/support/users/reedyseth/)
 * (@reedyseth)
 * [4 years, 1 month ago](https://wordpress.org/support/topic/php-warnings-trying-to-access-array-offset/#post-15601309)
 * [@fdanell](https://wordpress.org/support/users/fdanell/) Also please, could you
   share your PHP Version and the Restrict Content plugin version?
 *  Thread Starter [fdanell](https://wordpress.org/support/users/fdanell/)
 * (@fdanell)
 * [4 years, 1 month ago](https://wordpress.org/support/topic/php-warnings-trying-to-access-array-offset/#post-15601506)
 * I am using the shortcodes on some pages.
    Restrict content Version 3.0.4 PHP 
   version 8.0.18
 * I remember 7-8 months back when had the exact same errors from the restrictcontent.
   php that, back then,(before 2.2.10) had the exact same “if statement cluster”
   in the beginning of the file as shortcodes.php do now.
 * This was my request back then:
    [https://wordpress.org/support/topic/restrictcontent-php-generating-ton-of-php-warnings/](https://wordpress.org/support/topic/restrictcontent-php-generating-ton-of-php-warnings/)
 *  Plugin Contributor [Israel Barragan](https://wordpress.org/support/users/reedyseth/)
 * (@reedyseth)
 * [4 years, 1 month ago](https://wordpress.org/support/topic/php-warnings-trying-to-access-array-offset/#post-15603943)
 * Good day [@fdanell](https://wordpress.org/support/users/fdanell/) I have replicated
   your issue. We are working to fix it. This fix will be on the next release.
 * You can also switch into the newer version of RC.
 *  Plugin Contributor [Israel Barragan](https://wordpress.org/support/users/reedyseth/)
 * (@reedyseth)
 * [4 years ago](https://wordpress.org/support/topic/php-warnings-trying-to-access-array-offset/#post-15616626)
 * A new version of the plugin including this fix has been released.
 * If you have a spear minutes please leave us a review.
    [https://wordpress.org/support/plugin/restrict-content/reviews/#new-post](https://wordpress.org/support/plugin/restrict-content/reviews/#new-post)
 *  Thread Starter [fdanell](https://wordpress.org/support/users/fdanell/)
 * (@fdanell)
 * [4 years ago](https://wordpress.org/support/topic/php-warnings-trying-to-access-array-offset/#post-15617555)
 * Awesome guys!
 *  Plugin Contributor [highprrrr](https://wordpress.org/support/users/highprrrr/)
 * (@highprrrr)
 * [4 years ago](https://wordpress.org/support/topic/php-warnings-trying-to-access-array-offset/#post-15625360)
 * [@fdanell](https://wordpress.org/support/users/fdanell/) Thank you so much for
   bringing this to our attention!
 * If you wouldn’t mind, could you take a second to leave us a quick review here
   on wp.org?
 * And please don’t hesitate to reach out if you have any other issues!
 * -James

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

The topic ‘PHP Warnings Trying to access array offset…’ is closed to new replies.

 * ![](https://ps.w.org/restrict-content/assets/icon.svg?rev=3529325)
 * [Membership Plugin - Kadence Memberships](https://wordpress.org/plugins/restrict-content/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/restrict-content/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/restrict-content/)
 * [Active Topics](https://wordpress.org/support/plugin/restrict-content/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/restrict-content/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/restrict-content/reviews/)

## Tags

 * [legacy](https://wordpress.org/support/topic-tag/legacy/)

 * 7 replies
 * 3 participants
 * Last reply from: [highprrrr](https://wordpress.org/support/users/highprrrr/)
 * Last activity: [4 years ago](https://wordpress.org/support/topic/php-warnings-trying-to-access-array-offset/#post-15625360)
 * Status: resolved