acid.waste Posted November 21, 2010 Share Posted November 21, 2010 $arr = array('../', 'j/', 'AcidBB/', 'fileBOMB/', 'OurHome', 'up'); foreach ($arr as $value) { // echo "Value: $value<br /><br />"; if (is_dir($value)) { echo "<tr> <td>{$value}</td> <td><font color='#66FF33'>Exists</font></td></tr><br />"; } else { echo "<tr> <td>{$value}</td> <td><font color='#FF0000'>Does Not Exist</font></td></tr><br />"; } } ~~~ Solved after posting. Sorry. ~~~ Ok i have an Array of directories i need to check before the script installs itself, I know how to check for directories but i dont know how to scan each array in the list without calling each one seperately in If() { } Else If { } Else If { } And so on and so on... My Question is, If a For Statement is neaded, How would i go about checking each string in the Array List? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.