$( 'h3 > a,  > a', $(this) ).css('text-decoration', 'underline');

MaurĂ­cio
  -----Mensagem Original----- 
  De: Jacques Choquette - WhistlerGraphicDesign.com 
  Para: jQuery (English) 
  Enviada em: sexta-feira, 10 de julho de 2009 10:33
  Assunto: [jQuery] Is there a more efficent way to write this script?




  $(this).children("h3").children("a").css("text-decoration",
  "underline");$(this).children("a").css("text-decoration",
  "underline");

  I am changing the css text decoration on A tags within H3 elements and
  also on child A tags is there not a way to bundle these together? so I
  would only have to write out the .css("text-decoration", "underline");
  part once?

Reply via email to