Use PHP code to add watermarks to images,
First look for a picture, renamed to Face.jpeg, create watermark.php:
<?php/** * Created by Phpstorm. * User:administrator * DATE:2015/6/29 * time:22:27 * * $img = imagecreatefromjpeg (' face.jpeg ');//Create an image header from an existing JPG ( ' Content-type:image/jpeg ');//Set MIME type imagestring ($img, 5,5,5, ' vito-l ', Imagecolorallocate ($img, 255,0,0));// Generate Watermark, imagestring (picture, font, position x, position y, string, color) imagejpeg ($img);//output image//full image in the upper left corner is 0,0
The effect is as follows:
The above mentioned is the whole content of this article, I hope you can like.
http://www.bkjia.com/PHPjc/1024922.html www.bkjia.com true http://www.bkjia.com/PHPjc/1024922.html techarticle use PHP code to add watermark to the picture, first find a picture, renamed to Face.jpeg, create watermark.php:php/** * Created by Phpstorm. * User:administrator * date:2015/ 6/29 * Time: ...