久久久久久久视色,久久电影免费精品,中文亚洲欧美乱码在线观看,在线免费播放AV片

<center id="vfaef"><input id="vfaef"><table id="vfaef"></table></input></center>

    <p id="vfaef"><kbd id="vfaef"></kbd></p>

    
    
    <pre id="vfaef"><u id="vfaef"></u></pre>

      <thead id="vfaef"><input id="vfaef"></input></thead>

    1. 站長(zhǎng)資訊網(wǎng)
      最全最豐富的資訊網(wǎng)站

      php文件下載后不能打開(kāi)怎么辦

      php文件下載后不能打開(kāi)的解決辦法:首先打開(kāi)文件下載代碼;然后在該文件中添加“ob_clean();flush();”語(yǔ)句即可。

      php文件下載后不能打開(kāi)怎么辦

      本文操作環(huán)境:windows7系統(tǒng)、PHP7.1版,DELL G3電腦

      php文件下載后不能打開(kāi)怎么辦?

      PHP下載圖片后文件打開(kāi)顯示損壞問(wèn)題解決方法

      用php寫(xiě)個(gè)圖片下載方法,測(cè)試發(fā)現(xiàn)下載的圖片大小都沒(méi)問(wèn)題,但是無(wú)法打開(kāi)文件。

      解決方法如下:

      增加

      ob_clean();   flush();

      這2句話。

      完整下載圖片代碼:

      PHP

      if(isset($_GET['action'])&&$_GET['action'] == 'download') { if($_GET['file']) { $fileinfo = pathinfo($_GET['file']); header('Content-type: application/x-'.$fileinfo['extension']); header('Content-Disposition: attachment; filename=favicon.ico'); ob_clean();       flush();   readfile($_GET['file']); exit(); } }

      推薦學(xué)習(xí):《PHP視頻教程》

      贊(0)
      分享到: 更多 (0)
      網(wǎng)站地圖   滬ICP備18035694號(hào)-2    滬公網(wǎng)安備31011702889846號(hào)