Columns are collapsing at wrong time

I have a row with 2 columns. It looks and works like normal, but sometimes when editing the right column will collapse like in mobile view (one underneath the other).

The screen I am editing on is not small enough to make that happen so it feels like a bug.

Hey @thecashbag,

Thanks for writing in. Before we can list this as a bug, we first need to prove this really is a problem with X or Cornerstone and not caused by third party factors. With that said, please do the following:

  1. Clear all caches including browser cache then deactivate your caching plugin and other optimization plugins.

  2. If you’re using a CDN, please clear the CDN’s cache and disable optimization services or it’s much better if you disconnect you CDN. This is for troubleshooting only.

  3. Test for a plugin conflict. You can do this by deactivating all third party plugins, and seeing if the problem remains. If it’s fixed, you’ll know a plugin caused the problem, and you can narrow down which one by reactivating them one at a time.

  4. If you have customizations, remove custom CSS, Javascript and templates.

  5. Reset your htaccess file by renaming it to .htaccess-bak. Then in WP Admin Menu, go to Settings > Permalinks and just click the Save Changes button.

  6. Contact your host to increase your allocated memory or do it yourself by adding this code in your wp-config.php

define( 'WP_MEMORY_LIMIT', '256M' );
define( 'WP_MAX_MEMORY_LIMIT', '512M' );

Thanks.

I cloned my site to a staging area (test.elementpaints.com) and ran all those tests, the bug is still present.

You can login to the new staging site using the same credentials as before.

Hi There,

Thank you for cooperation. It seems the issue is coming from that JavaScript that you have on the RAW Content element.

Please remove that from your content, and move it to the <head> area of the site using the following code snippet.

add_action('wp_head','custom_javascript');
function custom_javascript () { ?>

<!-- Replace this with your javascript code -->

<?php }

Add that to your child theme’s functions.php file.

Hope it helps,
Cheers!

The content inside the Raw Content area is a widget provided by Google Trends.

I cannot move it to the head. I have to paste in their JavaScript code where I want the widget to appear on the page.

Also I doubt Google would supply faulty code. Are you sure the conflict isn’t something coming from within Cornerstone? Maybe some something Theme X has overlooked with their code implementation?

Hi there,

It’s sure a compatibility issue between your javascript code and the builder preview. It’s the same with other bundled plugins, it requires integration between the builder and javascript for it to work. All javascript should be loaded with Wordpress Enqueue and it’s Wordpress’s standard, https://developer.wordpress.org/reference/functions/wp_enqueue_script/.

But sometimes it may still not work if the script doesn’t follow the standard at all. It’s the same when google maps changed their implementation of Map API and it causes more issues, the preview can’t capture that javascript generated by map embed code (it’s generated on the fly).

Hence, it always depends on the scripts you’re implementing. The builder is just there ready to capture the scripts you’re implementing.

All I could do for now is add this to our issue tracker.

Thanks!

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.