FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » switch with range of comparisons
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: switch with range of comparisons [message #184640 is a reply to message #184636] Tue, 14 January 2014 00:54 Go to previous messageGo to previous message
Peter H. Coffin is currently offline  Peter H. Coffin
Messages: 245
Registered: September 2010
Karma:
Senior Member
On Mon, 13 Jan 2014 18:35:07 -0500, richard wrote:
> switch ($value){
>
> case "A">="Z";
>
>
> }
>
> Would this be allowed?

Allowed? Yes. Does it solve your problem? Probably not. That case will
never be executed unless $value contains something that evaluates to
false. As "A">="Z" does.

> What I want to do is to have one case for all 26 letters of the
> alphabet without having to use ||.

Back further up. Most ways of answering that question are probably
useless. What problem are you trying to solve?

--
10. I will not interrogate my enemies in the inner sanctum -- a small
hotel well outside my borders will work just as well.
--Peter Anspach's list of things to do as an Evil Overlord
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: When a random file is not found then what?
Next Topic: [CM] Falkvinge: MtGox had custom SSHD written in PHP
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Mon Sep 30 06:10:24 GMT 2024

Total time taken to generate the page: 0.04583 seconds