PHP Developers Network

A community of PHP developers offering assistance, advice, discussion, and friendship.
 
Loading
It is currently Thu Jul 09, 2020 11:01 pm

All times are UTC - 5 hours




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: Help check PHP code
PostPosted: Sun Mar 06, 2005 2:22 pm 
Offline
Forum Newbie

Joined: Sun Mar 06, 2005 2:09 pm
Posts: 12


Top
 Profile  
 
 Post subject:
PostPosted: Sun Mar 06, 2005 8:18 pm 
Offline
DevNet Master

Joined: Tue Jan 20, 2004 12:11 am
Posts: 4897
Location: Leuven, Belgium
my comments:

- there is an access log thing... while your webserver has better facilities for this...

- asking for a password in a text input field is usually unwanted. make this a password input field

- with op=edit you simply output the contents of a textfile. minimal requirement is that you run htmlspecialchars on it... and probably also want to strip javascript etc... might want to lookup what file_get_contents and file functions can do for you.

- for the else part you probably want to lookup how empty/isset/array_key_exists (for testing $_GET['input']) and in_array (for testing the1Humanities.txt, 1Culture.txt etc)



conclusion: might want to check the php api/manual to discover some nice functions that allow you to do stuff more elegant. and have a look at for example to sanitize the input...


Top
 Profile  
 
 Post subject:
PostPosted: Tue Mar 08, 2005 6:13 pm 
Offline
Forum Newbie

Joined: Sun Mar 06, 2005 2:09 pm
Posts: 12


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC - 5 hours


Who is online

Users browsing this forum: No registered users and 5 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group