got invalid password when trying to fix a bug content
| From: | Laurent Laville | Date: | Sat, 13 Mar 2004 10:46:06 +0000 |
| Subject: | got invalid password when trying to fix a bug content | ||
| Groups: | php.pear.dev | ||
| Request: | Send a blank email to pear-dev+get-26376@lists.php.net to get a copy of this message | ||
I've opened BUG#1002 http://pear.php.net/bugs/bug.php?id=1002 about
Image_Color
My new comment and contribution for leaders of the package is :
While trying to use allocateColor() method on my next release of
HTML_Progress, i solved the problem like that:
function allocateColor(&$img, $color)
{
$color = Image_Color::color2RGB($color);
return ImageColorAllocate($img, $color[0], $color[1], $color[2]);
}
function color2RGB($color)
{
$c = array();
if ($color{0} == '#') {
$c = Image_Color::hex2rgb($color);
} else {
$c = Image_Color::namedColor2RGB($color);
}
return $c;
}
Laurent Laville
-----------------------
PHP For Ever http://pear.php.net/user/farell