• Resolved sanvir

    (@sanvir)


    I am experiencing an issue where my website displays this message “The site is experiencing technical difficulties.” after both the lite and pro plugins are enabled.

    After inspecting the error logs, the following error message was found:

    PHP Fatal error: Uncaught Error: Class 'dokan_update_2_9_4_order_post_author' not found in /nas/content/live/mysite/wp-content/plugins/dokan-lite/includes/background-processes/class-dokan-background-processes.php:22\nStack trace:\n#0 /nas/content/live/mysite/wp-content/plugins/dokan-lite/dokan.php(450): Dokan_Background_Processes->__construct()\n#1 /nas/content/live/mysite/wp-includes/class-wp-hook.php(286): WeDevs_Dokan->after_plugins_loaded('')\n#2 /nas/content/live/mysite/wp-includes/class-wp-hook.php(310): WP_Hook->apply_filters(NULL, Array)\n#3 /nas/content/live/mysite/wp-includes/plugin.php(465): WP_Hook->do_action(Array)\n#4 /nas/content/live/mysite/wp-settings.php(394): do_action('plugins_loaded')\n#5 /nas/content/live/mysite/wp-config.php(117): require_once('/nas/content/li...')\n#6 /nas/content/live/mysite/wp-load.php(37): require_once('/nas/content/li...')\n#7 /nas/content/live/mysite/wp-blog-header.php(13): require_once('/nas/content/li...')\n#8 /nas/content/live/mysite in /nas/content/live/mysite/wp-content/plugins/dokan-lite/includes/background-processes/class-dokan-background-processes.php on line 22

    Any idea how to solve this?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hello @sanvir,

    The error you shared seems a bit known to me. It usually occurs if the plugin is updated from a very backdated version. Please open your wp-content/plugins/dokan-lite/includes/upgrade/ and open dokan-upgrade-2.7.3.php file.

    Now, just comment out (// insert before the line) the line number 79 and the code is //dokan_update_order_meta_273() and then activate Dokan.

    I hope this will help you with a fix. Let me know if the issue remains.

    Best Regards.

    • This reply was modified 5 years, 1 month ago by roshni07.
    • This reply was modified 5 years, 1 month ago by roshni07.
    Thread Starter sanvir

    (@sanvir)

    Hi @roshni07

    I commented out that line and activated Dokan, but got the same result.

    The error is occurring in dokan-upgrade-2.9.4.php. Is there something that can be edited in that file maybe?

    This is the content of dokan-upgrade-2.9.4.php

    <?php
    
    /**
     * Update post_author id for shop_orders
     *
     * @since 2.9.4
     *
     * @return void
     */
    function dokan_update_shop_order_post_author() {
        $processor_file = DOKAN_INC_DIR . '/upgrades/background-processes/class_dokan_update_2_9_4_order_post_author.php';
    
        include_once $processor_file;
    
        $processor = new Dokan_Update_2_9_4_Order_Post_Author();
    
        $args = array(
            'updating' => 'shop_order_post_author',
            'paged'    => 0
        );
    
        $processor->push_to_queue( $args )->dispatch_process( $processor_file );
    }
    
    dokan_update_shop_order_post_author();
    
    /**
     * Update refund table structure
     *
     * @return void
     */
    function dokan_update_refund_table_2_9_4() {
        global $wpdb;
    
        $table_name = $wpdb->prefix . 'dokan_refund';
    
        if ( $wpdb->get_var( $wpdb->prepare("SHOW TABLES LIKE %s", $table_name ) ) !== $table_name ) {
            return;
        }
    
        $columns = array( 'item_qtys', 'item_totals', 'item_tax_totals' );
    
          foreach ( $columns as $column ) {
            $wpdb->query(
                $wpdb->prepare(
                    "ALTER TABLE <code>{$wpdb->prefix}dokan_refund</code>
                    MODIFY COLUMN %s varchar(200)", $column
                )
            );
        }
    }
    
    dokan_update_refund_table_2_9_4();
    
    Nazmul Hassan

    (@nazmulhassann20)

    @sanvir, It seems like somehow this class is not working on your website while it is running fine on our local server. Because we did not change anything on the file and in the class which you have shown on this error.
    It could be better if we can have a direct look at the issue. I hope you will create a support ticket to us directly via our website else, it would be very complicated to provide any specific solution as it is not a usual issue.

    Cheers!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Error 500 after enabling both Dokan-lite and Dokan-pro’ is closed to new replies.