?

解决方案 »

  1.   

    设置header为图片,然后读取图片文件,直接echo到浏览器.
      

  2.   


    <?php
    Header("Content-type: image/gif");
    $im = imagecreate(400,30);
    $black = ImageColorAllocate($im, 0,0,0);
    $white = ImageColorAllocate($im, 255,255,255);
    imageline($im, 1, 1, 350, 25, $black);
    imagearc($im, 200, 15, 20, 20, 35, 190, $white);
    imagestring($im, 5, 4, 10, "Graph TEST!!", $white);
    ImageGif($im);
    ImageDestroy($im);
    ?>
      

  3.   


    //除了楼上的方法, 还可以这样, 看例子<?php//自己把图片url装载进$arrImage
    $arrImage[0] = '../image/1.gif';
    $arrImage[1] = '../image/2.gif';
    $arrImage[2] = '../image/3.gif';//输出图片
    $str = '';
    foreach($arrImage as $value){
       $str.= '<img src="'.$value.'" />';
    }
    echo $str;
    ?>
      

  4.   


    问题看错了!
    <? $file="xxx.jpg";
       $image=fread(fopen($file,r),filesize($file));
       header("content-type:image/JPEG",true);
       echo $image;
    ?>
      

  5.   

    ?如何读取一个图片 显示出来?
    不用那么复杂吧
    比如a.php自动生产一张图片
    <img src="http://xxxxx.xxx.com/xxx/a.php">
    比如读取已知路径图片
    <img src="http://xxxxx.xxx.com/xxx/a.jpg">