Author Topic: Case-sensitive string finding  (Read 593 times)

How does one do it?

$a = "potato";
$b = "Potato";

if($a $= $b)
    echo("Torque is case-insensitive");

$a = "potato";
$b = "Potato";

strStr($a,$b) == -1
strStr($a,$a) == 0


What's the difference between strCmp and striCmp?

What's the difference between strCmp and striCmp?

striCmp is case-insensitive.

What's the difference between strCmp and striCmp?
case-insensitive

http://www.garagegames.com/community/forums/viewthread/100195
A help thread about "case-sensitive printing" and I saw both functions used, so I wasn't sure.

http://www.garagegames.com/community/forums/viewthread/100195
A help thread about "case-sensitive printing" and I saw both functions used, so I wasn't sure.

When you see i stuck in a function or in a parameter, it generally refers to making it ignore case. Aside from the above and striPos, a commonly used function, it's generally seen in regular expressions. /^stuff here$/i, for example.