Jump to content

[SOLVED] Php Switch - Between 2 numbers?


wwfc_barmy_army

Recommended Posts

Hello.

 

I've got a variable called $score and this number can be anywhere between -20 and 20. And i'm trying to use a switch statement instead of a bit if statement, i need to do something like 'between -20 and -15 echo 'this' ' but i think i'm doing it wrong, how do you do 'between' values in a switch statement?

 

Any advice is appreciated.

 

Thanks! :)

 

Link to comment
https://forums.phpfreaks.com/topic/56944-solved-php-switch-between-2-numbers/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.