Title: PHP Fatal error:  Uncaught TypeError: explode()
Last modified: June 28, 2025

---

# PHP Fatal error:  Uncaught TypeError: explode()

 *  [Amanda Giles](https://wordpress.org/support/users/shedonist/)
 * (@shedonist)
 * [10 months, 4 weeks ago](https://wordpress.org/support/topic/php-fatal-error-uncaught-typeerror-explode/)
 * I’m getting this error on my site on a fairly regular basis:
 * PHP Fatal error:  Uncaught TypeError: explode(): Argument #2 ($string) must be
   of type string, array given in /xxx-hidden-xxx/wp-content/plugins/responsive-
   lightbox/includes/class-frontend.php:802
 * I’m not sure which page it’s happening on, but it looks like an Elementor page–
   yet all the ones I’ve looked at don’t seem to use a WP Media widget . like indicated
   in the stack. I’m wondering if anyone has seen this or has any idea how to resolve
   it. The full error chain is:
 * [28-Jun-2025 15:47:15 UTC] PHP Fatal error: Uncaught TypeError: explode(): Argument#
   2 ($string) must be of type string, array given in /xxx-hidden-xxx/wp-content/
   plugins/responsive-lightbox/includes/class-frontend.php:802
   Stack trace: **0**/
   xxx-hidden-xxx/wp-content/plugins/responsive-lightbox/includes/class-frontend.
   php(802): explode() **1** /xxx-hidden-xxx/wp-content/plugins/responsive-lightbox/
   includes/functions.php(43): Responsive_Lightbox_Frontend->get_gallery_shortcode_images()**
   2** /xxx-hidden-xxx/wp-content/plugins/responsive-lightbox/includes/class-frontend.
   php(2187): rl_get_gallery_shortcode_images() **3** /xxx-hidden-xxx/wp-includes/
   class-wp-hook.php(326): Responsive_Lightbox_Frontend->basic_slider_gallery_shortcode()**
   4** /xxx-hidden-xxx/wp-includes/plugin.php(205): WP_Hook->apply_filters() **5**/
   xxx-hidden-xxx/wp-includes/media.php(2708): apply_filters() **6** /xxx-hidden-
   xxx/wp-includes/widgets/class-wp-widget-media-gallery.php(129): gallery_shortcode()**
   7** /xxx-hidden-xxx/wp-includes/widgets/class-wp-widget-media.php(257): WP_Widget_Media_Gallery-
   >render_media() **8** /xxx-hidden-xxx/wp-content/plugins/elementor/includes/widgets/
   wordpress.php(284): WP_Widget_Media->widget() **9** /xxx-hidden-xxx/wp-content/
   plugins/elementor/includes/base/controls-stack.php(2374): Elementor\Widget_WordPress-
   >render() **10** /xxx-hidden-xxx/wp-content/plugins/elementor/includes/base/widget-
   base.php(636): Elementor\Controls_Stack->render_by_mode() **11** /xxx-hidden-
   xxx/wp-content/plugins/elementor/includes/base/widget-base.php(774): Elementor\
   Widget_Base->render_content() **12** /xxx-hidden-xxx/wp-content/plugins/elementor/
   includes/base/element-base.php(492): Elementor\Widget_Base->print_content() **
   13** /xxx-hidden-xxx/wp-content/plugins/elementor/includes/base/element-base.
   php(1453): Elementor\Element_Base->print_element() **14** /xxx-hidden-xxx/wp-
   content/plugins/elementor/includes/base/element-base.php(492): Elementor\Element_Base-
   >print_content() **15** /xxx-hidden-xxx/wp-content/plugins/elementor/includes/
   base/element-base.php(1453): Elementor\Element_Base->print_element() **16** /
   xxx-hidden-xxx/wp-content/plugins/elementor/includes/base/element-base.php(492):
   Elementor\Element_Base->print_content() **17** /xxx-hidden-xxx/wp-content/plugins/
   elementor/core/base/document.php(1895): Elementor\Element_Base->print_element()**
   18** /xxx-hidden-xxx/wp-content/plugins/elementor/core/base/document.php(1811):
   Elementor\Core\Base\Document->do_print_elements() **19** /xxx-hidden-xxx/wp-content/
   plugins/elementor/core/base/document.php(1208): Elementor\Core\Base\Document-
   >print_elements() **20** /xxx-hidden-xxx/wp-content/plugins/elementor/includes/
   frontend.php(1201): Elementor\Core\Base\Document->print_elements_with_wrapper()**
   21** /xxx-hidden-xxx/wp-content/plugins/elementor/includes/frontend.php(1096):
   Elementor\Frontend->get_builder_content() **22** /xxx-hidden-xxx/wp-includes/
   class-wp-hook.php(324): Elementor\Frontend->apply_builder_in_content() **23**/
   xxx-hidden-xxx/wp-includes/plugin.php(205): WP_Hook->apply_filters() **24** /
   xxx-hidden-xxx/wp-includes/post-template.php(256): apply_filters() **25** /xxx-
   hidden-xxx/wp-content/themes/nhbm/template-parts/content-model-yachting.php(39):
   the_content() **26** /xxx-hidden-xxx/wp-includes/template.php(812): require(‘/
   home/nhbmorg/p…’) **27** /xxx-hidden-xxx/wp-includes/template.php(745): load_template()**
   28** /xxx-hidden-xxx/wp-includes/general-template.php(206): locate_template()**
   29** /xxx-hidden-xxx/wp-content/themes/nhbm/single-model-yachting-news.php(18):
   get_template_part() **30** /xxx-hidden-xxx/wp-includes/template-loader.php(106):
   include(‘/home/nhbmorg/p…’) **31** /xxx-hidden-xxx/wp-blog-header.php(19): require_once(‘/
   home/nhbmorg/p…’) **32** /xxx-hidden-xxx/index.php(17): require(‘/home/nhbmorg/
   p…’) **33** {main} thrown in /xxx-hidden-xxx/wp-content/plugins/responsive-lightbox/
   includes/class-frontend.php on line 802
    -  This topic was modified 10 months, 4 weeks ago by [Amanda Giles](https://wordpress.org/support/users/shedonist/).
      Reason: Added tags

The topic ‘PHP Fatal error:  Uncaught TypeError: explode()’ is closed to new replies.

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

## Tags

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

 * 0 replies
 * 1 participant
 * Last reply from: [Amanda Giles](https://wordpress.org/support/users/shedonist/)
 * Last activity: [10 months, 4 weeks ago](https://wordpress.org/support/topic/php-fatal-error-uncaught-typeerror-explode/)
 * Status: not resolved