elementor error notice Post CSS File

Error: Elementor\Post_CSS_File is deprecated

There’s nothing worse than loading a website and finding an error, except finding that error at the top of the page!  It’s the first thing that users see and what an impact, especially as a WordPress web developer, an error at the top of the screen can make.  You’ve essentially LOST any potential sale from the visitor that came to the site!

The only thing worse than getting an error on the website is when you search forums and Google for an answer, and you find hundreds of people with the same error (or websites showing the same error) and nobody providing a real answer!

Fear not, I have a solution for you.

The Error I Got With Elementor

Notice: Elementor\Post_CSS_File is deprecated since version 2.1.0! Use Elementor\Core\Files\CSS\Post instead. in /public/wp-includes/functions.php on line 4016

The error notice from Elementor is quite ugly, isn’t it?  And, in many ways, it’s really not that helpful or informative.

Sure, we can see that they want us to use a different system than how it was previously used, but there’s not much more available.  Searching the community at Elementor has proved fruitless, so I then went searching Sourceforge to see what others may have come up with, and also the WordPress Plugin and Support section.

From what I could find, there was staff from Elementor advising users to enable “Safe Mode” and to ignore the error.

Ignore the error?  If I’m to ignore it, why bother having it display in the first place?  That seems like a ridiculous answer to a problem and really poor advice!

How Did The Error Notice in Elementor Start?

There’s any number of ways that you can trigger this error, but at the end of the day, essentially, it’s triggered by updating the Elementor plugin and code in the plugin not being compatible with the latest version.

For me, the error started after updating my Elementor Plugins:

Elementor 2.3.5 was upgraded to Elementor 2.4.1
Elementor Pro 2.2.5 was upgraded to Elementor Pro 2.3.1

The moment I updated the two Elementor plugins, I started to get the following error:

Notice: Elementor\Post_CSS_File is deprecated since version 2.1.0! Use Elementor\Core\Files\CSS\Post instead. in /public/wp-includes/functions.php on line 4016

As you can see, both plugins that I updated were a major branch version update, and as with any update, the best advice is to use a testing environment before going live.  Thankfully, our processes and procedures are in place so we didn’t display the error, but others are often not so lucky.

Sometimes, webmasters can spend days tracking down the issue. And worse, sometimes the update of the plugins were performed by a client or end-user and the webmaster doesn’t even know that an error was generated.

Enable Safe Mode, Disable the WordPress Debug

From the various places I found online, everyone suggested just to enable the Safe Mode and the error goes away. Essentially, it suppresses the notice so you don’t see it. It doesn’t mean that there’s still not an issue, it just means that you’re not going to see the warning.

While this might work as a temporary fix, it doesn’t actually resolve the issue, it just masks it.

You can enable Safe Mode in Elementor by going to Elementor > Tools

Enabling the Safe Mode in Elementor didn’t help in my case, and from what I can read, it didn’t help with many other people either.

How did I finally fix the Error / Notice in Elementor?

No matter what I did, the notice continued to show:

Notice: Elementor\Post_CSS_File is deprecated since version 2.1.0! Use Elementor\Core\Files\CSS\Post instead. in /public/wp-includes/functions.php on line 4016

But hey, I finally found exactly what was causing the problem for me, and the issue was my theme – OceanWP.

I love the OceanWP Theme and I probably have it installed on a dozen or more sites that we’ve developed.  It gives so much flexibility, but in this particular case, the notice and error being presented by Elementor were because of OceanWP and their code.

They updated their theme, but I never updated it on the site – after all, the general rule of thumb is if it’s not broke, don’t fix it. The only exception to that rule is if there’s a security update, then YES, you should definitely update!

Once I updated OceanWP to version 1.6.1, the error went away. There is something in their code which was using the old format that Elementor used to have, and since Elementor changed their path, OceanWP needed to change theirs too.

Did you Resolve Your Elementor Notice Too?

Shame on me for not updating the theme sooner! There’s really no reason not to have updated it other than there was nothing broken on the website, so why bother?  Well, like other plugins update, the theme will now be something I need to monitor too.

Did you experience any issues with the Elementor Notice regarding the POST CSS FILE change in Elementor?  Did you resolve it with the Theme also, or was there another method you used?

If you’re having problems with your WordPress website, or need some assistance with editing things, drop us a call or send us a message and we’d love to take a peek behind the curtains and see what’s going on.

Share this post

Share on facebook
Share on google
Share on twitter
Share on linkedin
Share on pinterest
Share on print
Share on email
Check Out These Other Articles
Bright Idea Website Design for Web Designers

Business Website Design: Is It Time for An Update?

The right website design can help ensure that a business has a highly effective online presence. On the other hand, the wrong design can hold a business back. Since the design a business chooses is very important, implementing an initial design or opting to do a redesign aren’t decisions that should be taken lightly. They also shouldn’t be done based on reasons that aren’t directly linked to the goals of a business.

Responsive Web Design

The Best Type of Web Design in 2017 and Beyond

If a new business is looking to have a website built or an established business decides to update their website to mobile responsive, they may be overwhelmed by the number of different options that are available today. While the market is filled with different website styles and options, there’s one type of design that stands out above the rest.

The Blog to End All Blogs: Part 3, The Long Game

It’s been shown that readers of blogs make quick decisions about what to read based on the title and first few lines—with hundreds of new articles being posted every day, readers pretty much have to make those kinds of decisions just to keep their heads above water. If you want to get their attention, you have to spend time thinking

Close Menu