How to use contains and equalsignorecase in string
<p>is there a way to check if a string contains something while not being case sensitive?</p>

<p>for example: (this code is invalid it's just for you to get a basic understanding of my question)</p>

<pre><code>String text = "I love ponies";

if(text.contains().equalsIgnoreCase("love") {
    // do something
}
</code></pre>

<p>EDIT:
-------- Still not working</p>

<p>ooh, turns out it's not working. here's what i'm using.
(it's a curse filter for a game)</p>

<pre><code>public void onChat(PlayerChatEvent event) {
    Player player = event.getPlayer(); 
    if (event.getMessage().contains("douche".toLowerCase()) || /* More words ... */) {
        event.setCancelled(true);
        player.sendMessage(ChatColor.GOLD + "[Midnight Blue] " + ChatColor.RED + "Please Don't Swear.");
    }
}
</code></pre>

<p>it works with lowercas but not upercase.</p>
