How to create a image.php (show ip +background) [Closed]

Posts
1
Registration date
Monday August 7, 2017
Last seen
August 7, 2017
-
i can't combine these codes i tested but not work

<?php
$img_number = imagecreate(275,225);
$backcolor = imagecolorallocate($img_number,102,102,153);
$textcolor = imagecolorallocate($img_number,205,205,205);

imagefill($img_number,0,0,$backcolor);
$number = " Your IP is $_SERVER[REMOTE_ADDR]";

Imagestring($img_number,10,5,5,$number,$textcolor);

header("Content-type: image/jpeg");
imagejpeg($img_number);
?>

+ background

<?php
$im = imagecreatefrompng("imagetest.png");

header('Content-Type: image/png');

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

in a file (image.php) /please help me /thanks
See more 

2 replies

Posts
1
Registration date
Friday March 2, 2018
Last seen
March 2, 2018
0
Thank you
You can't evaluate PHP in a CSS file. The only way to do this with PHP is to set the CSS value as an inline CSS value.
Respond to JohnyArts
Posts
10940
Registration date
Monday June 3, 2013
Status
Moderator
Last seen
December 14, 2018
0
Thank you
What error are you getting?
Respond to ac3mark