Jump to content

Archived

This topic is now archived and is closed to further replies.

Perry

[Solved] CSS not loading outside of editor

Recommended Posts

Perry

Hello there,

We have started experiencing a crippling issue within the last few days. It seems that ever since three days ago the CSS will not load for our pages outside of the DMS editor. Inside of the editor everything appears to be looking fine, but after publishing and viewing the page in a new browser our elements are all over the place, and in the console it appears that there is an error stating that the CSS did not get loaded. Looking through FTP, it seems that the two CSS files in the pagelines folder in wp-content are now missing. We did not access this folder or modify any files prior to this.  What kind of problem could this be? We are totally halted on any work we can perform until this is solved, so any help would be greatly appreciated. 

An example of the phenomenon: http://datesafe2.21thirteenhost.com/category/ask-mike/

Best,

Perry

Share this post


Link to post
Share on other sites
Perry

In addition, when we attempt to add to add renamed css from another functional DMS site strange behavior occurs. The files are added, but soon after new files with new names are added to the folder, and in the chrome console the file the site is searching for is also changed. Since this appears to be a dynamically generated file we attempted to load the css files remotely through the custom script section, but the file declaration was nowhere to be found in the index. So at this point we have tried everything we could think of, to no avail. 

Share this post


Link to post
Share on other sites
Simon

You are using a page cache.

So the cached page has a different css path. When you save your settings a new css file is generated, but the css file url is different in your cached page because that isnt refreshed.

Ive never heard of the cache plugin you are using.

Somewhere in the DMS settings there is an alternative css url setting, cant remember where it is, probably advanced or something.

Also, you are using the old 'customize' plugin which was for the product before dms, is this intentional?

Share this post


Link to post
Share on other sites
Perry

Hi Simon, and thanks so much for replying. My name is Perry - my assistant Kyle wrote the earlier posts.

If you would be kind enough, please use this site as an example: http://bradley.21thirteenhost.com (because it is a 5 page site, not a zillion-page site like http://datesafe2.21thirteenhost.com/category/ask-mike/ )

Your answer makes sense. However, the issue persists.

On both sites ( we are actually having this problem on multiple sites as of a few days ago), we have no cacheing plugin installed that I know of - please let me know what you are seeing as a cacheing plugin. These are the plugins we have on http://bradley.21thirteenhost.com :

Disable Comments
DMS Professional Tools
Gravity Forms

ManageWP - Workerthis allows us to manage/backup/update our sites using the ManageWP service - could this be the cacheing plugin?

Pagelines Customize - you asked: this was recommended in the forum to use to change things like the number of words in the excerpt in the Flipper widget -
we load it on all our sites in case we need it, but are nit using it in this case so it is now deactivated

PageLines Updater
Popup Pro (from WPMU Dev)
Recent Posts Widget Extended
Sidebar Manager Light
WooCommerce
WPMU DEV Dashboard
- needed in order to use Popup Pro
Yoast SEOnot activated

I can't imagine which of these plugins is cacheing the site unless it is Worker, but we use worker in all our sites.

Prior to receiving your reply, the only page of the Bradley site that was loading the css was the "Shop" page. After receiving your reply, I found the checkbox for Enable Alternative CSS URLs in
Site Settings/Advanced - right hand column and enabled it, then I went to Site Settings/Resets and flushed Caches. After that, the home page of the Bradley site worked (except the
font-awesome icons are missing - another issue we've run into with a workaround we use), but now none of the others do.
In the editor, I went to the individual pages and refreshed and published, but it made no difference. In the Pagelines PRO settings we do not have the CDN enabled.
This issue is occurring with both the most recent version of WP (4.7) and the next earlier version.
The other strange thing that is happening (though it is most likely caused by the same issue, I would think), is that we thought that we could at least work around the issue by taking the two css files (compiled-css-core and compiled-css-sections) and putting them in a folder off site and using a <link rel="stylesheet" in the Custom/Custom Scripts area to go get the stylesheets. Then even though a new css file is generated with a different number, the site is going to go get the external stylesheets.
However, when we put the external stylesheet links in the Custom Script area, refresh and publish, then go the site outside the editor (ie in firefox or safari or on another computer), there is no difference and when we View Source, we do not see the custom script - it does not seem to be publishing.

We are really in a desperate situation as we need to complete these sites, and my fear is that if we go in to edit any of the 150+ websites we've created with DMS that are now live on the web, they will break as well. Unfortunately, we are a team of designers who know html and CSS but who are not developers and do not know php, js, etc... ignorance is NOT bliss!

I've enabled Debug mode in Advances Settings. If needed I'd be happy to provide access to the Dashboard or anything else that might help if we can safely do so.

Any help would be DEEPLY appreciated, and thank you so much in advance.
Perry
21Thirteen Design
http://21thirteen.com

 

Share this post


Link to post
Share on other sites
Simon

As I said before, disable the cache.

See this page: http://bradley.21thirteenhost.com/style/?something_random=wierd

Notice it works, because I invalidated your cache with a random query string.

Like I said, Ive never heard of your cache plugin.

We include a trigger for clean_post_cache when any settings are saved, with most cache plugins this triggers it to purge its caches, but either yours does not support that or its configured not to.

Share this post


Link to post
Share on other sites
Perry

Dear Simon,

Thank you and please forgive me in advance for my ignorance, but as I said, we don't HAVE a cache plugin in the site, (that I know of) - I listed all the plugins we have in the site - if we have a cache plugin in there I don't know what it is - can you tell what it is? I'd love to disable the cache but I don't know how. The cache plugin that you mentioned that you've never heard of: what is it?? Where is it?

I'm terribly sorry that this is true, but I don't understand what a random query string is, or a trigger for clean_post_cache - we're just dumb designers here who, ideally, use the tools created by the really smart people who do all the work in companies such as yours to make what we hope are beautiful websites! ;-) So please guide me or instruct me as if I know nothing technical.

I really appreciate your being patient with me, and thank you again.

Perry

Share this post


Link to post
Share on other sites
Simon

From the source of your page: https://cl.ly/282N1C242t3A

Seems to be this: https://github.com/bluehost/endurance-page-cache

Maybe its some forced plugin on your host?

Now you switched the css file is not timestamped

http://bradley.21thirteenhost.com/wp-content/uploads/pagelines/compiled-css-sections.css

So its always loadable, even if its out of date.

Share this post


Link to post
Share on other sites
Perry

Dear Simon,

Imagine my joy when I got your reply, called Bluehost and they turned off the caching plugin* - thank you! Sadly, imagine my horror when afterwards I went into http://mhodge.21thirteenhost.com/ to do some work on it... and the issue is still there!! 

Please take a look at this site and see if you can see anything. I've enabled debug.

Also, I saw in another one of your posts that you recommended trying https://wordpress.org/plugins/sucuri-flush/ - I've uploaded the plugin and activated, but I don't know what to fill in the field for the url to be called - any suggestions? maybe this could solve the issue?

Also, I don't know what you mean in your second to last post by,

"Now you switched the css file is not timestamped

http://bradley.21thirteenhost.com/wp-content/uploads/pagelines/compiled-css-sections.css

So its always loadable, even if its out of date."

Screenshots of Bluehost and the Sucuri plugin are below.

Thank you for your continued support with this issue,

Perry

varnish.jpg

sucuri.jpg

Share this post


Link to post
Share on other sites
Simon

Varnish is a server app that caches your assets.

The wordpress MU plugin is still active. See your page source.

Share this post


Link to post
Share on other sites
Perry

Hi Simon - thanks again - for the record, Bluehost tech support said, "Oh, it's Varnish" and turned it off, which of course did no good because it was NOT varnish. They did indeed install the Endurance Page Cache plugin in the MU plugins folder of every single WP installation on our hosting account as of Dec. 14 of this year. The plugin creates a folder in the wp-content folder when it is called and puts a cached html file for every page edited in that folder - this is what was causing the issue. When we discovered this after your last post and manually deleted the plugins and the cached html files, the issue was solved. We've put in a ticket to them to remove it from all our sites and ensure it is not re-installed automatically.

Thank you for your help and your patience. Please consider this issue resolved.

My best,

Perry

Share this post


Link to post
Share on other sites
Simon

At least the Bluehost server techs and their support staff are both clued up now. Shame there is no way to turn it off. Our host also has varnish and php opcache and we have full control over them via a neat control page.

Share this post


Link to post
Share on other sites

  • Similar Content

    • Michael Kummer
      By Michael Kummer+
      Hi guys!
      I have noticed that my primary sidebar becomes intermittently invisible when browsing through various blog articles on michaelkummer.com/blog.
      See:
      https://www.dropbox.com/s/z646sgoa3mfjl1j/Screenshot 2018-07-12 15.57.46.jpg?dl=0 and https://www.dropbox.com/s/vdledzzgginvwgv/Screenshot 2018-07-12 15.57.57.jpg?dl=0
      Upon refresh, the sidebar appears. I have been using the following CSS code to hide the sidebar on mobile without any issues. 
      @media only screen and (max-width: 993px) {
      /* hide sidebars */
           .plsb {
              display: none !important;
          }
      }
      I tried to add the following CSS to force the sidebar to show on screens that are wider than 994 pixels but to no avail. Any clue what could be causing this issue?
    • Michael Kummer
      By Michael Kummer+
      Hi guys!
      I am using the LESS/CSS Pagelines extension and tried to add the following code to make use of FontAwesome:
      a.c2a:before {
          content: "\f07a\00a0";
          font-family: "Font Awesome 5 Pro";
          Font-weight: 900;
          font-style: normal;
          font-weight: normal;
          text-decoration: inherit;
          padding-left: 4px;
      }
       
      The issue is that as soon as I have the CSS via the Custom Styling text box, Pagelines (or the extension) strips out the backslashes (\). As a result, I had to abandon the CSS/LESS extension and instead add all my CSS code to a separate .css file.
      Is there a fix or workaround for this?
      Thanks
      Michael
    • MiraAdmin
      By MiraAdmin+
      Looking for some help on a recently developed issue. Editor will not load. 
      Theme:  DMS2
      Error from:  Chrome - Inspector - console view
      Error message: Refused to execute script from 'http://xxxx.xxx/wp-content/themes/dms/dms/editor/js/gettext.js/?ver=4.9.7' because its MIME type ('text/html') is not executable, and strict MIME type checking is enabled.
      Occurs on all sites on same server. 
      WP versions to 4.9.5, 4.9.6, 4.9.7 = same behavior. Worked properly on these same versions until 07/04/2018.
      No new plugins. Isolating plugins offers same behavior. 
      Server vendor reports no changes, patches, etc. 
      Server re-starts no impact.  

      Thank you. 
    • glyph.marketing
      By glyph.marketing+
      Hello, I am having a problem similar to that experienced by Michael Kummer here. We have pages that show this automatic scrolling issue (examples here and here) and it is sufficiently annoying that we have seen customers bounce while trying to convert. Strangely, it only happens at specific resolutions, so it can be difficult to reproduce. In general we can only consistently reproduce it on a 4k resolution with a browser width between 1517 and 1536px. 
      Thanks to Michael Kummer's help we were able to set the overflow-anchor property to none in the entire body, which fixed the issue as far as we can tell, but also obviously disabled scroll anchoring for the whole site. I tried applying it to the specific element that looked like it was being reloaded, which was the PL Meganav extension, but that was unsuccessful. 
      Can anyone help us figure out which element or ID we can apply this property to, so that we can fix the scrolling issue but not disable scroll anchoring for the entire site?
      Thank you - 
      Glyph Language Services
    • Tom
      By Tom
      Hi, I desperatly need some help fixing the DMS editor. It's not loading at all en gets stuck at 'Oops there may be an issue loading.'
      I'm able to find this two warnings in chrome:
       
      www.studiekeuzemaken.nl/:4607 Uncaught SyntaxError: Invalid or unexpected token
      pl.editor.js:740 Uncaught TypeError: Cannot read property 'lang' of undefined
          at Object.reloadConfig (pl.editor.js:740)
          at Object.startUp (pl.editor.js:72)
          at HTMLDocument.<anonymous> (pl.editor.js:10)
          at i (jquery.js:2)
          at Object.fireWith [as resolveWith] (jquery.js:2)
          at Function.ready (jquery.js:2)
          at HTMLDocument.K (jquery.js:2)
       
      When I dug into the first warning a little deeper (line 4607)I found out that there is a typo in a css that's causing the SyntaxError. Because the css is placed within a textbox and the editor is not loading I'm not able to fix this.

      What can I do?

      Please help!

      - Tom
       
       
       
×