YoungNate_Black_coder Posted June 19, 2011 Share Posted June 19, 2011 how do you write this statement??? while($key > 0 and less than 2...????) Quote Link to comment https://forums.phpfreaks.com/topic/239768-php-loops-question/ Share on other sites More sharing options...
2-d Posted June 19, 2011 Share Posted June 19, 2011 <?php while($key > 0 && $key < 2){ //do stuff } The key youre missing is that && is how you do and in conditonals. You should read up some on while loops here: http://php.net/manual/en/control-structures.while.php Quote Link to comment https://forums.phpfreaks.com/topic/239768-php-loops-question/#findComment-1231675 Share on other sites More sharing options...
YoungNate_Black_coder Posted June 19, 2011 Author Share Posted June 19, 2011 thanks Rap ... Quote Link to comment https://forums.phpfreaks.com/topic/239768-php-loops-question/#findComment-1231677 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.