Readfile() + mpg = http status 500, windows server 2012, php 5.5.1

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

 



Good morning,
I run into same trouble.

Kind regards





hi oli,
i can confirm this if i use following command.
one download one 500

[download.cmd]
"C:\Program Files (x86)\GnuWin32\bin\wget.exe" --limit-rate=40000
http://127.0.0.1/index.php

did you find any solution?

regards


Hi List,
i installed a blank Windows Server 2012 Standard, added Role IIS & Feature
CGI
extracted 5.5.1 VC11 x86 Non Thread Safe to c:\Program Files (x86)\php
installed vcredist_x86.exe

added Handler Mappings in IIS
Request path: *.php
Module: FastCgiModule
Executable: c:\Program Files (x86)\php\php-cgi.exe
Name: PHP via FastCgi

Added 2 files to C:\inetpub\wwwroot index.php & movie.mpg (6MB)
Content of index.php

<?php
$track = "movie.mpg";
if (file_exists($track)) {
    header("Content-Type: audio/mpeg");
    header('Content-Length: ' . filesize($track));
    header('Content-Disposition: inline; filename="movie.mpg"');
    header('X-Pad: avoid browser bug');
    header('Cache-Control: no-cache');
    readfile($track);
    exit;
} else {
    header($_SERVER['SERVER_PROTOCOL'].' 404 Not Found', true, 404);
    echo "no file";
}

?>

Now every time the index.php is requested i get an error 500 in
Webserver log. But file will be delivered sucessfully.
Is there a problem with mpg files and readfile();
No difference with 5.4.17, 5.3.27 & Windows Server 2008 R2.
I know its very basic, but expected result should be: HTTP-Status: 200 or?
phpinfo() will be delivered succesful.

Thx + regards
oli

[Index of Archives]     [PHP Home]     [PHP Users]     [PHP Database Programming]     [PHP Install]     [Kernel Newbies]     [Yosemite Forum]     [PHP Books]

  Powered by Linux