Qasars Storage

Qasars Storage

Posted by: TJITBNE
Posted on: 2007-12-06 05:41:00

Hi,

I am trying to setup a PHP program that allows my users to upload to a folder, however, the setup script falls over at a line in the setup that reads:

reset ($HTTP_POST_VARS);

The error I get is:

Warning: reset() [function.reset]: Passed variable is not an array or object in /home/.yellow/tech/tf/tech/setup/actions/choose_install_type.php on line 20

Warning: Variable passed to each() is not an array or object in /home/.yellow/tech/tf/tech/setup/actions/choose_install_type.php on line 21

Warning: reset() [function.reset]: Passed variable is not an array or object in /home/.yellow/tech/tf/tech/setup/actions/choose_install_type.php on line 24

Warning: Variable passed to each() is not an array or object in /home/.yellow/tech/tf/tech/setup/actions/choose_install_type.php on line 25

The PHP project comes from http://projects.quasars.de/storage/

Can anyone tell me where it's going wrong, please.

Thanks in advance.



Regards,
Tony

I want to die in my sleep like my Grandfather. Not kicking and screaming like his passengers!

Re: Qasars Storage

Posted by: scjessey
Posted on: 2007-12-06 06:40:00

$HTTP_POST_VARS is deprecated in PHP4 and PHP5. DreamHost's PHP5 setup has the register_long_arrays directive disabled, so you must use the newer $_POST superglobal array variable instead.

-- si-blog --

Re: Qasars Storage

Posted by: TJITBNE
Posted on: 2007-12-06 20:11:00

Thanks scjessey. I'm not a PHP guru by any means. Is it just a matter of replacing all occurrences with 'post', or is there more to it?

The reason I am trying to get Qasar running is that I need an controlled username/password system to allow my users to upload, based on permissions i.e. Upload to only one common folder, limit number of files per day etc. Would you know of such a program that will run on DW?

Thanks again.


Regards,
Tony

I want to die in my sleep like my Grandfather. Not kicking and screaming like his passengers!Edited by TJITBNE on 12/06/07 08:12 PM (server time).

Re: Qasars Storage

Posted by: scjessey
Posted on: 2007-12-07 04:24:00

In reply to:

Is it just a matter of replacing all occurrences with 'post', or is there more to it?


In most cases, it should really be that simple. If you have anything else that uses $HTTP_*_VARS, particularly involving sessions, it will be a wee bit more difficult.

In reply to:

The reason I am trying to get Qasar running is that I need an controlled username/password system to allow my users to upload, based on permissions i.e. Upload to only one common folder, limit number of files per day etc. Would you know of such a program that will run on DW?


I am not aware of any such program, although one may certainly exist. I always hand-roll whatever I need, due to a personal dislike of third-party software in general.

-- si-blog --

Re: Qasars Storage

Posted by: wholly
Posted on: 2007-12-07 06:11:00

Luddite!

(Uploading big files through php is really a problem. You really may want to find a non-php solution if files are going to be over more than a couple meg.)


Wholly - Use promo code WhollyMindless for full 97$ credit until 12/11/07.

Tags: arrayphp programthanks in advancesleep