Try this :

function inicializarEventos()
{
  var x;
  x=$("tr");
  x.click(presionFila);
}

function presionFila()
{
  var x;
  x=$(this);
  x.css("background-color","eeeeee");
}

var x;
x=$(document);
x.ready(inicializarEventos);

With Regards,
Chandan Luthra
Intelligrape Software Pvt. Ltd.
www.intelligrape.com


On Thu, Jan 15, 2009 at 2:28 PM, Mauricio (Maujor) Samy Silva <
css.mau...@gmail.com> wrote:

>  Hi Gustavo,
> Doesn't work because there is a missed  # in the color sintax
>
> pay attention here => x.css("background-color","#eeeeee");
> Maurcício
>
> -----Mensagem Original-----
> *De:* Lord Gustavo Miguel Angel <goosfanc...@gmail.com>
> *Para:* jQuery (English) <jquery-en@googlegroups.com>
> *Enviada em:* quarta-feira, 14 de janeiro de 2009 21:15
> *Assunto:* [jQuery] [ TR.click not work in Firefox]
>
> hi,
>
> Look this do not work in firefox, in IE yes. why?
>
> Thank´s
>
>
> ---------- index.html -------------
>
> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "
> http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd";>
> <html xmlns="http://www.w3.org/1999/xhtml";>
> <head>
> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
>
> <script language="javascript" type="text/javascript"
> src="jvs/jquery-1.2.6.js"> </script>
> <script language="javascript" type="text/javascript"
> src="jvs/funciones.js"></script>
>
> <title>Documento sin t&iacute;tulo</title>
>
> </head>
>
> <body>
>
>     <table width="200" border="1">
>       <tr>
>         <td>t1 c1</td>
>         <td>t1 c2</td>
>         <td>t1 c3</td>
>       </tr>
>       <tr>
>         <td>t2 c1</td>
>         <td>t2 c2</td>
>         <td>t2 c3</td>
>       </tr>
>       <tr>
>         <td>t3 c1</td>
>         <td>t3 c2</td>
>         <td>t3 c3</td>
>       </tr>
>     </table>
>
> </body>
>
> </html>
> ---------------- EOF ---------------
>
> -------------funciones.js---------------
> // JavaScript Document
> var x;
> x=$(document);
> x.ready(inicializarEventos);
>
> function inicializarEventos()
> {
>   var x;
>   x=$("tr");
>   x.click(presionFila);
> }
>
> function presionFila()
> {
>   var x;
>   x=$(this);
>   x.css("background-color","eeeeee");
> }
> --------------------- EOF ----------------
>
>

Reply via email to