cvs: phpdoc-fr /reference/image/functions imagesetstyle.xml

From: Date: Fri, 20 Dec 2002 03:35:12 +0000
Subject: cvs: phpdoc-fr /reference/image/functions imagesetstyle.xml
Groups: php.doc.fr 
Request: Send a blank email to doc-fr+get-141@lists.php.net to get a copy of this message
dams Thu Dec 19 22:35:12 2002 EDT Modified files: /phpdoc-fr/reference/image/functions imagesetstyle.xml Log: fixing error in the example Index: phpdoc-fr/reference/image/functions/imagesetstyle.xml diff -u phpdoc-fr/reference/image/functions/imagesetstyle.xml:1.1 phpdoc-fr/reference/image/functions/imagesetstyle.xml:1.2 --- phpdoc-fr/reference/image/functions/imagesetstyle.xml:1.1 Tue Dec 17 21:43:44 2002 +++ phpdoc-fr/reference/image/functions/imagesetstyle.xml Thu Dec 19 22:35:12 2002 @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.1 $ --> +<!-- $Revision: 1.2 $ --> <!-- splitted from ./en/functions/image.xml, last change in rev 1.43 --> <refentry id="function.imagesetstyle"> <refnamediv> @@ -29,7 +29,7 @@ <programlisting role="php"> <![CDATA[ <?php -header ("Content-type: image/png"); +header ("Content-type: image/jpeg"); $im = imagecreate (100, 100); $w = imagecolorallocate ($im, 255, 255, 255); $red = imagecolorallocate ($im, 255, 0, 0); @@ -44,11 +44,12 @@ imagesetstyle ($im, $style); $brush = imagecreatefrompng ("http://www.libpng.org/pub/png/images/smile.happy.png"); -imagecolortransparent ($brush, $w); +$w2 = imagecolorallocate($brush,255,255,255); +imagecolortransparent ($brush, $w2); imagesetbrush ($im, $brush); imageline ($im, 100, 0, 0, 100, IMG_COLOR_STYLEDBRUSHED); -imagepng ($im); +imagejpeg ($im); imagedestroy ($im); ?> ]]>

« previous php.doc.fr (#141) next »