How to split uploads up and concatenate them back together in PHP?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • bhavyamr
    New Member
    • Oct 2010
    • 1

    How to split uploads up and concatenate them back together in PHP?

    Hi,

    I am allowing users to upload video files in my website. If the user needs to upload 3MB video file he has to wait for long time. So i am searching for the solution . I have gone through this link still problem not resolved. Can you pl tell me how do i detect the video size before uploading and if it exceeds 500KB split and upload the chunks and recombine the parts before saving .

    NEED SOLUTION IN PHP

    Hi this is very urgent.. Help is appreciable.. Thanks in advance...
  • Sudaraka
    New Member
    • Jan 2011
    • 55

    #2
    Well unless you compress the data before you upload it's gonna take as long as it's gonna take to upload N number of bytes.
    This really depend on the speed of the connection between server and the client.

    However you can make the end-user experience a little better by displaying some sort of an indication that the upload is progressing, maybe displaying the progress.

    My favorite tool for this is (SWF Upload.
    Using SWF Upload, I have done a web page that upload multiple images (around 10Mb each) and everything works pretty smoothly.

    Comment

    • kovik
      Recognized Expert Top Contributor
      • Jun 2007
      • 1044

      #3
      Firstly, what you want to do is not possible. You can't control the upload or modify the files on the user's computer. You can only accept or deny the upload. And if 3MB is a slow upload, then you should consider upgrading your server's connection since videos can get much, much larger than that. The upload speed is related to the speed of the client's connection and the speed of the server's connection. Generally, you want the client's connection to be the bottleneck, not your server's.

      ~Sudaraka's suggestion of showing progress is a good one. This requires the use of 3rd party plugins such as Flash or Java (and possibly Silverlight, though I've yet to try it) serving as an active medium between the server and the client.

      Comment

      Working...