Home >Backend Development >PHP Tutorial >How to generate php background image

How to generate php background image

PHP中文网
PHP中文网Original
2016-07-25 08:53:432485browse

How to generate a php background image:

<?php
$image = imagecreatetruecolor($imgWidth, $imgHeight);
$white = imagecolorallocate($image, 255, 255, 255);
imagefill($image, 0, 0, $white);

The above is the sample code of how to generate a php background image. For more related content, please pay attention to the PHP Chinese website (www.php.cn)!



Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn