form for upload files - problems

partymaker

New Member
Messages
7
Reaction score
0
Points
0
I try create "form action" for uploading files, but it's not working.
Is it nessesery activate "register_globals" for PHP version 5.2.6
and where I can find that?
 

marshian

New Member
Messages
526
Reaction score
9
Points
0
This is a tutorial about php file uploading: http://www.tizag.com/phpT/fileupload.php
And register_globals is EVIL! Whoever invented it should :gtfo2: ...
When you have an url such as file.php?var=1 you can access the var by $_GET['var'] or $_request['var'], if register globals is on, $var would be the same! And what's even worse, it's a GLOBAL! In your whole file.php $var would have the same contents (1), this is extremely useful for a hacker, not to mention if you have an $var in the main loop and an $var in a function, they will have the same contents, which is probably not a good thing...

So just leave register globals off... (Yes, x10 has it turned off.)
 

DeadBattery

Community Support Team
Community Support
Messages
4,018
Reaction score
120
Points
0
To turn Register Globals off, create a new file called ".htaccess" (Make sure you can see hidden [dot] files)
Then add this line of code to it:
php_flag register_globals off

Then save it and now Register Globals is now off. :)
 
Top