• When I try to edit a table, I receive the following notice:

    There has been a critical error on your website. Please check your site admin email inbox for instructions.

    When I check my debug log, I see the following:

    wp_redirect()
    wp-content/plugins/wc-product-table-lite/main.php:206

    Line 206 is the 11th line in the following passage (the line that begins with wp_redirect):

    /* redirect to table editor */
    add_action('plugins_loaded', 'wcpt_redirect_to_table_editor');
    function wcpt_redirect_to_table_editor( ) {
      global $pagenow;
    
      // edit
      if($pagenow == 'post.php' && isset($_GET['post']) && isset($_GET['action']) && $_GET['action'] == 'edit'){
        $post_id = (int) $_GET['post'];
        $post = get_post_type( $post_id );
        if($post === 'wc_product_table'){
          wp_redirect( admin_url( '/edit.php?post_type=wc_product_table&page=wcpt-edit&post_id=' . $post_id ) );
          exit;
        }
      }

    I have no problem creating new table or rendering the tables on live pages. The only issue is editing tables. Please advise.

Viewing 1 replies (of 1 total)
  • Plugin Author WC Product Table

    (@wcproducttable)

    Hi,

    Thank you for writing in with your query.

    This is the first time I am receiving a report of a critical error due to ‘wp_redirect’, which is a standard wp function and normally does not cause any issue in the script. That is, unless the plugin is conflicting with another module on your site – plugin / theme / custom code / server setting.

    Since this issue is unique to your site I will need further information about it to resolve this issue. Please write in to [email protected] to discuss further.

    Regards,
    Kartik

Viewing 1 replies (of 1 total)
  • The topic ‘Plugin Causes Critical Error’ is closed to new replies.