Skip to main content
added 131 characters in body
Source Link
Neil
  • 55.5k
  • 8
  • 65
  • 74

I think you want to use && in your condition instead of ||.

The way you've written it it will keep going if either condition is true, so it will only stop if they are both false.

EDIT: after reading your question more closely, I think you need to use

while (0 == $date1 && $this->counter < 5 ) { 

I think you want to use && in your condition instead of ||.

The way you've written it it will keep going if either condition is true, so it will only stop if they are both false.

I think you want to use && in your condition instead of ||.

The way you've written it it will keep going if either condition is true, so it will only stop if they are both false.

EDIT: after reading your question more closely, I think you need to use

while (0 == $date1 && $this->counter < 5 ) { 
Source Link
Neil
  • 55.5k
  • 8
  • 65
  • 74

I think you want to use && in your condition instead of ||.

The way you've written it it will keep going if either condition is true, so it will only stop if they are both false.