Jump to content

Change Image Background


iPixel

Recommended Posts

This creates an image 1500x1500 pixels. But it creates it in black... how can i make it white.

And i have to use imagecreatetruecolor() not imagecreate().

 

<?php

$im = imagecreatetruecolor(1500,1500);


// Output the image to the browser
header('Content-type: image/jpg');

imagejpeg($im);
imagedestroy($im);
?>

 

Thanks!

Link to comment
https://forums.phpfreaks.com/topic/224220-change-image-background/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.