RE: Including GD inside HTML code

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> Alberto García Gómez wrote:
> > I trying to include some image generate for a function that use GD.
> > 
> > eg.:
> > 
> > function myfunct(){
> >     [MY_CODE]
> > }
> > 
> > but when I call the function it generate me a lot of symbols, letters and numbers but no image.
> > 
> > WHAT CAN I DO?
> > 
> > PS.: I actually usgin a iframe to create the iomage in another .php page and place it using this tag.
> > 
> > Este correo ha sido enviado desde el Politécnico de Informática "Carlos Marx" de Matanzas.
> > "La gran batalla se librará en el campo de las ideas"
> > 
> 
> Sounds like you are trying to output the actual file content of the image in the HTML.
> 
> You should have a separate script generate the img and link to it with your HTML
> 
> <img src="generate_image.php?img=someImage" />
> 
> Then in the script generate_image.php you create the image and pass it back at that point.

Depending on what is in your myfunct(), you may also need to set a header to let the browser know what type of content you are outputting.

_________________________________________________________________
Boo! Scare away worms, viruses and so much more! Try Windows Live OneCare!
http://onecare.live.com/standard/en-us/purchase/trial.aspx?s_cid=wl_hotmailnews

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux