Re: displaying image from blog

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

 



It doesn't appear that gd is installed by my host as that functionthrows undefined function errors and I don't see gd when I dophpinfo();
On 10/4/05, Michael Crute <mcrute@xxxxxxxxx> wrote:> On 10/4/05, blackwater dev <blackwaterdev@xxxxxxxxx> wrote:> > I am querying a MSSQL db where an jpg image is stored as a blog.> >> > I have this code:> >> > <html>> > <head>> > <meta http-equiv="Content-Type" content="image/jpg">> > </head>> > <body>> > <?> > //Do the query> > include_once("../includes.list.php");> >  $ms_sql= new ms_db();> >  $my_sql=new Database();> >  $query="select photo from cars where id=22";> >  $data=$ms_sql->query($query);> >   while($obj = $ms_sql->objects('',$data)){> >    echo $obj->photo;> >   }> > $data=$ms_sql->disconnect();> > ?>> > </body>> > </html>> >> > But when viewed I just get all the junk code:> >> > !1AQaq"2B'¡±Á #3RðbrÑ> > $4á%ñ&'()*56789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz‚ƒ„…†‡ˆ‰Š'""•–—˜™š¢£¤¥¦§¨(c)ª²³´µ¶·¸¹ºÂÃÄÅÆÇÈÉÊÒÓÔÕÖ×ØÙÚâãäåæçèéêòóôõö÷øù> >> > What is wrong?> >> > Thanks!> >>> Try passing the output from the BLOB into imagecreatefromstring (a GD> function) and going that way.>> http://us2.php.net/manual/en/function.imagecreatefromstring.php>> -Mike>> --> ________________________________> Michael E. Crute> Software Developer> SoftGroup Development Corporation>> Linux, because reboots are for installing hardware.> "In a world without walls and fences, who needs windows and gates?">

[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