I have using shared hosting Go-daddy server I'm unable to run this command line on server
Warning: system() [function.system]: Unable to fork [ls -lart]
give me idea to run the script.
Thanks in advance.
I have using shared hosting Go-daddy server I'm unable to run this command line on server
Warning: system() [function.system]: Unable to fork [ls -lart]
give me idea to run the script.
Thanks in advance.
shared hosting systems disable some commands for security reasons , you need to work around that , use native php for what you want to do, open the directory and read its content using php itself.
system
and exec
are usually completely disabled or partially limited.
if you are interested here is a simple code to get directory content :
if (is_dir($base) && is_readable($base)) {
if ($handle = opendir($base)) {
$base .= '/';
while (false !== ($entry = readdir($handle))) {
//$entry is a file or directory including `.` and `..`
}
closedir($handle);
}
}