BHB Posted March 18, 2012 Share Posted March 18, 2012 I have downloaded the scripts in case I typed something incorrect but I get this error for View Tasks: Undefined offset: 0 in C:\wamp\www\programming\tasks\TMP3q6kb137y5.php on line 74 Warning: Invalid argument supplied for foreach() in C:\wamp\www\programming\tasks\TMP3q6kb137y5.php on line 28 What the ??? This is chapter 1... copied script should work, no? When I go to add task I do not get any other option for parent, just '0' default. Must be a table error?? That was about as simple as it could be too. Link to comment Share on other sites More sharing options...
rob Posted March 18, 2012 Share Posted March 18, 2012 You need to put some entries in the database. Link to comment Share on other sites More sharing options...
BHB Posted March 18, 2012 Author Share Posted March 18, 2012 I have entries,.. Link to comment Share on other sites More sharing options...
rob Posted March 18, 2012 Share Posted March 18, 2012 So, what debugging steps have you taken? Undefined offset and Warning: Invalid argument supplied for foreach() are pretty standard errors for someone with php experience. Link to comment Share on other sites More sharing options...
Antonio Conte Posted March 19, 2012 Share Posted March 19, 2012 Your array is most likely empty. That is why you are getting the foreach error. As rob says, this is most likely because you fail to retrieve the rows from DB. Show us some code. Link to comment Share on other sites More sharing options...
Recommended Posts