Title: PHP Warning: Undefined array key &#8220;img_crop&#8221;
Last modified: December 12, 2023

---

# PHP Warning: Undefined array key “img_crop”

 *  Resolved [devbd](https://wordpress.org/support/users/devbd/)
 * (@devbd)
 * [2 years, 5 months ago](https://wordpress.org/support/topic/php-warning-undefined-array-key-img_crop/)
 * Hi, after upgrading PHP to 8.1, your plugin started generating a PHP warning.
   The warning is :
 * PHP Warning: Undefined array key “img_crop” in /wp-content/plugins/modula-best-
   grid-gallery/includes/public/templates/modula-gallery.php on line 81, referer:/
   wp-admin/edit.php?post_type=page
 * All components on the website are up-to-date and website is on the newest version
   of WordPress too. Could you support me with this warning, please? As you can 
   see, it’s getting logged only when I edit the page in the back end of WordPress.
 * Regards,

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

 *  [Razvan Aldea](https://wordpress.org/support/users/raldea89/)
 * (@raldea89)
 * [2 years, 5 months ago](https://wordpress.org/support/topic/php-warning-undefined-array-key-img_crop/#post-17275183)
 * Hello [@devbd](https://wordpress.org/support/users/devbd/),
 * Could you please let me know if you are using Modula’s Gutenberg block on that
   page or are you using the simple shortcode to display the gallery? And if you
   are using the Gutenberg block, if you switch to the normal shortcode does the
   problem still persist?
   Also, could you please go to the edit screen of the problematic
   gallery, open the screen options and toggle on the “Debug gallery” box.
 * > [View post on imgur.com](https://imgur.com/a/ZUQzYiq)
 * 
   After that please locate the “Debug gallery” box
 * > [View post on imgur.com](https://imgur.com/a/NsTYreW)
 * Export the gallery and send the downloaded file to us please. It contains the
   settings of the gallery so that we can import into our testing servers and try
   to replicate as detailed as we can what you are experiencing.
   Warmly,Razvan
 *  Plugin Author [Cristian Raiber](https://wordpress.org/support/users/cristianraiber-1/)
 * (@cristianraiber-1)
 * [2 years, 5 months ago](https://wordpress.org/support/topic/php-warning-undefined-array-key-img_crop/#post-17287691)
 * Closing this due to inactivity.

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

The topic ‘PHP Warning: Undefined array key “img_crop”’ is closed to new replies.

 * ![](https://ps.w.org/modula-best-grid-gallery/assets/icon-256x256.png?rev=3095828)
 * [Modula Image Gallery - Photo Grid & Video Gallery](https://wordpress.org/plugins/modula-best-grid-gallery/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/modula-best-grid-gallery/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/modula-best-grid-gallery/)
 * [Active Topics](https://wordpress.org/support/plugin/modula-best-grid-gallery/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/modula-best-grid-gallery/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/modula-best-grid-gallery/reviews/)

 * 2 replies
 * 3 participants
 * Last reply from: [Cristian Raiber](https://wordpress.org/support/users/cristianraiber-1/)
 * Last activity: [2 years, 5 months ago](https://wordpress.org/support/topic/php-warning-undefined-array-key-img_crop/#post-17287691)
 * Status: resolved