Title: Fatal error: Uncaught TypeError
Last modified: May 20, 2019

---

# Fatal error: Uncaught TypeError

 *  Resolved [byothe](https://wordpress.org/support/users/byothe/)
 * (@byothe)
 * [7 years ago](https://wordpress.org/support/topic/fatal-error-uncaught-typeerror-3/)
 * Hello,
 * First of all, thank you for this really good pluggin !
 * I am encountering an error on one of my AMP page… I have no idea what the problem
   is. I have this message (you cans see it directly on the page) :
 * `Fatal error: Uncaught TypeError: Argument 1 passed to DOMNode::replaceChild()
   must be an instance of DOMNode, string given in /datas/vol2/w4a138130/var/www/
   byothe.fr/htdocs/wp-content/plugins/accelerated-mobile-pages/includes/vendor/
   amp/includes/sanitizers/class-amp-gallery-block-sanitizer.php:136 Stack trace:#
   0 /datas/vol2/w4a138130/var/www/byothe.fr/htdocs/wp-content/plugins/accelerated-
   mobile-pages/includes/vendor/amp/includes/sanitizers/class-amp-gallery-block-
   sanitizer.php(136): DOMNode->replaceChild('', Object(DOMElement)) #1 /datas/vol2/
   w4a138130/var/www/byothe.fr/htdocs/wp-content/plugins/accelerated-mobile-pages/
   includes/vendor/amp/includes/class-amp-content.php(129): AMPforWP\AMPVendor\AMP_Gallery_Block_Sanitizer-
   >sanitize() #2 /datas/vol2/w4a138130/var/www/byothe.fr/htdocs/wp-content/plugins/
   accelerated-mobile-pages/includes/vendor/amp/includes/class-amp-content.php(94):
   AMPforWP\AMPVendor\AMP_Content_Sanitizer::sanitize('<div class='mai...', Array,
   Array) #3 /datas/vol2/w4a138130/var/www/byothe.fr/htdocs/wp-c in /datas/vol2/
   w4a138130/var/www/byothe.fr/htdocs/wp-content/plugins/accelerated-mobile-pages/
   includes/vendor/amp/includes/sanitizers/class-amp-gallery-block-sanitizer.php
   on line 136`
 * Thank you for your help,
    -  This topic was modified 7 years ago by [byothe](https://wordpress.org/support/users/byothe/).
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Ffatal-error-uncaught-typeerror-3%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 1 replies (of 1 total)

 *  Plugin Author [Mohammed Kaludi](https://wordpress.org/support/users/mohammed_kaludi/)
 * (@mohammed_kaludi)
 * [7 years ago](https://wordpress.org/support/topic/fatal-error-uncaught-typeerror-3/#post-11552124)
 * We have fixed this issue in the latest update, so please update the pluign to
   the latest version(0.9.97.53) and do let us know.

Viewing 1 replies (of 1 total)

The topic ‘Fatal error: Uncaught TypeError’ is closed to new replies.

 * ![](https://ps.w.org/accelerated-mobile-pages/assets/icon-256x256.png?rev=1693616)
 * [AMP for WP - Accelerated Mobile Pages](https://wordpress.org/plugins/accelerated-mobile-pages/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/accelerated-mobile-pages/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/accelerated-mobile-pages/)
 * [Active Topics](https://wordpress.org/support/plugin/accelerated-mobile-pages/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/accelerated-mobile-pages/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/accelerated-mobile-pages/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [Mohammed Kaludi](https://wordpress.org/support/users/mohammed_kaludi/)
 * Last activity: [7 years ago](https://wordpress.org/support/topic/fatal-error-uncaught-typeerror-3/#post-11552124)
 * Status: resolved