For Programmers: Free Programming Magazines  


Home > Archive > PHP SQL > January 2005 > is this code correct?









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author is this code correct?
raizan

2005-01-26, 2:50 am

i've been wondering if there is something with this below line of code, because it never works. I've tried asking a few other people, they says it because shell_exec is disabled in safe_mode. Though there are serveral other shell_exec command lines in the script and they work just fine. Everything just stuck when it gets to this line though

PHP:

$data 
shell_exec("mysql -uhello -hlocalhost -phaha $username < dbase.sql");



The idea of this line is to insert the mysql data from the dbase.sql file into the $username database whichever it might be, through the big boss user (hello).

Is there any problems with this line of code? If shell_exec for this is REALLY disabled, are there any alternative codes that would do the same stuff?.
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com