Title: Fatal Error With in plugin
Last modified: February 4, 2020

---

# Fatal Error With in plugin

 *  Resolved [Ashish Jangra](https://wordpress.org/support/users/ashishjangra-1/)
 * (@ashishjangra-1)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/fatal-error-with-in-plugin/)
 * Warning: Use of undefined constant AMPFORWP_CUSTOM_THEME – assumed ‘AMPFORWP_CUSTOM_THEME’(
   this will throw an Error in a future version of PHP) in /wp-content/plugins/accelerated-
   mobile-pages/components/theme-loader.php on line 18
 * Warning: require_once(/functions.php): failed to open stream: No such file or
   directory in /wp-content/plugins/accelerated-mobile-pages/components/theme-loader.
   php on line 22
 * Fatal error: require_once(): Failed opening required ‘/functions.php’ (include_path
   =’\php\PEAR’) in /wp-content/plugins/accelerated-mobile-pages/components/theme-
   loader.php on line 22
 * There has been a critical error on your website.

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

 *  Plugin Author [Ahmed Kaludi](https://wordpress.org/support/users/ahmedkaludi/)
 * (@ahmedkaludi)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/fatal-error-with-in-plugin/#post-12396092)
 * Can you please share your website URL? So we can analyze it and help you fix 
   the issue for you.
 *  Thread Starter [Ashish Jangra](https://wordpress.org/support/users/ashishjangra-1/)
 * (@ashishjangra-1)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/fatal-error-with-in-plugin/#post-12401061)
 * Here is the URL
 * [https://bit.ly/2Uqx6gl](https://bit.ly/2Uqx6gl)
 *  Plugin Author [Ahmed Kaludi](https://wordpress.org/support/users/ahmedkaludi/)
 * (@ahmedkaludi)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/fatal-error-with-in-plugin/#post-12401236)
 * AMP is currently disabling on your website. For testing purpose can you please
   enable that option?
    -  This reply was modified 6 years, 2 months ago by [Ahmed Kaludi](https://wordpress.org/support/users/ahmedkaludi/).
 *  Plugin Author [Ahmed Kaludi](https://wordpress.org/support/users/ahmedkaludi/)
 * (@ahmedkaludi)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/fatal-error-with-in-plugin/#post-12404469)
 * This issue is fixed in the latest version of our plugin. Can you please update
   the plugin to the latest version(1.0.21)?
 *  Thread Starter [Ashish Jangra](https://wordpress.org/support/users/ashishjangra-1/)
 * (@ashishjangra-1)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/fatal-error-with-in-plugin/#post-12421394)
 * Hi Thank you for you support.. One last help
 * How can we enable on Custom Taxonomy Archive Page .. i.e my custom taxonomies
   are products so siteurl.com?products=productname&amp=true doesn’t work.
 * As we have custom archive for product taxonomy so we already have URL routes 
   defined.
 * add_rewrite_rule( ‘^/blogs/category/products/([^/]*)/?’, ‘index.php?products=
   $matches[1]’,’top’ );
 * Now i have set
 * add_rewrite_rule( ‘^/blogs/category/products/([^/]*)/amp?’, ‘/blogs/category/
   products/=$matches[1]/?amp’,’top’ );
 * this converts my url
    /blogs/category/products/PRODUCTNAME/amp
 * But as i have mentioned we have custom RULES to get the posts accordingly which
   logic are written under custom archive pages.
 * But its always keeps me on default archive page. I have create a my custom file
   as well but its not working
 * Please suggest
    -  This reply was modified 6 years, 2 months ago by [Ashish Jangra](https://wordpress.org/support/users/ashishjangra-1/).
    -  This reply was modified 6 years, 2 months ago by [Ashish Jangra](https://wordpress.org/support/users/ashishjangra-1/).
 *  Plugin Author [Ahmed Kaludi](https://wordpress.org/support/users/ahmedkaludi/)
 * (@ahmedkaludi)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/fatal-error-with-in-plugin/#post-12421664)
 * Can you please enable the custom post type option and custom taxonomies in AMP?
   
   AMP->settings->general Like this: [https://prnt.sc/r0podp](https://prnt.sc/r0podp)
   And save Permalink in AMP AMP->Settings->Permalink Like this: [https://monosnap.com/file/h4lpLeBB0gAgJCFNb4gd4Pwo8PLS7W](https://monosnap.com/file/h4lpLeBB0gAgJCFNb4gd4Pwo8PLS7W)
 *  Thread Starter [Ashish Jangra](https://wordpress.org/support/users/ashishjangra-1/)
 * (@ashishjangra-1)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/fatal-error-with-in-plugin/#post-12424559)
 * I didn’t see any option for Custom Taxonomy in settings. Refer to the screenshot
 * [https://we.tl/t-8BoxPZmvYl](https://we.tl/t-8BoxPZmvYl)
 *  Plugin Author [Ahmed Kaludi](https://wordpress.org/support/users/ahmedkaludi/)
 * (@ahmedkaludi)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/fatal-error-with-in-plugin/#post-12424748)
 * Can you please tell me you have any custom taxonomies in custom post types? If
   you have custom taxonomies in WordPress, it will be shown automatically. If you
   don’t have any custom taxonomies it does not show.
    -  This reply was modified 6 years, 2 months ago by [Ahmed Kaludi](https://wordpress.org/support/users/ahmedkaludi/).
 *  Thread Starter [Ashish Jangra](https://wordpress.org/support/users/ashishjangra-1/)
 * (@ashishjangra-1)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/fatal-error-with-in-plugin/#post-12425085)
 * Yes we have custom taxonomy.
 * // Register Custom Taxonomy
    function products_taxonomy() { $labels = array( ‘
   name’ => _x( ‘Products’, ‘Taxonomy General Name’, ‘aff’ ), ‘menu_name’ => __(‘
   Products’, ‘aff’ ), ‘all_items’ => __( ‘All Product’, ‘aff’ ), ‘parent_item’ 
   => __( ‘Parent Product’, ‘aff’ ), ‘parent_item_colon’ => __( ‘Parent Product :’,‘
   aff’ ), ‘new_item_name’ => __( ‘New Product Name’, ‘aff’ ), ‘add_new_item’ =>
   __( ‘Add New Product’, ‘aff’ ), ‘edit_item’ => __( ‘Edit Product’, ‘aff’ ), ‘
   update_item’ => __( ‘Update Product’, ‘aff’ ), ‘separate_items_with_commas’ =
   > __( ‘Separate Product with commas’, ‘aff’ ), ‘search_items’ => __( ‘Search 
   Product’, ‘aff’ ), ‘add_or_remove_items’ => __( ‘Add or Remove Product’, ‘aff’),‘
   choose_from_most_used’ => __( ‘Choose from Most Used Product’, ‘aff’ ), );
 *  $args = array(
    ‘labels’ => $labels, ‘hierarchical’ => true, ‘public’ => false,‘
   show_ui’ => true, ‘show_admin_column’ => true, ‘show_in_nav_menus’ => false, ‘
   show_tagcloud’ => false, ‘rewrite’ => array(‘slug’ => ‘products’), );
 *  register_taxonomy( ‘products’, array(‘resources’,’post’), $args );
    }
 * // Hook into the ‘init’ action
    add_action( ‘init’, ‘products_taxonomy’, 3);
 *  Thread Starter [Ashish Jangra](https://wordpress.org/support/users/ashishjangra-1/)
 * (@ashishjangra-1)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/fatal-error-with-in-plugin/#post-12425679)
 * Ohh I see its cause of “Public => false”
 * But Taxonomies is not going to be the public
 *  Thread Starter [Ashish Jangra](https://wordpress.org/support/users/ashishjangra-1/)
 * (@ashishjangra-1)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/fatal-error-with-in-plugin/#post-12425700)
 * I think I Figure this out. Thanks for your support.
 *  Plugin Author [Ahmed Kaludi](https://wordpress.org/support/users/ahmedkaludi/)
 * (@ahmedkaludi)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/fatal-error-with-in-plugin/#post-12425832)
 * Glad that it’s working now.

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

The topic ‘Fatal Error With in plugin’ 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/)

 * 12 replies
 * 2 participants
 * Last reply from: [Ahmed Kaludi](https://wordpress.org/support/users/ahmedkaludi/)
 * Last activity: [6 years, 2 months ago](https://wordpress.org/support/topic/fatal-error-with-in-plugin/#post-12425832)
 * Status: resolved