x

main_style.css link not working

Today I entered the code editor to make some changes to the css, but found that the main_style.css link was no longer working. Instead of displaying editable code, it had been turned into some sort of empty folder [which by the way is impossible to upload anything into]. I've attached a screenshot below. Any advice would be most welcome.

image

Tags (1)
8,270 Views
Message 1 of 33
Report
32 REPLIES 32
Square

Hi @freddiek Have you made any recent changes and/or saves to the theme? Can you please verify the name of the site you are working on?

4,780 Views
Message 34 of 33
Report

Hello Bernadette

Thanks for getting in touch.

I last modified the css on 14 June and the theme was working fine then. The site is www.heliconmuse.com, Stories from Mount Helicon. Weebly must have the code stored somewhere because the styling is still shown when the website is published and I have been able to export the theme with the code up to date and still intact. There just doesn't seem to be anyway of accessing it via the code editor anymore.

I tried pasting it back into another theme's code, but css and .less don't seem to mix.

Fred

4,775 Views
Message 34 of 33
Report
Square

I think there's something with the custom theme which is interrupting requests to return the contents of main_style.css. You might want to try switching back to the standard version of the theme (or a different theme) and making your custom changes again.

4,768 Views
Message 34 of 33
Report

Thanks Adam Would I be able to cut and paste the code back in to the original Birdseye theme? I've seen that the styling is under a .less file, rather than css, although the code looks pretty much the same. Fred

4,760 Views
Message 34 of 33
Report
Square

That could possibly work if the code within each wasn't changed.

4,759 Views
Message 34 of 33
Report

We have the same problem.

I think the issue started since 2 new Weebly templates were introduced.

The problem is that whenever I try to edit any of the websites above, I get an empty screen and the default file called "main_style.css" is being shown as a folder instead.

I can't delete this file or upload any CSS from a backup.

Here is what I did to produce the issue:
1. Click on Edit HTML/CSS in the Weebly editor
2. This empty screen shows instead of the main style css

When we investigated further we saw a change in the older themes what could cause this issue:

the older main_style.css are now recreated as main.less

For that reason the themes that use the older main_style.css won't work.

Weebly says that it has something to do with the customazition of the theme. But one of the three folders:
Headers
Styles
Assets

is missing. And we are not able to create or delete those folders.

Almost 10 of our websites are affected with this problem. Please look in to this seriously and don't say it is somethning with our custom theme. A few days ago everything worked well so we think that Weebly updated something that could cause this problem.

Kind regards, Luuk

4,745 Views
Message 34 of 33
Report
Square

All of the sites using the same custom theme? Custom themes are global, so any site using a problematic theme will show the same problem. While newer themes use main.less, this wouldn't affect what you see in main-style.css on a theme that uses it (even older, non-custom themes). We've actually been using main.less with newer themes for quite a while now.

That said, I'm not sure why the code is missing from the theme editor. My guess is it's something preventing the theme editor from retrieving the code, since all of the css is present on the live site.

4,740 Views
Message 34 of 33
Report
Square

This error suggests something isn't working right and it's not able to get the CSS for the file:

If you haven't yet, I would let our CS team know so they can take it to our advanced support team. Generally speaking, we don't assist with custom themes that are not working right, though this may be a case of something else preventing you from editing.

4,740 Views
Message 34 of 33
Report

Hi Adam,

Thank you so much for looking into this. We tried to contact support yesterday by both chat and phone, but they refused to look into the issue citing only that they don't help if there is a custom theme,

Related to your question on your first reply:

No, they are using different older weebly themes. I'm not sure which site is using which original weebly theme, but they are all based on them. We haven't used a 3rd party theme,

Kind regards, Luuk

4,732 Views
Message 34 of 33
Report

I see i'm logged in with one of my other accounts. But i am the same person where you first replied to.

Kind regards, Luuk

1,568 Views
Message 34 of 33
Report
Square

No problem, Luuk. Smiley Happy 

I have some ideas you can test. 

1. Export your custom theme, then check the files on your computer to see if main-style.css includes the CSS code. 

2. If it does, rename the current main-style.css "folder" to something else and upload the main-style.css file to your theme.

3. If it does not, add /files/main_style.css to the URL of the live site, and it should show you all of the CSS in the file. Copy that to a file on your computer and name that file main-style.css, then repeat step 2 (I would still back up your theme before doing it just in case).

1,568 Views
Message 34 of 33
Report

"Thank you so much for the reply and the suggestions. It's a great idea!

We did test that, but the file in the backup theme.zip shows properly, as main_style.css and as an actual file.

Only on the Weebly editor it shows as an uneditable folder.

Unfortunately, we can't seem to upload the file, as it just reverts back to a folder as soon as you click on "Edit HTML/CSS"

Could I give you admin access to see how it looks on the actual website? It would help me a lot"

1,567 Views
Message 34 of 33
Report
Square

That is really weird. Hmm... I don't think it would do anything differently if I uploaded it. Is there something you want to change in main-style.css? You could add your own CSS somewhere else and override whatever it is in there. For example, upload a file called "overrides.css", then add a link to it in the footer of your page templates (where we link to some JS) so it's loaded after any other rules.

1,565 Views
Message 34 of 33
Report

I know what you mean. Yes, we'll keep that a as a last resort if we need to modify the CSS and the editor isn't fixed, as there would be many side-effects:

  • We'll need to have a reliable 3rd party host for the CSS, and it's also not a very good idea to load the main css styling separate from the website.
  • We'll also loose access to the preview function while making changes, which is one of the bigger benefits of Weebly.

I do appreciate all the effort that you've gone through and all the suggestions. Thank you very much for that!

Let's hope Weebly will fix the editor issue, so that we don't need to make such workarounds.

Update: monday 24th of june. I see more people are complaining:

 The codes of the Main.style.css file disappeared from the css / html edit 

1,564 Views
Message 34 of 33
Report
Square

I don't think you'll need to host the CSS file somewhere else as long as you can upload a different CSS file to the Assets folder. Have you tried doing that yet?

1,541 Views
Message 34 of 33
Report

yes, we did and while we can upload a css, we get this error message:
https://stackoverflow.com/questions/22631158/resource-interpreted-as-stylesheet-but-transferred-with...

So, basically, we can no longer add additional CSS styles in the /files/theme/ from the Weebly website.
And you are right, this was working before, but it's not anymore.

1,539 Views
Message 34 of 33
Report
Square

Ahh, ok. Hmm... well, it's not a very elegant solution, though you could also add the same CSS to each page template wrapped in style tags, e.g.

<style>

/* overrides here */

</style>

1,536 Views
Message 34 of 33
Report

Thank you, but that would be a nightmare to manage with a 2000+ line CSS and a couple of dozen header templates 😅

Could you please report this issue with the development team, if they can check if it's possible to be fixed?

I do appreciate all the workarounds and the support you've been offering (which was amazing BTW!). We do need to get a proper long-term solution for this issue.

1,534 Views
Message 34 of 33
Report
Square

One more thing to try, or maybe clarify. When you open the theme editor and click on main-style.css, can you let sit for a few minutes and let me know if the file contents load? I want to confirm whether it's a different issue that I saw or if it's the same thing.

1,521 Views
Message 34 of 33
Report

Of course. I just tested leaving it for few minutes, but it doesn't load. Please note that it shows it as a folder since the update.

image

1,640 Views
Message 34 of 33
Report
This thread has been archived and locked. Please start a new thread if you would like to continue the conversation.