WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is there a function, either in PHP or Wordpress itself, or in a plugin, that will choose a good css background-color to go with a given background-image?

For example, if someone chose a very large dark-brown design for a background, it should have background-color of brown so before the image loaded, or if the image failed to load, it would still look ok.

share|improve this question
1  
Something like Color Thief (which appears to be JS-based)? – Pat J Aug 15 '14 at 14:33
    
@PatJ Yes, thanks, I hadn't seen that library. – NoBugs Aug 16 '14 at 1:45

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.