Nelson’s 記事簿











{一月 11, 2006}   FlysprayMe attachment問題解決了

花了一天,終於將這個Bug給解決了:

    if (file_exists($basedir."attachments/$file_name")) { //mod by nelson liu 2006/1/11
 
      $path = $basedir."attachments/$file_name"; //mod by nelson liu 2006/1/11
 
      header("Pragma: public");
      header("Content-type: $file_type");
      header("Content-Disposition: filename=$orig_name");
      header("Content-transfer-encoding: binary\n");
      header("Content-length: " . filesize($path) . "\n");
 
      readfile("$path");
   exit; //added by nelson liu 2006/1/11



發表迴響

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / 變更 )

Twitter picture

You are commenting using your Twitter account. Log Out / 變更 )

Facebook照片

You are commenting using your Facebook account. Log Out / 變更 )

連結到 %s

及其他等等
Follow

Get every new post delivered to your Inbox.