W
W
WordPress WooCommerce2015-08-18 00:53:32
MySQL
WordPress WooCommerce, 2015-08-18 00:53:32

How to make color tint via php?

The essence of the problem. I have a WordPress theme that has an option to "Select Primary Site Color". Let's say I chose blue.
Accordingly, all the main elements, be it the color of the main menu, the footer and the buttons, turn blue. That's all right.
But next I need to add tints for the button borders. So that they are slightly darker than the main color. I would like to do this automatically, without manual instructions. Is it possible to generate a darker color from the original using php?

Answer the question

In order to leave comments, you need to log in

4 answer(s)
P
Pavel, 2019-02-15
@mrusklon

go to .htaccess
put there AddDefaultCharset utf-8

D
Dmitry, 2019-02-16
@BackDoorMan

The script is written in uft8 encoding, and the data in the database is in cp1251. Or vice versa

B
brevis, 2015-08-18
@maxxannik

Lots of libraries. For example, https://github.com/mexitek/phpColors

A
Alexander Taratin, 2015-08-18
@Taraflex

Just like in any other language.
https://ru.wikipedia.org/wiki/HSL
Offtopic.
systemo.biz Your site?
Why are you so cool there, but ask such basic questions?
How do you achieve such results? I'm purely interested in myself (I can't find a job for 1.5 years).

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question