[jQuery] Re: click action effect/problem

2010-01-20 Thread Scott Sauyet
I'd like to thank you guys again for the quick response, but for some reason, both methods aren't working. I made two suggestions. MorningZ's suggestion was very much like my first one. My second one is a bit more general, and might help. I modified MorningZ's page here:

[jQuery] Re: click action effect/problem

2010-01-18 Thread MorningZ
Hope this helps put you on the path http://jsbin.com/ejuga3 (run) http://jsbin.com/ejuga3/edit (edit) Event Delegation = awesome knowledge to have http://www.learningjquery.com/2008/03/working-with-events-part-1 On Jan 18, 4:07 pm, Legostrat legost...@gmail.com wrote: Hey, I've got a

[jQuery] Re: click action effect/problem

2010-01-18 Thread Scott Sauyet
On Jan 18, 4:07 pm, Legostrat legost...@gmail.com wrote: div id=button    Click here       div id=submenu        option 1        option 2       /div /div So, when you click on the button div, it reveals the sub-menu div. The problem is that when you click on the content within the

[jQuery] Re: click action effect/problem

2010-01-18 Thread Legostrat
Thanks guys!

[jQuery] Re: click action effect/problem

2010-01-18 Thread Legostrat
I'd like to thank you guys again for the quick response, but for some reason, both methods aren't working. With the first method, when you click on the containing div, in this case #twitter, it reveals the div with the content, #flwtwitter. However, when you click on it a second time it tries

[jQuery] Re: click event is not working

2010-01-08 Thread CreativeMind
thanx a lot! On Jan 8, 3:07 am, Charlie Griefer charlie.grie...@gmail.com wrote: http://docs.jquery.com/Events/live On Thu, Jan 7, 2010 at 2:01 PM, CreativeMind aftab.pu...@gmail.com wrote: hi, i'm appending a child div in a parent div. parent div has already child div's which have

[jQuery] Re: click(function{ problem with Firefox

2009-12-24 Thread Šime Vidas
Yea, that happens if you don't follow the standard some browser will break your code :) For a comprehensive overview of propper HTML nesting rules, consult my diagram: http://vidasp.net/HTMLstructure.htm

[jQuery] Re: click(function{ problem with Firefox

2009-12-24 Thread turnavies
Thanks for your replies! FF is happy now, although it's not fully standards-compliant (I still have an img inside my label), but the code is a lot cleaner and it works on the major browsers (haven't tested IE though :D) Nice diagram! Thomas

[jQuery] Re: click(function{ problem with Firefox

2009-12-24 Thread turnavies
ah look at that, img is an inline element :D standards ftw! On 24 dec, 23:10, turnavies thomas.vanoeke...@gmail.com wrote: Thanks for your replies! FF is happy now, although it's not fully standards-compliant (I still have an img inside my label), but the code is a lot cleaner and it works on

[jQuery] Re: Click Even

2009-12-03 Thread shapper
On Dec 3, 2:52 am, JMcGinnis justin.mcgin...@gmail.com wrote: y0, Not really, why do you need to/ or want to? you could do this $('#Play').click(function() { $.cookies.set('WCA.Player', 'Play', { path: '/' }) }) ha, j/k same thing, just one line.  Could you just explain why you would like

[jQuery] Re: Click event outside of an element

2009-12-03 Thread Keysher
Umm, It seems fine, I'll check it later. Thanks! On 23 nov, 15:13, Dustan dustan.kas...@gmail.com wrote: Perhaps something along these lines is what you are looking for? $(document).click(function(event) {     if (!$(event.target).hasClass('classname')) {         // run this code if

[jQuery] Re: Click event outside of an element

2009-11-23 Thread Dustan
Perhaps something along these lines is what you are looking for? $(document).click(function(event) { if (!$(event.target).hasClass('classname')) { // run this code if anywhere in the document except the item is clicked } }); On Nov 20, 8:29 am, Keysher keys...@gmail.com wrote:

[jQuery] Re: Click event outside of an element

2009-11-22 Thread Keysher
Works fine! Thanks!! :o) On 21 nov, 15:29, mofle mofl...@gmail.com wrote: Here you go: $(document).click(function(){         alert('clicked outside classname'); }); $('.classname').click(function(e){         e.stopPropagation(); }); First you bind a click event to the document with

[jQuery] Re: Click event outside of an element

2009-11-21 Thread mofle
Here you go: $(document).click(function(){ alert('clicked outside classname'); }); $('.classname').click(function(e){ e.stopPropagation(); }); First you bind a click event to the document with the action you want. Then you bind the classname to stop it from propagate up to the

[jQuery] Re: Click not running on IE

2009-10-30 Thread James
What value is in r? Does it have something like a # or . that makes it a valid selector? For example, in your code below: var blocco = r + div.pul; $(blocco).each(function (i) blocco may become 'testdiv.pul' $(blocco), will become $('testdiv.pul'), which does nothing because there's no element

[jQuery] Re: Click multiple times, different states, saves different data to DB (confusing?)

2009-10-22 Thread mkmanning
Well, if you just want to loop through the array to change the background color, you don't really need toggle then. Try this: $(#item_list li div a).click(function(){ var arrValues = ['rgb(9, 128, 0)','rgb(0, 255, 255)','rgb(0, 0, 255)','rgb(128, 0, 128)'], bgcolor =

[jQuery] Re: Click multiple times, different states, saves different data to DB (confusing?)

2009-10-22 Thread The Danny Bos
For each click of the DIV I'm hoping to change the BackgroundColor, make some updates in the Database (depending on which array selection it's on) and that's about it. So, the first click of the DIV = Change BG to 'green', update DB field to 'XXX' the second click of the DIV = Change the BG to

[jQuery] Re: Click multiple times, different states, saves different data to DB (confusing?)

2009-10-22 Thread mkmanning
Yeah, the snippet I wrote updates the color; you can add an ajax call to update your db as well, if the value your updating in the db is the color, or else the value is in an array that's indexed the same. On Oct 22, 12:10 am, The Danny Bos danny...@gmail.com wrote: For each click of the DIV

[jQuery] Re: Click multiple times, different states, saves different data to DB (confusing?)

2009-10-22 Thread The Danny Bos
Thanks so much man, That'll work well ... One more thing, how would I change it to point to classes instead of direct colours? var arrValues = ['c1','c2','c3','c3'], Thanks again, On Oct 22, 6:27 pm, mkmanning michaell...@gmail.com wrote: Yeah, the snippet I wrote updates the color; you

[jQuery] Re: Click multiple times, different states, saves different data to DB (confusing?)

2009-10-22 Thread mkmanning
Something like this (untested): var arrValues = ['c1','c2','c3','c3'], cnameIndex = $.inArray(this.className,arrValues)+1; this.className = cnameIndex===arrValues.length?0: cnameIndex ]; if you can live with only one classname, otherwise you'll have to add code to remove the old classname from

[jQuery] Re: Click multiple times, different states, saves different data to DB (confusing?)

2009-10-22 Thread The Danny Bos
Thanks man, I'll give it a whirl ... Thanks for all your time and energy. d On Oct 23, 4:19 am, mkmanning michaell...@gmail.com wrote: Something like this (untested): var arrValues = ['c1','c2','c3','c3'], cnameIndex = $.inArray(this.className,arrValues)+1; this.className =

[jQuery] Re: Click multiple times, different states, saves different data to DB (confusing?)

2009-10-21 Thread mkmanning
.toggle() allows you to rotate through multiple functions, you might want to check it out in the docs: http://docs.jquery.com/Events/toggle#fnfn2fn3.2Cfn4.2C... On Oct 21, 2:58 am, The Danny Bos danny...@gmail.com wrote: I've got one for ya, JQuery and Ajax. I want to have a button image,

[jQuery] Re: Click multiple times, different states, saves different data to DB (confusing?)

2009-10-21 Thread The Danny Bos
Thanks, had a good read, figured it out in part. Now I'm stuck trying to introduce an array to do my bidding ... Example below. The array is an example of how I want to loop through to use those values. Underneath is the perfect code for clicking an Anchor and changing its BGcolour differently

[jQuery] Re: click function populating value in a hidden field

2009-10-01 Thread James
Suppose your rows looked like this: tr id=row_1tdtext/td/tr tr id=row_2tdtext/td/tr tr id=row_3tdtext/td/tr $(tr).click(function () { $(.clicked).removeClass(clicked); $(this).addClass(clicked); var row_id = this.id.split('_')[1]; // e.g. 2 $(#hiddenField).val(row_id); //

[jQuery] Re: click function populating value in a hidden field

2009-10-01 Thread Chuk
Works like a charm! Thanks so much! :)

[jQuery] Re: click function populating value in a hidden field

2009-10-01 Thread Chuk
Works like a charm! Thanks so much! :)

[jQuery] Re: click function populating value in a hidden field

2009-10-01 Thread Chuk
Works like a charm! Thanks so much! :)

[jQuery] Re: .click() fires my callback more than once

2009-09-25 Thread allenm541
I've run into this problem many times as well. The issue is that your click function is being bound more than once. To fix it, use the .unbind() method. .unbind() without any parameters will unbind everything bound to that element, including your .click() function. However, if you wish to

[jQuery] Re: .click() fires my callback more than once

2009-09-24 Thread Liam Potter
probably because you have click handlers inside the confirmAction function, which is run on click itself. Fabdrol wrote: Hi guys, I'm facing this little problem, I've got a button toolbar, and users can select rows in a table. When they have selected some row's, they can click one of the

[jQuery] Re: click a button returned by ajax

2009-09-09 Thread Carlos Santos
function live was what I needed. But now another question. it's possible to make a POSTwith AJAX, via a button also created with AJAX, and store the return in a CONTAINER that does not exist in the DOM, but must exist when the POST is done? I.E. /*Action on a button that still exist in the

[jQuery] Re: click a button returned by ajax

2009-09-08 Thread MorningZ
There's no reason why this shouldn't work... remember you cannot wire an event to something that isn't on the DOM unless you: (1) use the .live() functionality of jQuery (http://docs.jquery.com/ Events/live#typefn) or (2) do it after it is in the DOM, which my code shows below $.post(

[jQuery] Re: click a button returned by ajax

2009-09-08 Thread rupak mandal
Hi carlos try to use http://docs.jquery.com/Events/live thanks Rupak On Tue, Sep 8, 2009 at 8:54 PM, Carlos Santos carloeasan...@gmail.comwrote: I have a button that do appear on my page through a post with jquery: $.post( 'more_item.php',{

[jQuery] Re: Click event not working?

2009-08-27 Thread Cesar Sanz
mmm.. try this.. Put a border to your div, let's say border: 10px, then click the border to see what happen.. - Original Message - From: Kris S krissauqui...@gmail.com To: jQuery (English) jquery-en@googlegroups.com Sent: Wednesday, August 26, 2009 7:04 PM Subject: [jQuery] Click

[jQuery] Re: Click event not working?

2009-08-27 Thread James
Could you show us what your animate_next() function looks like? On Aug 26, 3:04 pm, Kris S krissauqui...@gmail.com wrote: I'm trying to execute a function animate_next() when a div element is clicked, but it isn't working. Here is what it looks like..

[jQuery] Re: Click Binding not Working

2009-08-26 Thread Richard D. Worth
You need to use the ID selector (#): $('#btnInput').click(showVal); $('#btnInput').bind('click', showVal); - Richard On Wed, Aug 26, 2009 at 2:18 AM, S2 smnthsm...@gmail.com wrote: I have this code that works: var btnInput= document.getElementById('btnInput');

[jQuery] Re: click-event-handler for dynamically created a-elements?

2009-08-20 Thread ak732
You might also want to check go to http://api.jquery.com and check out the live method under Events--Live Events. On Aug 20, 9:43 am, ak732 ask...@gmail.com wrote: There are a lot of ways to do this, here are a couple: $(#div99).append(a id='alnDiv99' href='#'I am in div99/a).click

[jQuery] Re: click-event-handler for dynamically created a-elements?

2009-08-20 Thread ak732
There are a lot of ways to do this, here are a couple: $(#div99).append(a id='alnDiv99' href='#'I am in div99/a).click (function(){alert(hello world);}); $(a/).attr({id:alnDiv99, href:#}).text(I am in div99).click (function(){alert(hello world);}).appendTo(#div99); On Aug 20, 6:42 am, Audrey

[jQuery] Re: Click() Not Working

2009-08-14 Thread S2
!DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01//EN http://www.w3.org/ TR/html4/strict.dtd html head meta http-equiv=Content-Type content= text/html; charset=iso-8859-1 title/title script type=text/javascript src=jquery.js /script script type=text/javascript $(function(){

[jQuery] Re: Click() Not Working

2009-08-14 Thread Richard D. Worth
It doesn't work to call .click() on an A, if you want to navigate a link's href. Instead: window.location = $(td a.menu:contains('Main')).attr('href'); - Richard On Fri, Aug 14, 2009 at 7:32 PM, S2 smnthsm...@gmail.com wrote: !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01//EN http://www.w3.org/

[jQuery] Re: Click() Not Working

2009-08-14 Thread James
Just to clarify that further, click() on a a doesn't perform a mouse click on a link and follow through. It calls the onclick event attached to the a elements, which you don't have set, so it does nothing. On Aug 14, 4:08 pm, Richard D. Worth rdwo...@gmail.com wrote: It doesn't work to call

[jQuery] Re: Click() Not Working

2009-08-13 Thread Jules
$(td a.menu:contains('Main')).click() should work. Can you post the html? On Aug 14, 4:48 am, S2 smnthsm...@gmail.com wrote: This doesn't work in IE or Firefox: $(td a.menu:contains('Main')).click(); This works in IE: $(td a.menu:contains('Main'))[0].click(); $(td

[jQuery] Re: Click event to load a new page

2009-08-06 Thread James
Do you mean that when someone clicks on an image, it just goes to a different page? (Similar to a normal a tag around an image.) If so: $(#i4).click(function() { document.location.href = 'index.php? whichPage=sliderwhichAct=0subPage=mixnmingle'; }); Or did you mean load an external page

[jQuery] Re: Click event to load a new page

2009-08-06 Thread Richard D. Worth
Use window.location = index.php?whichPage=sliderwhichAct=0subPage=mixnmingle; - Richard On Thu, Aug 6, 2009 at 2:35 PM, paul.mac paul.mcma...@uuconstruct.co.ukwrote: I want to add a click function to an image to laod a new page Tried this but it doesn't work $(#i4).click(function(){

[jQuery] Re: Click event to load a new page

2009-08-06 Thread paul.mac
Thanks guys - came to the same conclusion shortly after posting the question. Thanks Paul On Aug 6, 7:52 pm, Richard D. Worth rdwo...@gmail.com wrote: Use window.location = index.php?whichPage=sliderwhichAct=0subPage=mixnmingle; - Richard On Thu, Aug 6, 2009 at 2:35 PM, paul.mac

[jQuery] Re: Click event to load a new page

2009-08-06 Thread Simon
This is something that was bothering me too, and I came to the same conclusion. How is this for SEO though? Redirecting with Javascript that is? Does it recognize the link? Cheers, Simon On Aug 6, 3:52 pm, paul.mac paul.mcma...@uuconstruct.co.uk wrote: Thanks guys - came to the same conclusion

[jQuery] Re: click treeview and then jqgrid refresh?

2009-07-20 Thread Orcun Avsar
You can use: $(#grid_id).trigger(reloadGrid); it reloads grid with grid params that may be changed by browser user ( sorting name, page number), so if you want a full refresh or need changed options on grid , you may need to use something like this:

[jQuery] Re: .click doesn't seem to respond to elements added with jQuery

2009-07-16 Thread borgsquad
try to use the .live method with the click listener blcArmadillo wrote: I'm working on creating a little suggestion/autocomplete code for form fields. Here is the code I currently have written: $(document).ready(function() { $(#city).keyup(function() {

[jQuery] Re: Click events handling conflict due to prototype?

2009-06-22 Thread Steve the Canuck
Btw... I do have a workaround - register my click event on something outside the table, such as the body tag, and then check the original event target. I'd prefer to target just the list item and anchor though if possible. On Jun 22, 11:14 am, Steve the Canuck steve.san...@gmail.com wrote: Hi,

[jQuery] Re: Click events handling conflict due to prototype?

2009-06-22 Thread Cesar Sanz
Use jQuery and not $ - Original Message - From: Steve the Canuck steve.san...@gmail.com To: jQuery (English) jquery-en@googlegroups.com Sent: Monday, June 22, 2009 10:34 AM Subject: [jQuery] Re: Click events handling conflict due to prototype? Btw... I do have a workaround - register

[jQuery] Re: Click events handling conflict due to prototype?

2009-06-22 Thread Steve the Canuck
(); } }); On Jun 22, 3:17 pm, Cesar Sanz the.email.tr...@gmail.com wrote: Use jQuery and not $ - Original Message - From: Steve the Canuck steve.san...@gmail.com To: jQuery (English) jquery-en@googlegroups.com Sent: Monday, June 22, 2009 10:34 AM Subject: [jQuery] Re: Click events handling

[jQuery] Re: Click events handling conflict due to prototype?

2009-06-22 Thread Charlie
ish)" jquery-en@googlegroups.com Sent: Monday, June 22, 2009 10:34 AM Subject: [jQuery] Re: Click events handling conflict due to prototype? Btw... I do have a workaround - register my click event on something outside the table, such as the body tag, and then check the original event target.

[jQuery] Re: Click events handling conflict due to prototype?

2009-06-22 Thread Steve the Canuck
...@gmail.comwrote:Use jQuery and not $ - Original Message - From: Steve the Canucksteve.san...@gmail.comTo: jQuery (English)jquery-en@googlegroups.comSent: Monday, June 22, 2009 10:34 AM Subject: [jQuery] Re: Click events handling conflict due to prototype? Btw... I do have

[jQuery] Re: click function on anchor element

2009-06-11 Thread Pierre Bellan
Hi, I think that is because of the alert function. It needs a string and maybe for an anchor object, jquery introduces a toString method. With the console of firebug, there are no differences between anchor and images Pierre 2009/6/11 bensan...@gmail.com bensan...@gmail.com Hi all, I'm

[jQuery] Re: click function on anchor element

2009-06-11 Thread Chandan Luthra
Hi Bensanlau, try $('a').click(function(){ alert(*$(this)*); return false; }); Chandan Luthra Intelligrape Software Pvt. Ltd. Josh Billingshttp://www.brainyquote.com/quotes/authors/j/josh_billings.html - Every man has his follies - and often they are the most interesting thing he has got. On

[jQuery] Re: click function on anchor element

2009-06-11 Thread Ricardo
Just clearing up what Pierre said: if the argument you passed to alert () is not a string, it's .toString() method will be called. For convenience, the toString on an anchor HTMLElement object returns it's href. Try this: $('a').get(0).toString(); or $('a').click(function(){ alert(

[jQuery] Re: click function on anchor element

2009-06-11 Thread Kean
Interesting! That's also the same with labeling object properties. The label will be casted into their string representation. a href=hi.html id=yaasdf/a $('#ya').click(function(){ a = {}; a[this] = 1; cache = this; }); alert(a[cache.toString()]); // alerts 1 On Jun 11, 12:16 pm,

[jQuery] Re: Click event on dynamically-generated link

2009-06-04 Thread waseem sabjee
$(.mylinkclass).live(click, function() { alert(it Worked); }): if that fails try holding this script in one of the xml nodes script $(function() { $(.mylinkclass).live(click, function() { alert(it Worked); }): }); /script On Thu, Jun 4, 2009 at 4:46 PM, fredriley fred.ri...@gmail.com wrote:

[jQuery] Re: Click event on dynamically-generated link

2009-06-04 Thread MorningZ
I'd suggest to understand why your dynamic objects are wired up, thoroughly read this article http://www.learningjquery.com/2008/03/working-with-events-part-1 understanding why is the solution of fixing your issue as for as even to do the simplest thing you need to fully internalise the whole

[jQuery] Re: Click event on dynamically-generated link

2009-06-04 Thread fredriley
On Jun 4, 3:50 pm, waseem sabjee waseemsab...@gmail.com wrote: $(.mylinkclass).live(click, function() { alert(it Worked); }): Thanks very much for the swift and helpful reply. I'd not come across 'live' before, but looking at the docs http://docs.jquery.com/Events/live it's plainly what I

[jQuery] Re: Click event on dynamically-generated link

2009-06-04 Thread fredriley
Thanks to you as well for the swift reply. On Jun 4, 4:04 pm, MorningZ morni...@gmail.com wrote: I'd suggest to understand why your dynamic objects are wired up, thoroughly read this article http://www.learningjquery.com/2008/03/working-with-events-part-1 Thanks, I'll read it carefully.

[jQuery] Re: Click Tracking - Works In IE Only

2009-05-29 Thread waseem sabjee
try using bind() instead of live() On Fri, May 29, 2009 at 11:23 PM, Up-Works mich...@up-works.com wrote: Need to know why this code below records the click in IE but does not record the click in FF or Safari. a.adBanner is an internal link within the same domain. Thank you in advance.

[jQuery] Re: Click Tracking - Works In IE Only

2009-05-29 Thread James
What is not working? Clicking the link does nothing? Does 'providerid' not have a value? Is the AJAX not being sent? No AJAX response? On May 29, 11:23 am, Up-Works mich...@up-works.com wrote: Need to know why this code below records the click in IE but does not record the click in FF or

[jQuery] Re: Click Tracking - Works In IE Only

2009-05-29 Thread James
Try putting a return false; at the end of your click code so that it doesn't go to the next page. See if the AJAX call works. (Theoretically, it probably still should not if it didn't before.) I'm not sure what you're saying about the console displaying the text in red. Does it also contain any

[jQuery] Re: Click Tracking - Works In IE Only

2009-05-29 Thread Up-Works
On May 29, 2:36 pm, James james.gp@gmail.com wrote: What is not working? Clicking the link does nothing? Does 'providerid' not have a value? Is the AJAX not being sent? No AJAX response? In FF and Safari it does not fetch the $.get before loading the new page location, thus the

[jQuery] Re: Click Tracking - Works In IE Only

2009-05-29 Thread James
That's strange. Maybe it's a race condition issue which may vary depending on your computer. I've tried this before for logging click- throughs and it worked fine. What if you try to use $.ajax instead, and set the option 'async' to 'false', so that it waits for the AJAX response before the

[jQuery] Re: Click Tracking - Works In IE Only

2009-05-29 Thread Up-Works
Thank you James - I will try thisWhat if you try to use $.ajax instead, and set the option 'async' to 'false', so that it waits for the AJAX response before the click- through occurs?

[jQuery] Re: Click event not fired when hide() called by blur()

2009-05-25 Thread Ricardo
Set a flag on mousedown on the DIV to prevent blur (mousedown fires first): $().ready(function(){ var divclick = false; $('#aa') .focus(function() { $('#bb').show(); }) .blur(function() { if ( divclick ) return( divclick = false ); $('#bb').hide(); }); $('#bb')

[jQuery] Re: Click event not fired when hide() called by blur()

2009-05-25 Thread cohq82
This works. Thanks On May 24, 11:29 pm, Ricardo ricardob...@gmail.com wrote: Set a flag on mousedown on the DIV to prevent blur (mousedown fires first): $().ready(function(){  var divclick = false;  $('#aa')   .focus(function() {     $('#bb').show();   })   .blur(function() {    

[jQuery] Re: .click function won't work twice? addClass and hasClass little problem

2009-05-19 Thread James
I think you want this: if($(#content).hasClass(blue)) { $(#content).removeClass(blue); $(#content).addClass(red); } if($(#content).hasClass(red)) {

[jQuery] Re: Click-Event in Options/defaults

2009-05-15 Thread Geuintoo
Keep in mind this recursively calls attr( key, value ) or attr ( key, fn ), so if one of the properties you are passing is a function, the function will be evaluated and not stored as the attribute itself. Question: The function should NOT will be evaluated... Any idea? Thanks!

[jQuery] Re: Click-Event in Options/defaults

2009-05-15 Thread Geuintoo
This works, but is there no better way? $.each(opts.button, function(i, n){ var func = n.click; delete(n.click); var button = $('img /') .attr(n) .click(func); $(#rtfButtons).append(button); });

[jQuery] Re: click() only binds to first match

2009-04-01 Thread MorningZ
Well, IDs are supposed to be *unique* on the page, which you do not have your selector would be better off like $(span.box).click() On Apr 1, 5:16 am, thalis tkalf...@gmail.com wrote: Hi all, I have 3 images. I want one of them to be displayed, and when user clicks either on  

[jQuery] Re: click(function() works only once per page load?

2009-03-29 Thread Mr. Zeph
Thanks On Sun, Mar 29, 2009 at 1:25 AM, Ricardo ricardob...@gmail.com wrote: That's as simple as changing $(.ajax_homes_primary_img).click (function(){ to $(.ajax_homes_primary_img).live('click', function() Thanks, tried it, and even used livequery (amazing how fast this stuff is to pick

[jQuery] Re: click(function() works only once per page load?

2009-03-28 Thread Ricardo
Your click handler only applies to the elements matching .ajax_homes_primary_img at the time the click() function is called. When you replace it, the new element has no event listeners attached. You can either rebind the event every time you modify it, or use the 'live' function, which uses event

[jQuery] Re: Click event is not captured by jQuery after the link to click is rendered by AJAX through jQuery

2009-03-23 Thread Eric Garside
It's because jQuery operates on the elements which already exist. Lets say for instance: a href=load.html class=ajax-clickery/a div id=ajax-content/div Loads this page into div#ajax-content: a href=load-another.html class=ajax-clickery-two/a When you first render the page, you're grabbing

[jQuery] Re: Click event is not captured by jQuery after the link to click is rendered by AJAX through jQuery

2009-03-23 Thread tadatoshi
Thank you, Eric. It worked very well. In my previous example, I modified the code like this following your advice: jQuery(document).ready( function($) { jQuery( .class-name-for-element-for-ajax ).click( function() { ... jQuery.get( jQuery(this).attr(href), { some_variable:

[jQuery] Re: click here to earn money through online

2009-03-16 Thread Happy Hyderabad
http://www.happyhyderabad.com/entertainment.php?disp=gallery

[jQuery] Re: Click function dosen't work, after append new html data.

2009-03-11 Thread errant
That's because events are binded to existing elements. If you're using 1.3.x, take a look at live method: http://docs.jquery.com/Events/live#typefn. With previous versions, livequery plugin may be helpful: http://docs.jquery.com/Plugins/livequery On 11 мар, 09:25, sure sure.2...@gmail.com

[jQuery] Re: Click function dosen't work, after append new html data.

2009-03-11 Thread sure
Hi errant, Thank you very much for quick reply. Now it works good using live method. Your solution saves my lot of time. with Regards sure. On Mar 11, 1:32 pm, errant d.cheka...@gmail.com wrote: That's because events are binded to existing elements. If you're using 1.3.x, take a

[jQuery] Re: click event and window.location problem in safari

2009-02-27 Thread brian
I don't know what the problem is or how to fix it but I'm wondering why you need this onclick event at all. If you want the link to fill the entire div you might be able to just give the anchor display: block. On Fri, Feb 27, 2009 at 9:49 AM, introvert aljaz.faj...@gmail.com wrote: Hello I

[jQuery] Re: click event and window.location problem in safari

2009-02-27 Thread Karl Rudd
Try this plugin: http://newism.com.au/blog/post/58/bigtarget-js-increasing-the-size-of-clickable-targets/ Karl Rudd On Sat, Feb 28, 2009 at 1:49 AM, introvert aljaz.faj...@gmail.com wrote: Hello I have a simple jquery code that will put a link (on click event) on a division. The link is

[jQuery] Re: .click to start dropdown, hover out to clear (mixing the two)

2009-02-18 Thread Karl Swedberg
Hi Pete, You don't need to use .hover() with an empty function. You can use .mouseleave() in jQuery 1.3.x or .bind('mouseleave') in 1.2.6. --Karl Karl Swedberg www.englishrules.com www.learningjquery.com On Feb 18, 2009, at 12:28 AM, pedalpete wrote: Ok, actually got

[jQuery] Re: .click to start dropdown, hover out to clear (mixing the two)

2009-02-17 Thread James
The syntax for hover() is hover(function, function), where the first function is what happens when something is onmouseover and the second is onmouseout. $(elem).hover( function() { // do something on mouseover }, function() { // do something on mouseout }

[jQuery] Re: .click to start dropdown, hover out to clear (mixing the two)

2009-02-17 Thread pedalpete
right, so does that mean their is no way to specify only the hover out in jquery? On Feb 17, 6:21 pm, James james.gp@gmail.com wrote: The syntax for hover() is hover(function, function), where the first function is what happens when something is onmouseover and the second is onmouseout.

[jQuery] Re: .click to start dropdown, hover out to clear (mixing the two)

2009-02-17 Thread pedalpete
Ok, actually got this working with the following code [code] $('form#filterList span.holdDate').click(function(){ $('span#datePickers, div.datepicker').slideDown('fast'); $('span#datePickers, div.datepicker').hover(

[jQuery] Re: click events on links

2009-02-14 Thread pedalpete
i've done this before just leaving out the href in the a tag. if you aren't going to use it, you may as well not put it in. On Feb 14, 5:48 pm, introvert aljaz.faj...@gmail.com wrote: Hello. I have a simple anchor href link on which I put on click event handler: a href=# id=pause/a

[jQuery] Re: click events on links

2009-02-14 Thread Rick Faircloth
:39 PM To: jQuery (English) Subject: [jQuery] Re: click events on links i've done this before just leaving out the href in the a tag. if you aren't going to use it, you may as well not put it in. On Feb 14, 5:48 pm, introvert aljaz.faj...@gmail.com wrote: Hello. I have a simple

[jQuery] Re: CLick event for Select Box not supported by IE

2009-02-05 Thread James
I see. Yeah, select elements doesn't work like that. Though I found that click can work that way if you give the select element with a size attribute: select class=actions size=4 So if you re-click a selected element, it'll fire. Does this option fit with your design? On Feb 4, 6:01 pm, Pedram

[jQuery] Re: click/change events not recognized for checkboxes

2009-02-05 Thread James
Try: $(#mfglist input:checkbox) or maybe: $(#mfglist :checkbox) (note the space before :) might work. Using: $('#manufacturers:checkbox') is saying that you have a checkbox with the ID of manufacturers, which is incorrect. On Feb 5, 11:09 am, sdeo deo.shant...@gmail.com wrote: Hi   I have

[jQuery] Re: click event

2009-02-04 Thread jQuery Lover
You can take advantage of event delegation by binding click event to the table tag and checking with if statement if the clicked cell is not the one that has a checkbox. For event delegation see: http://www.learningjquery.com/2008/03/working-with-events-part-1 For row checking and stuff see:

[jQuery] Re: Click Links in the Nnavigation Bar

2009-02-04 Thread Karl Swedberg
On Feb 4, 2009, at 1:09 AM, Pedram wrote: Thanks Karl , It helped me alot Not a problem. Glad to help. Since it's not possible in a valid DOM to have an A that is a descendant of a UL but not a descendant of an LI, the LI is superfluous. No need to do an extra getElementsByTagName there.

[jQuery] Re: CLick event for Select Box not supported by IE

2009-02-04 Thread James
Change should work. $(select.actions).change(function(){ if ( $(this).val() == 'NEW' ) alert('NEW was selected'); else alert('NEW was not selected'); }); On Feb 4, 6:56 am, Pedram pedram...@gmail.com wrote: Dear folk ,  I have a select box with Multiple Options Such as below

[jQuery] Re: CLick event for Select Box not supported by IE

2009-02-04 Thread Pedram
Ow Great so $(this).val() returns the Option value , is this acceptable by IE because , I think I had a Problem with that before . On Feb 4, 10:52 am, James james.gp@gmail.com wrote: Change should work. $(select.actions).change(function(){      if ( $(this).val() == 'NEW' ) alert('NEW

[jQuery] Re: CLick event for Select Box not supported by IE

2009-02-04 Thread James
I've never had any issues with it on any common browsers, including IE6. On Feb 4, 4:05 pm, Pedram pedram...@gmail.com wrote: Ow Great so $(this).val() returns the Option value , is this acceptable by IE because , I think I had a Problem with that before . On Feb 4, 10:52 am, James

[jQuery] Re: CLick event for Select Box not supported by IE

2009-02-04 Thread Pedram
Thanks , great , But consider the I want the user to Click in a Option which is selected right now and An event Fire Ups so Click dosen't work for IE and CHange doen't support it On Feb 4, 10:52 am, James james.gp@gmail.com wrote: Change should work. $(select.actions).change(function(){

[jQuery] Re: Click Links in the Nnavigation Bar

2009-02-03 Thread Pedram
Thanks Karl , It helped me alot On Feb 1, 9:47 am, Karl Swedberg k...@englishrules.com wrote: On Feb 1, 2009, at 3:06 AM, Pedram wrote: I have another  tiny question  $(Ul li a), $(ul a), $(a,$(ul)) which one has the great performance !!? I would go with either $('ul a') or $('a',

[jQuery] Re: click Event not working on first binded element on IE after one click

2009-02-02 Thread shahku...@gmail.com
Using that doesn't work either. The first word, stops registering the click event after one click. The only way I found to resolve the issue is, add the following code to the page: span class=hint style=display:noneHidden/span In this case, Hidden becomes the first word, so the rest of the page

[jQuery] Re: Click Links in the Nnavigation Bar

2009-02-01 Thread Pedram
Thanks Karl , You are Right , I appreciate it , thank you again . You are always the solver On Jan 31, 11:54 am, Karl Swedberg k...@englishrules.com wrote: Hi Pedram, I agree with Nic. Especially if you're only dealing with 4 elements,   binding directly on them seems like the most sensible

[jQuery] Re: Click Links in the Nnavigation Bar

2009-02-01 Thread Pedram
I just had some Doubt , the performance is great On Jan 31, 11:54 am, Karl Swedberg k...@englishrules.com wrote: Hi Pedram, I agree with Nic. Especially if you're only dealing with 4 elements,   binding directly on them seems like the most sensible solution. Are you noticing performance

[jQuery] Re: Click Links in the Nnavigation Bar

2009-02-01 Thread Pedram
I have another tiny question $(Ul li a), $(ul a), $(a,$(ul)) which one has the great performance !!? On Feb 1, 12:02 am, Pedram pedram...@gmail.com wrote: I just had some Doubt , the performance is great On Jan 31, 11:54 am, Karl Swedberg k...@englishrules.com wrote: Hi Pedram, I

  1   2   3   >