English 中文(简体)
Coloring in php using HSL
原标题:Coloring in php using HSL

我想能够按顺序对一些信函(基地)进行总结。 我可以这样说,但我不能说肤色是什么。

我用内部风格做一些手套,但这似乎行不通。

case 1: /*500-550(Raw Score)*/
    $truecol=<div style="text-color: hsl($col,25%, 100%);">/*input*/</div>
    break;

case 2: //550-600
    $truecol=<div style="text-color: hsl($col,35%, 100%);">/*input*/</div>
    break;
case 3: //600-650
    $truecol=<div style="text-color: hsl($col,45%, 50%);">/*input*/</div>
    break;
case 4: //650-700
    $truecol=<div style="text-color: hsl($col,50%, 100%);">/*input*/</div>
    break;
case 5: //700-750
    $truecol=<div style="text-color: hsl($col,55%, 100%);">/*input*/</div>
    break;
case 6: //750-800
    $truecol=<div style="text-color: hsl($col,60%, 100%);">/*input*/</div>
    break;
case 6: //800-850
    $truecol=<div style="text-color: hsl($col,70%, 100%);">/*input*/</div>
    break;
case 7: //850-900
    $truecol=<div style="text-color: hsl($col,80%, 100%);">/*input*/</div>
    break;
case 8: //900-950
    $truecol=<div style="text-color: hsl($col,90%, 100%);">/*input*/</div>
    break;
case 9: //950-1000
    $truecol=<div style="text-color: hsl($col,100%, 100%);">/*input*/</div>
    break;

Do I have to convert rgb to hsl saturation, then back to hexadecimal? It is important that the colors go in a gradient. This is why I use HSL initially.

最佳回答

首先,只是看看贵国的购买力平价的颜色编码。 显然,你看不到这一点。

将这些超文本标签放在插图中。 最好有双引,只要你能正确摆脱风格。 例:

$truecol = "<div style="color: hsl($col,100%,50%);">...</div>";

通知一还更正了另外两个错误: 风格财产为color,而不是>>>> 密码-color,在hsl上,光度应为“正常”颜色的50%。 100%的人只是白人。

问题回答

暂无回答




相关问题
CSS working only in Firefox

I am trying to create a search text-field like on the Apple website. The HTML looks like this: <div class="frm-search"> <div> <input class="btn" type="image" src="http://www....

image changed but appears the same in browser

I m writing a php script to crop an image. The script overwrites the old image with the new one, but when I reload the page (which is supposed to pickup the new image) I still see the old one. ...

Firefox background image horizontal centering oddity

I am building some basic HTML code for a CMS. One of the page-related options in the CMS is "background image" and "stretch page width / height to background image width / height." so that with large ...

Separator line in ASP.NET

I d like to add a simple separator line in an aspx web form. Does anyone know how? It sounds easy enough, but still I can t manage to find how to do it.. 10x!

热门标签