• Plans & Pricing
  • Log in
  • Get started
  • WordPress Hosting
  • WordPress for Agencies
  • Become an Affiliate
  • Domain Names
  • AI Website Builder
  • Website Builder
  • Create a Blog
  • Newsletter
  • Professional Email
  • Website Design Services
  • Commerce
  • WordPress Studio
  • Enterprise WordPress 
  • Overview
  • WordPress Themes
  • WordPress Plugins
  • WordPress Patterns
  • Google Apps
  • Support Center
  • WordPress News
  • Business Name Generator
  • Logo Maker
  • Discover New Posts
  • Popular Tags
  • Blog Search
Get started
  • Sign up
  • Log in
About
  • Plans & Pricing
Products
  • WordPress Hosting
  • WordPress for Agencies
  • Become an Affiliate
  • Domain Names
  • AI Website Builder
  • Website Builder
  • Create a Blog
  • Newsletter
  • Professional Email
  • Website Design Services
  • Commerce
  • WordPress Studio
  • Enterprise WordPress  
Features
  • Overview
  • WordPress Themes
  • WordPress Plugins
  • WordPress Patterns
  • Google Apps
Resources
  • Support Center
  • WordPress News
  • Business Name Generator
  • Logo Maker
  • Discover New Posts
  • Popular Tags
  • Blog Search
Jetpack App
  • Learn more
  • Support Center
  • Guides
  • Courses
  • Forums
  • Contact
Search
  • Support Center
  • Guides
  • Courses
  • Forums
  • Contact
Forums / Problem adding product to store

Problem adding product to store

  • Unknown's avatar
    jakhoundi · Member · Jul 1, 2023 at 10:44 am
    • Copy link Copy link
    • Add topic to favorites Add topic to favorites

    Hello all

    I am trying to add product from aliexpress to my sotre using CJDropshipping. I keep receive this errorŞ

    I talked to CJ support they said:

    There can be 3 reasons for this error, * Must check php version and not lower than 7.4 * Any plugin blocks rest apis, for example, plugins with ajax effect (try disable the plugins) * It can be theme-based (try to change the theme)

    but non worked. I also tried to autorize store to CJ using OAuth Plugin but it didnt work too.

    my site looks like this afted adding product with error:

    can you please help :(

    The blog I need help with is: (visible only to logged in users)

  • Unknown's avatar
    staff-totoro · Staff · Jul 3, 2023 at 1:22 am
    • Copy link Copy link

    Hi there,

    There can be 3 reasons for this error, * Must check php version and not lower than 7.4 

    I can confirm that your site is using PHP v 8.0. You can check this anytime by following the steps here:

    WP
    PHP Version Switching
    in WordPress.com Support
    2 min read
    WordPress.com strives to ensure sites have access to the latest compatible versions of PHP. Plugin-enabled sites can switch PHP versions when multiple supported versions are available. You can learn what versions we currently support by visiting the PHP environment guide. How to Switch PHP Versions Visit the Settings → Hosting Configuration section of your site’s dashboard.  In the W

    Any plugin blocks rest apis, for example, plugins with ajax effect (try disable the plugins) * It can be theme-based (try to change the theme)

    but non worked.

    Can you clarify what steps you took here to follow the troubleshooting suggestions from CJDropshipping support staff? You disabled all plugins (aside from WooCommerce and CJDropshipping) and you still had this error? What theme did you switch to when you tried a different theme?

    Thanks for the additional info!

  • Unknown's avatar
    staff-totoro · Staff · Jul 3, 2023 at 1:29 am
    • Copy link Copy link

    Hi again,

    On our end we did see a PHP Critical error (as mentioned in your screenshot) and you may wish to share this with CJDropshipping support staff to see if it offers any clues:

    [01-Jul-2023 10:33:28 UTC] PHP Fatal error:  Uncaught Error: Call to undefined function wc_get_default_product_type_options() in /wordpress/plugins/woocommerce/7.8.1/includes/tracks/events/class-wc-products-tracking.php:242
    Stack trace:
    #0 /wordpress/plugins/woocommerce/7.8.1/includes/tracks/events/class-wc-products-tracking.php(259): WC_Products_Tracking::get_possible_product_type_options_ids()
    #1 /wordpress/plugins/woocommerce/7.8.1/includes/tracks/events/class-wc-products-tracking.php(311): WC_Products_Tracking::get_product_type_options(149)
    #2 /wordpress/core/6.2.2/wp-includes/class-wp-hook.php(308): WC_Products_Tracking->track_product_published(149, Object(WP_Post), false, NULL)
    #3 /wordpress/core/6.2.2/wp-includes/class-wp-hook.php(332): WP_Hook->apply_filters(NULL, Array)
    #4 /wordpress/core/6.2.2/wp-includes/plugin.php(517): WP_Hook->do_action(Array)
    #5 /wordpress/core/6.2.2/wp-includes/post.php(5436): do_action('wp_after_insert...', 149, Object(WP_Post), false, NULL)
    #6 /wordpress/core/6.2.2/wp-includes/post.php(4729): wp_after_insert_post(Object(WP_Post), false, NULL)
    #7 /wordpress/plugins/woocommerce/7.8.1/includes/data-stores/class-wc-product-data-store-cpt.php(135): wp_insert_post(Array, true)
    #8 /wordpress/plugins/woocommerce/7.8.1/includes/class-wc-data-store.php(186): WC_Product_Data_Store_CPT->create(Object(WC_Product_Variable))
    #9 /wordpress/plugins/woocommerce/7.8.1/includes/abstracts/abstract-wc-product.php(1431): WC_Data_Store->create(Object(WC_Product_Variable))
    #10 /wordpress/plugins/woocommerce/7.8.1/includes/rest-api/Controllers/Version3/class-wc-rest-crud-controller.php(169): WC_Product->save()
    #11 /wordpress/plugins/woocommerce/7.8.1/includes/rest-api/Controllers/Version3/class-wc-rest-crud-controller.php(191): WC_REST_CRUD_Controller->save_object(Object(WP_REST_Request), true)
    #12 /wordpress/core/6.2.2/wp-includes/rest-api/class-wp-rest-server.php(1181): WC_REST_CRUD_Controller->create_item(Object(WP_REST_Request))
    #13 /wordpress/core/6.2.2/wp-includes/rest-api/class-wp-rest-server.php(1028): WP_REST_Server->respond_to_request(Object(WP_REST_Request), '/wc/v3/products', Array, NULL)
    #14 /wordpress/core/6.2.2/wp-includes/rest-api/class-wp-rest-server.php(442): WP_REST_Server->dispatch(Object(WP_REST_Request))
    #15 /wordpress/core/6.2.2/wp-includes/rest-api.php(410): WP_REST_Server->serve_request('/wc/v3/products')
    #16 /wordpress/core/6.2.2/wp-includes/class-wp-hook.php(308): rest_api_loaded(Object(WP))
    #17 /wordpress/core/6.2.2/wp-includes/class-wp-hook.php(332): WP_Hook->apply_filters(NULL, Array)
    #18 /wordpress/core/6.2.2/wp-includes/plugin.php(565): WP_Hook->do_action(Array)
    #19 /wordpress/core/6.2.2/wp-includes/class-wp.php(399): do_action_ref_array('parse_request', Array)
    #20 /wordpress/core/6.2.2/wp-includes/class-wp.php(780): WP->parse_request('')
    #21 /wordpress/core/6.2.2/wp-includes/functions.php(1334): WP->main('')
    #22 /wordpress/core/6.2.2/wp-blog-header.php(16): wp()
    #23 /wordpress/core/6.2.2/index.php(17): require('/wordpress/core...')
    #24 {main}
      thrown in /wordpress/plugins/woocommerce/7.8.1/includes/tracks/events/class-wc-products-tracking.php on line 242

    Hope that helps. Please let us know if you have any more questions.

  • The topic ‘Problem adding product to store’ is closed to new replies.

Tags

  • account
  • design
  • Jetpack

About this topic

  • In: Support
  • 2 participants
  • 2 replies
  • Last activity 2 years
  • Latest reply from jakhoundi

Couldn't find what you needed?

Contact us

Contact us

Get answers from our AI assistant, with access to 24/7 expert human support on paid plans.

Browse our guides

Browse our guides

Find step-by-step solutions to common questions in our comprehensive guides.

WordPress.com

Products
  • WordPress Hosting
  • WordPress for Agencies
  • Become an Affiliate
  • Domain Names
  • AI Website Builder
  • Website Builder
  • Create a Blog
  • Professional Email
  • Website Design Services
  • WordPress Studio
  • Enterprise WordPress
Features
  • Overview
  • WordPress Themes
  • WordPress Plugins
  • WordPress Patterns
  • Google Apps
Resources
  • WordPress.com Blog
  • Business Name Generator
  • Logo Maker
  • WordPress.com Reader
  • Accessibility
  • Remove Subscriptions
Help
  • Support Center
  • Guides
  • Courses
  • Forums
  • Contact
  • Developer Resources
Company
  • About
  • Press
  • Terms of Service
  • Privacy Policy
  • Do Not Sell or Share My Personal Information
  • Privacy Notice for California Users
DeutschEspañolFrançaisBahasa IndonesiaItalianoNederlandsPortuguês do BrasilSvenskaTürkçeРусскийالعربيةעִבְרִית日本語한국어简体中文繁體中文English

Mobile Apps

  • Download on the App Store
  • Get it on Google Play

Social Media

  • WordPress.com on Facebook
  • WordPress.com on X (Twitter)
  • WordPress.com on Instagram
  • WordPress.com on YouTube

Automattic

Automattic
Work With Us
    • WordPress.com Forums
    • Sign up
    • Log in
    • Copy shortlink
    • Report this content
    • Manage subscriptions