Why isn't my switch block (switching on $(e.target) .attr("class")) working?
<p>I am trying to figure out why this code doesn't work.. <br></p>

<p>All i want is to have simple event delegation to assign one event listener.</p>

<p>it only alerts, it doesn't animate.
Please let me know whats wrong here:</p>

<pre><code>$(document).ready(function() {
  var img = $("img");

$("span").click(function(e){
  var targetClicked = $(e.target).attr('class');
  //the alert works fine
  alert(targetClicked)

switch(targetClicked){
// i deleted the rest of the cases
    case d:img.stop(false,true);
  break;
    case e:img.slideDown().animate({"width":200, height:200, opacity:0.4,});
  break; 
  //nothings works here as well
    case f:alert("hi");
  break;
 }
 });      
});
</code></pre>
