how to change the while loop condition depending on stuff?
        Posted  
        
            by linkcool
        on Stack Overflow
        
        See other posts from Stack Overflow
        
            or by linkcool
        
        
        
        Published on 2010-04-25T21:51:03Z
        Indexed on 
            2010/04/25
            22:03 UTC
        
        
        Read the original article
        Hit count: 271
        
by this question what i mean is that if, by example, someone's username is "bob" then the while loop condition will be ($i < 10), and if the username is something else then the while loop condition will be ($i > 10)
if($username == "bob")
{
   //make this while loop condition: ($i < 10)
   // it means: while($i <10){ so stuff}
}
else
{
   //make the while loop condition: ($i >10)
}
© Stack Overflow or respective owner