Site logo

Archived topic

Can't save linear-gradient in Simple CSS

6 replies · Started by Anonymous on June 15, 2016

Viewing posts 1–7 of 7

Hi Tom - I am trying to put a linear-gradient background in the menu - something like:

.inside-navigation {
background: linear-gradient(to bottom, #1e5799 25%, #2989d8);
}

Using Simple CSS, when I try to save the css, I get sent to an error page. If I remove the "25%" parameter, then it saves correctly. I tried putting this rule (with the "25%") directly into style.css, and it displays correctly.

Any idea why I can't save this in Simple CSS?

Thanks.

What's the error message?

It's most likely the sanitization that happens before the data is saved to the database - this is a good thing for security.

However, obviously in this case it's a little too aggressive as that's perfectly good CSS.

I'll look into it :)

Here is the error message:

I have trued several css plugins, and they all fail with the "25%" parameter. If I change it to "25px", then it saves correctly.

I contacted my host and this was their answer:

"The issue was caused by mod security web application firewall. I have now disabled a mod security rule for your domain. Please try now."

The css save is now working correctly.

Thanks for your help Tom.

Glad you got it sorted - thanks for sharing the solution :)

This archived topic is closed to new replies.