This is a really strange problem - I have posted initial details here, but little has been suggested yet.
Why are my mp3 files being chopped in half on my server? It is working fine within apache, but within moodle/PHP it is not:
An example of a link that works fine:
However, when I upload the file into Moodle, it is not working:
- When I add it as a uploaded resource, the flash mp3player plugin stops after 1:23 secs (the actual size is 3:20 secs)
- When I link to it in the HTML editor, the small flash filter plugin again stops after 1:23 secs.
- When I click on a hyperlink within a html page within Moodle, it gives a network error: "The server redirected the player to an invalid location"
- When I right-click and download the file to my computer, and then play it, again it stops short. The size is 1.9 MB instead of 4.6 MB and it plays for only 1:23 secs again
It is clearly a problem with my server
I have looked in php.ini for every setting related to file sizes, and changed settings, to no avail. I have changed: max_execution_time = 300; max_input_time = 300; memory_limit = 32M; post_max_size = 24M; all to no avail.
Here are my PHP compile options:
'./configure' '--prefix=/usr/local/php5' '--with-apxs2=/usr/local/apache2/bin/apxs' '--with-ldap' '--disable-debug' '--enable-ftp' '--enable-magic-quotes' '--enable-mbstring' '--with-gd' '--with-gettext' '--with-mysql=/usr/local/mysql' '--with-zlib-dir=/usr/lib' '--with-freetype-dir=/usr/lib' '--with-jpeg-dir=/usr/lib' '--with-gif-dir=/usr' '--with-png-dir=/usr/lib' '--with-ttf=/usr/lib' '--enable-sockets'
I am tearing my hair out now - I have been trying to solve this problem for 4 days and have got nowhere. Googling has not turned up any help.
If anyone can help me I would appreciate it,