• Resolved chinochinako

    (@chinochinako)


    When trying to edit my homepage template from the Bento theme, I click on “Edit Page” at the top of the page (or click directly on the Home page within my “Pages” on my Dashboard) and I’m getting the following error:

    “This block has encountered an error and cannot be previewed.”

    With this error in place I cannot access my template to make changes to my homepage. I am using Bento Expansion Pack version 2.1.2, and Page Builder by SiteOrigin version 2.11.2. I am receiving no PHP errors and I’m unsure how to correct this issue without leaving my Bento theme behind.

Viewing 15 replies - 1 through 15 (of 15 total)
  • Thread Starter chinochinako

    (@chinochinako)

    Now I am getting the following error message on all of my pages, making it impossible to update any of them using the block system:

    “This block contains unexpected or invalid content.”

    My only options are listed as “Resolve” or “Convert to HTML”. Maybe the overall issue is with SiteOrigin?

    Thread Starter chinochinako

    (@chinochinako)

    Okay, I was able to correct the SiteOrigin error I had on my pages by changing my theme to Twenty Twenty and deactivating all plugins besides SiteOrigin ones. After that I reactivated Bento and activated all plugins one-by-one. I can now use SiteOrigin to create and edit my pages again without error.

    Still cannot edit my homepage, error is the same as described in my first post above.

    Theme Author satoristudio

    (@satoristudio)

    Hey @chinochinako , thanks for choosing Bento! Let’s get to the bottom of this ?? could you please try reproducing the error, and then opening the browser console (see how) and copying any red messaged from there to this chat? Seeing the specific message will help me troubleshoot more effectively! (also, if your website is already online and open to visitors, it will also help if I see the live page) Thanks for your patience!

    Thread Starter chinochinako

    (@chinochinako)

    Hi and thank you! I’m getting the following errors:

    ReferenceError: Can’t find variable: wpColorPickerL10n
    TypeError: undefined is not an object (evaluating ‘o[i].slick[s]’)

    And the following warning:

    wp.editor.BlockControls is deprecated. Please use wp.blockEditor.BlockControls instead.

    Does this help at all?

    Theme Author satoristudio

    (@satoristudio)

    Thank you for the details! I’m still trying to replicate the error on my machine, so far without success – but meanwhile, could you please check if the solution mentioned in this thread works for you?

    Thread Starter chinochinako

    (@chinochinako)

    I’ve tried uploading the code, but nothing changed for me. It seems that the user experiencing issues in that thread was using Elementor, but I am not using that plugin at all, so that could be why it didn’t correct anything on my side. I wish I could upload images so I could show you visually what I am experiencing, but I don’t see an option here for that.

    When I go into my Appearance -> Theme Editor I get the following error at the top of the code block section:

    Notice: Undefined variable: error in /home2/chinochi/public_html/wp-admin/theme-editor.php on line 277

    When I open that file, I see the following between lines 270-280:

    270: <?php wp_print_theme_file_tree( wp_make_theme_file_tree( $allowed_files ) ); ?>
    271:
    272:
    273:
    274: </div>
    275:
    276: <?php
    277: if ( $error ) :
    278: echo ‘<div class=”error”><p>’ . __( ‘File does not exist! Please double check the name and try again.’ ) . ‘</p></div>’;
    279: else :
    280: ?>

    Maybe this can help you figure out a fix?

    Thread Starter chinochinako

    (@chinochinako)

    Whoops! Here’s a better look at the code I mis-typed above:

    <?php wp_print_theme_file_tree( wp_make_theme_file_tree( $allowed_files ) ); ?>
    			</ul>
    		</li>
    	</ul>
    </div>
    
    <?php
    if ( $error ) :
    	echo '<div class="error"><p>' . __( 'File does not exist! Please double check the name and try again.' ) . '</p></div>';
    else :
    	?>
    Theme Author satoristudio

    (@satoristudio)

    I recommended that thread as a potential solution because Elementor is using the same color picker as Bento, which seems to be the root of the problem ??

    To be clear, though – is the error appearing when you click on “Edit Page” at the top of the home page, or in the “Edit Theme” section, or both?

    Thread Starter chinochinako

    (@chinochinako)

    It happens when I click Edit Page at the top of the homepage when I’m logged in. I can’t find a place for Edit Theme so I’m not sure how to check that.

    I followed this link: https://www.hostinger.com/tutorials/how-to-create-wordpress-child-theme to create a child theme function file to upload the code you pointed me to, but i ended up with a fatal error:

    Fatal error: Cannot redeclare wp_default_custom_scripts() (previously declared in /home2/chinochi/public_html/wp-content/themes/bento-child/functions.php:5) in /home2/chinochi/public_html/wp-content/themes/bento/functions.php on line 1176
    
    There has been a critical error on your website. Please check your site admin email inbox for instructions.
    • This reply was modified 4 years, 2 months ago by chinochinako.
    Theme Author satoristudio

    (@satoristudio)

    You can use this child theme template instead, it’s been prepared specifically for Bento

    Thread Starter chinochinako

    (@chinochinako)

    Downloaded that template and added the code to the functions.php file that you pointed out in the other thread. After uploading it to my Themes folder and activating it, I ended up with the same fatal error as above:

    “Fatal error: Cannot redeclare wp_default_custom_scripts() (previously declared in /home2/chinochi/public_html/wp-content/themes/bento-child/functions.php:16) in /home2/chinochi/public_html/wp-content/themes/bento/functions.php on line 1176
    There has been a critical error on your website.”

    What can I do to correct this? I’m uninstalling the bento-child theme to gain access to my site again in the meantime.

    Thread Starter chinochinako

    (@chinochinako)

    Still no luck with editing my homepage. I even turned off my Coming Soon page just in the hope that it would somehow fix the issue I’m having, but I’m still getting the SiteOrigin layout message of “This block has encounter an error and cannot be previewed”. I’m not getting this error on any other page and even after uninstalling and reinstalling SiteOrigin plugins the home page continued to give me the same message when I try to “Edit Page”.

    I’m sorry this is such a tough fix… Is there anything else I can try?

    Thread Starter chinochinako

    (@chinochinako)

    It’s now been three weeks since I last posted and still no fix in sight. Is there anything else I can try so I can edit my homepage again? I paid for Bento Pro a while ago and I’d like to continue to use this theme for much longer than only a few months.

    • This reply was modified 4 years, 1 month ago by chinochinako.
    Thread Starter chinochinako

    (@chinochinako)

    UPDATE: After testing several things, I concluded that the issue was not with the Bento theme itself, but with SiteOrigins Widgets. I’m working with the SiteOrigins team now on a fix and they have been able to replicate my issue on their side and figured out that it was something within the Carousel widget itself (which was only installed on my home page, hence that being the only page I could no longer edit).

    Once they have a patch tested I’ll update this thread again and mark it closed if they are successful. Thank you for your help along the way.

    Thread Starter chinochinako

    (@chinochinako)

    SiteOrigin has found a fix: “This fix will [also] be included in the next formal release of the Widgets Bundle.” If anyone else is having this error–pages cannot be edited while you have the Carousel widget on them–please reach out to SiteOrigins for a patch or wait until the next formal release of the SiteOrigins Widgets Bundle.

    Thanks again!

    – Jeannette ChinoChinako

Viewing 15 replies - 1 through 15 (of 15 total)
  • The topic ‘Home Page Editor Broken’ is closed to new replies.