fambizzari ha scritto:
Ok... here we go... I got it to work with this...
$(table tbody)
.mouseover(function(e)
{
$(e.target).parents('tr').addClass('over');
})
.mouseout(function(e)
{
fambizzari ha scritto:
George, I have no idea what you are talking about!
Can you explain by means of code?
I posted an example in the first answer to your question :)
Didn't you read it?
Ciao
Renato
@Renato - Thanks for the example. But i didn't see it and i still
can't see it.
@Suni - I've never used bind (except in a copy/paster job). Can you
point me to a tutorial which explains it.
Thanks
Thanks Renato, i didn't realise you were talking about that.
On Nov 8, 8:58 pm, Renato Formato [EMAIL PROTECTED] wrote:
fambizzari ha scritto: @Renato - Thanks for the example. But i didn't see it
and i still
can't see it.
Try
Renato,
THat doesn't seem to work over here:
$(table tbody)
.mouseover(function(e)
{
if(e.target).is(tr) $(e.target).addClass(over);
})
.mouseout(function(e)
{
if(e.target).is(tr) $(e.target).removeClass(over);
I got it to work with this though:
$(table tbody)
.mouseover(function(e)
{
if((e.target)==tr) $(e.target).addClass(over);
})
.mouseout(function(e)
{
if((e.target)==tr) $(e.target).removeClass(over);
});
Is
Ok the code does not throw any errors, but it doesn't do what its
supposed to do.
Aren't we suppose to check what the parent of the target is? Because,
in effect, it is a table cell which is being hovered over and not the
row.
Any ideas?
Ok... here we go... I got it to work with this...
$(table tbody)
.mouseover(function(e)
{
$(e.target).parents('tr').addClass('over');
})
.mouseout(function(e)
{
$(e.target).parents('tr').removeClass('over');
One final thought, can you deligate mouseover and mouseout events to a
parent element such as the table, then inside your event handler
function, read the event.target to decide which row or cell or
whatever is being hovered-over?
George
On Nov 7, 5:38 am, fambizzari [EMAIL PROTECTED] wrote:
George, I have no idea what you are talking about!
Can you explain by means of code?
basically just bind the event handlers to the parent, such as the
tbody or table, check the event.target and act:
$('#myTable tbody').bind('click', function(e)
{
});
[EMAIL PROTECTED] ha scritto:
The following code works fine on small tables:
$(table tbody
tr).mouseover(function(){$(this).addClass(over);}).mouseout(function(){$(this).removeClass(over);});
But on tables with 5,000-10,000 rows, it throws the A script on this
page may be busy, or it
The solution i adopted was CSS (tr:hover) for non-IE6 and only allow
small tables to have hover-over using a class name to identify them.
Any better solutions?
On Nov 6, 10:45 am, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
The following code works fine on small tables:
$(table tbody
-Original Message-
From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of fambizzari
Sent: Tuesday, November 06, 2007 2:29 AM
To: jQuery (English)
Subject: [jQuery] Re: PROBLEM: Adding hover to table rows on large tables
The solution i adopted was CSS (tr:hover) for non-IE6
-Original Message-
From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Jeffrey Kretz
Sent: Tuesday, November 06, 2007 9:21 AM
To: jquery-en@googlegroups.com
Subject: [jQuery] Re: PROBLEM: Adding hover to table rows on large tables
Personally, I would recommend looking
Of Jeffrey Kretz
Sent: Tuesday, November 06, 2007 9:21 AM
To: jquery-en@googlegroups.com
Subject: [jQuery] Re: PROBLEM: Adding hover to table rows on large tables
Personally, I would recommend looking at a paging solution, rather than
trying to deal with so many rows on a single HTML page.
I
Why not try paging on scroll, similar to Google Reader? I think there
was a plugin for just that a while ago.
I'm just not a big fan of that technique from a usability standpoint.
Regular non-techie people are not used to unexpected things happening when
they scroll.
If someone wants to
to
paging.
-- Josh
- Original Message -
From: Karl Swedberg
To: jquery-en@googlegroups.com
Sent: Tuesday, November 06, 2007 1:55 PM
Subject: [jQuery] Re: PROBLEM: Adding hover to table rows on large tables
You could add onmouseover and onmouseout directly to the trs. It's
Kretz
Sent: Tuesday, November 06, 2007 9:21 AM
To: jquery-en@googlegroups.com
Subject: [jQuery] Re: PROBLEM: Adding hover to table rows on large
tables
Personally, I would recommend looking at a paging solution, rather
than
trying to deal with so many rows on a single HTML page.
I tested
In the end, we've gone for pagination on the most commonly used
application and a warning on the least used application recommending
users to keep their lists short.
20 matches
Mail list logo