Author Topic: Error uploading mp3 & videos  (Read 12693 times)

0 Members and 1 Guest are viewing this topic.

Offline Shap

  • Full Member
  • ***
  • Posts: 114
    • View Profile
Error uploading mp3 & videos
« on: November 25, 2002, 05:04:26 AM »
Im not having any luck when I try uploading videos or mp3's.

When I try uploading mp3's I get this error

Quote
Error uploading image file:
MF27.mp3: Invalid file type (mp3, audio/mp)




Also is there a differents between mpg and mpeg's? I'm trying to upload mpegs and its not working.

Another thing, I got AVI files to upload, but they will not display in the page, i got to download them to work, anyone know whats going on?


Thanks!

Offline Jan

  • Administrator
  • 4images Guru
  • *****
  • Posts: 5.024
    • View Profile
    • 4images - Image Gallery Management System
Error uploading mp3 & videos
« Reply #1 on: November 25, 2002, 07:27:31 AM »
The script checks the uploaded file mim type against the entry in "includes/upload_definitions.php". You can see the mime type in the error message:

MF27.mp3: Invalid file type (mp3, audio/mp)

Just add the mime type to the appropriate array in upload_definitions.php:

Code: [Select]
$mime_type_match['mp3'] = array("audio/mpeg", "audio/x-mpeg", "audio/mp3", "audio/mpg", "audio/mp");

If you add new file types you must ensure to add the extension to "Valid file extensions" in your settings. Note its a difference between mpg and mpeg.

Jan
Your first three "must do" before you ask a question:
1. Forum rules
2. FAQ
3. Search

Offline Shap

  • Full Member
  • ***
  • Posts: 114
    • View Profile
Error uploading mp3 & videos
« Reply #2 on: November 25, 2002, 07:34:27 AM »
so if I want mpg, and mpeg to display video, what would I do? If i put that code in the upload_definitions.php file should everything work out?

Offline Jan

  • Administrator
  • 4images Guru
  • *****
  • Posts: 5.024
    • View Profile
    • 4images - Image Gallery Management System
Error uploading mp3 & videos
« Reply #3 on: November 25, 2002, 07:40:06 AM »
Just try it ;)

Jan
Your first three "must do" before you ask a question:
1. Forum rules
2. FAQ
3. Search

Offline Shap

  • Full Member
  • ***
  • Posts: 114
    • View Profile
Error uploading mp3 & videos
« Reply #4 on: November 25, 2002, 07:53:45 PM »
I guess I'm just wondering

Code: [Select]
$mime_type_match['mp3'] = array("audio/mpeg", "audio/x-mpeg", "audio/mp3", "audio/mpg", "audio/mp");

does the audio/mpeg" tell it to play audio? If so what code would I use to have it play both audio and video, "audio/video/mpeg"?

Offline Shap

  • Full Member
  • ***
  • Posts: 114
    • View Profile
Error uploading mp3 & videos
« Reply #5 on: November 26, 2002, 07:02:44 AM »
Ok, i figured out what your talking about, but now my problem is, when I try uploading video's it acts like its uploading then says

Quote
Please recheck the marked fields.


and doesnt upload.

Anyone figured out what you need to do to make video's upload?

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Error uploading mp3 & videos
« Reply #6 on: November 26, 2002, 01:20:51 PM »
and what marked places it shows?
make sure that max upload size is correct in admin control panel settings.
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)

Offline Shap

  • Full Member
  • ***
  • Posts: 114
    • View Profile
Error uploading mp3 & videos
« Reply #7 on: November 26, 2002, 07:24:41 PM »
its showing the uploaded file, as the check marked place. I double checked image size its at 5000kb,  which is plenty

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Error uploading mp3 & videos
« Reply #8 on: November 26, 2002, 10:09:15 PM »
make sure that in php.ini max upload size is enough too.
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)

Offline Shap

  • Full Member
  • ***
  • Posts: 114
    • View Profile
Error uploading mp3 & videos
« Reply #9 on: November 26, 2002, 11:38:20 PM »
where would php.ini be found? i searched for it and cant find it

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Error uploading mp3 & videos
« Reply #10 on: November 29, 2002, 08:27:09 PM »
I dont know if u get the message I sent on ICQ, but here it is:
do u run 4images on your own web server or it's hosted somewere? if it's on your server, then check for php.ini file in c:/windows/ dir.
if its on somewhere host, then u can write little script that will show u php.ini settings:
<?php
phpinfo();
?>
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)