background color imagefill


Posted on 16th Feb 2014 07:03 pm by admin

Hello

I would like to ask you why I see this square in red color just in my local xampp installation. If I run the code in the remote server (http://www.arreglaordenador.com/numberimage2.php) I see the square in black color instead of red. Do you have any ideas?

Code: (text)
<?php

$im = imagecreatetruecolor(100, 100);

// sets background to red
$red = imagecolorallocate($im, 255, 0, 0);
imagefill($im, 0, 0, $red);

header('Content-type: image/png');
imagepng($im);
imagedestroy($im);
?>
Thanks

No comments posted yet

Your Answer:

Login to answer
65 Like 36 Dislike
Previous forums Next forums
Other forums

preg_match logical error
Code: <?php
$s = file_get_contents("page.html");
preg_match('/<div cla

updating a single value to multiple non consecutive rows
I need to update the same value to multiple non consecutive rows. I need to add an experation date t

php or sql?
Sorry not sure if this is a sql problem or php the following code is supposed to delete data from th

Javascript or not?
How many people prefer javascript/ajax sites? How many prefer the good old fashion straight php sit

Undefined Index Notice In Internet Explorer Only
I am getting the following notice:

QuoteNotice: Undefined index: jrox in /home/ycsn/public_h

Performance impact of cookies
Hi, I was just wondering what impact there would be in terms of performance if you where to set then

temporary objects
Until now i thought every temporary object in C++ is created as constant. I'm wondering why my compi

Revoking alter any table from a schema
Hi All,

i am working in Oracle 10g.
my requirement is to revoke all kind of DDL oper

Casting Decimals in Oracle
This code worked as a query in DB2, but I am not sure what the syntax is for casting decimals in Ora

Good Programming and Web Design Books
Hi,

I recived a pm today from a fellow phpfreaker regarding php books, i replied with the fo

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash