Community & Support

How to install Upload Progress bars to File Upload CCK

I'm planning on allowing people to upload pretty large files so I need to let them see the progress of their uploads:

http://drupalmodules.com/module/filefield

This says that filefield can do it with a PECL uploadprogress Extension: found here: http://pecl.php.net/package/uploadprogress

I've never worked with Pecl or anything like that? How do I get the upload progress working?

Comments

_

You don't provide any info about your environment, but the easiest way is to enable the apc option for php. Otherwise, see some of these posts: http://drupal.org/search/apachesolr_search/uploadprogress.

_
Don't be a Help Vampire - read and abide the forum guidelines.
If you find my assistance useful, please pay it forward to your fellow drupalers.

I'm using Bluehost virtual

I'm using Bluehost virtual hosting in a Linux environment.

Install uploadprogress on Bluehost

Here is how I got it to work. Replace the paths with those that will work for your environment.

Build the php extension:

1.  From ssh, mkdir ~/tmp/pecl

2.  cd ~/tmp/pecl

3.  wget http://pecl.php.net/get/uploadprogress-1.0.1.tgz

4.  tar zxvf uploadprogress-1.0.1.tgz

5.  cd uploadprogress-1.0.1

6.  phpize

7.  ./configure

8.  make

9.  cd modules

10. mkdir ~/php/ext

11. cp uploadprogress.so ~/php/ext

Install the php extension:

1.  From cPanel, click PHP Config in the Software / Services section

2.  Make sure PHP5 (Single php.ini) is selected and then click SAVE CHANGES

3.  Click INSTALL PHP.INI MASTER FILE

4.  From ssh, cd ~/php/ext

5.  Type pwd and note the full path (to be added in step 8 below)

6.  cd ~/public_html

7.  cp php.ini.default php.ini

8.  Edit php.ini and change the following line:

    extension_dir = "/usr/lib64/php/modules" (replace "/usr/lib64/php/modules" with the full path from step 5)

    Add the following line to the end of the extension section:

    extension = uploadprogress.so

9.  Add the file phpinfo.php to ~/public_html with the following contents:

    <?php phpinfo(); ?>

10. From your browser, point to http://[yourdomainhere]/phpinfo.php

11. Scroll down to make sure there is a section entitled uploadprogress

12. If you see this section, you were successful!

Hope this was helpful.

I am having this problem

I can't get upload progress to display on any filefield widget in bluehost

I followed your instructions exactly and each step was successful.
I can run phpinfo.php and SEE the extension is installed but it still doesn't work.
Bluehost told me that they will not run mod_php and to my understanding this module relies on that one to function correctly (or at all I'm assuming)

Any ideas?

nobody click here