[jQuery] Frustrating Scope Question with getJSON

2009-09-19 Thread dysfunct
There's some sort of scope issue here that I cant seem to get passed. I'd ideally just like the function to return the shortUrl from the json results but can't seem to get it anywhere but the callback function. function shortenURL(url){ var apiKey = 'APIKEY'; var apiLogin =

[jQuery] [autocomplete] Does it support version 1.3.2?

2009-09-19 Thread Catherine
Same as subject I'm having trouble using it with jQuery 1.3.2. Please advice.

[jQuery] Validation, ignore specific words

2009-09-19 Thread jbotos
Hi, I have values in each input which tells the user what to enter in that field. Each value clears on click and resets to default if no value is entered. How can I have it treat my values as if it would be empty (no value entered)?

[jQuery] Re: Validation, ignore specific words

2009-09-19 Thread Jörn Zaefferer
You can avoid that issue by using a solution that doesn't modify the inputs value. The (planned) jQuery UI watermark widget does that, you can get the code from labs here: http://jquery-ui.googlecode.com/svn/branches/labs/watermark/ui/ui.watermark.js A sort-of demo is here:

[jQuery] Re: Using append() - each element or string of HTML?

2009-09-19 Thread Karl Swedberg
One interesting side note is that, according to John Resig's presentation on recent changes to jQuery internals (at last weekend's jQuery conference): for (var i=0; i 250; i++) { $('lisome thing/li').attr('id', 'foo' + i).appendTo('ul'); } ... is now faster than this: for (var i=0; i

[jQuery] Re: Frustrating Scope Question with getJSON

2009-09-19 Thread Dave Methvin
I'd ideally just like the function to return the shortUrl from the json results but can't seem to get it anywhere but the callback function. ...          $.getJSON(http://api.bit.ly/shorten?version=2.0.1longUrl=; + url + login= + apiLogin + apiKey= + apiKey, function(data){                

[jQuery] Re: Clear selection of text on ul element

2009-09-19 Thread Dave Methvin
I am trying to get/set only text  of list only element text value. But for some reason I can not select it in clear way. ul li id=myid  Here text that I want to modify ul li id=dfdfi don't want modify this/li li id=dfdfi don't want modify this/li /ul /li ul You didn't show your code,

[jQuery] Re: [autocomplete] Does it support version 1.3.2?

2009-09-19 Thread alexbodn . groups
sure :) On Sat, Sep 19, 2009 at 04:31, Catherine catherinek@gmail.com wrote: Same as subject I'm having trouble using it with jQuery 1.3.2. Please advice. -- alex smime.p7s Description: S/MIME Cryptographic Signature

[jQuery] Re: Deterministic or Non-Deterministic Event Handler execution?

2009-09-19 Thread alexbodn . groups
event driven programs can't usually rely on the order they might run. but in the case they both handle the same event or predictable event sequence, you may have handler for one event [conditionally] trigger the other event or even invoke it's handler directly. just my thought :) . On Sat,

[jQuery] [ why don´t working attr ]

2009-09-19 Thread Lord Gustavo Miguel Angel
Hi, I have this code jQuery: $('div.contenedor a').each(function(index){ $(this).attr({ 'rel': 'external', 'id': index }); }); -- This´s my html -- div id=contenedor h1UNA TERTULIA INESPERADA/h1

[jQuery] Re: [ why don´t working attr ]

2009-09-19 Thread adambundy
Your syntax is incorrect. What you want, I think, is: $(this).attr({ 'rel','external', 'id',index }); (commas in place of the colons) -Adam On Sep 19, 8:20 am, Lord Gustavo Miguel Angel goosfanc...@gmail.com wrote: Hi, I have this code jQuery:  $('div.contenedor

[jQuery] data function

2009-09-19 Thread cafaro
Hi, I'm trying to get the data() function working, but no success so far. Here's the code I've come up with: //$(a[href*='user.php?nick=']).data(test, true); $(a[href*='user.php?nick=']).mouseover(function() { $(this).data(test, true); });

[jQuery] Re: Does it support version 1.3.2?

2009-09-19 Thread Mike Alsup
On Sep 18, 9:31 pm, Catherine catherinek@gmail.com wrote: Same as subject I'm having trouble using it with jQuery 1.3.2. Please advice. What trouble are you having? You need to provide some details.

[jQuery] Re: Frustrating Scope Question with getJSON

2009-09-19 Thread Bill H
I've tried that and still can't seem to get the data into any sort of usable scope.

[jQuery] Re: [ why don´t working attr ]

2009-09-19 Thread Mike McNally
On Sat, Sep 19, 2009 at 10:03 AM, adambundy adambu...@gmail.com wrote: Your syntax is incorrect. What you want, I think, is: $(this).attr({   'rel','external',   'id',index  }); (commas in place of the colons) No, that's not correct. The syntax is fine in the original. I think the

[jQuery] Re: [ why don´t working attr ]

2009-09-19 Thread MorningZ
It's colons straight from the docs http://docs.jquery.com/Attributes/attr#properties On Sep 19, 12:44 pm, Mike McNally emmecin...@gmail.com wrote: On Sat, Sep 19, 2009 at 10:03 AM, adambundy adambu...@gmail.com wrote: Your syntax is incorrect. What you want, I think, is: $(this).attr({

[jQuery] Re: ajax xml question

2009-09-19 Thread David .Wu
Yup, it will be correct, so weird, why does Google's character wrong. On 9月18日, 下午7時44分, lanxiazhi lanxia...@gmail.com wrote: you may request the a.php directly in the browser ,and see if the charactors display correctly. 2009/9/18 David .Wu chan1...@gmail.com it's not work actually.

[jQuery] Re: data function

2009-09-19 Thread Mike McNally
Have you put a console.log() call in your mouseover handler? On Sat, Sep 19, 2009 at 10:03 AM, cafaro tvdbu...@gmail.com wrote: Hi, I'm trying to get the data() function working, but no success so far. Here's the code I've come up with: //$(a[href*='user.php?nick=']).data(test, true);

[jQuery] Re: Frustrating Scope Question with getJSON

2009-09-19 Thread MorningZ
On Sep 19, 11:34 am, Bill H dysfunct...@gmail.com wrote: I've tried that and still can't seem to get the data into any sort of usable scope. The problem is that while you may be understanding scope, you are not understanding asynchronous calls the $.getJSON call doesn't return anything

[jQuery] Re: Frustrating Scope Question with getJSON

2009-09-19 Thread Michael Geary
In other words, you have to redesign your shortenURL function, like this: function shortenURL( url, callback ) { var apiKey = 'APIKEY'; var apiLogin = 'LOGIN'; $.getJSON( http://api.bit.ly/shorten?version=2.0.1longUrl=; + url + login= + apiLogin + apiKey= + apiKey,

[jQuery] GalleryView not playing nicely with Drupal

2009-09-19 Thread narayanis
I'm using the GalleryView plugin and it works beautifully on a plain HTML page. But when I add the code into a Drupal node, the last filmstrip image wraps to the next line and is invisible. Here's an example of it working as expected on an empty page: http://parkcirclefilms.org/drpl/gallery.htm

[jQuery] help to simplify code

2009-09-19 Thread alienfactory
i would like to know how i could do it better this actualy repeats 3 more time to get the other mouse over states. Please dont write any code i am still learning and would be helpful if anyone could just guide me in the right direction Many Thanks $('#vision, #navvision').hover(

[jQuery] Re: Powerfull WYSIWYG editor with upload image capability

2009-09-19 Thread morwo
On Sep 18, 4:54 pm, Rama Vadakattu rama.vadaka...@gmail.com wrote: Can any one please recommend a powerful WYSIWYG (commercial/open source) editor which has a image upload capability. What about TinyMCE? It seems good and I think it's easy to install new (even your own) plugins :)

[jQuery] Multipart form with Validate + Accordion Problem (validate)

2009-09-19 Thread kolanos
Hi All, I need some pointers on what I'm doing wrong here. I followed the multipart form demo included with jquery.validate, creating a custom validation rule like so: code$.validator.addMethod(pageRequired, function(value, element) { var $element = $(element)

[jQuery] Re: JCarouselLite - pause scrolling

2009-09-19 Thread Steffan A. Cline
on 9/18/09 7:49 AM, dudal at jes...@dudal.com wrote: Hey Steffan I'm glad you like it. I used to go with the full carousel version just for this feature, but then I looked into the code and found that it could be acomplished using only 3 lines of code or so. I posted it on Ganeshjis

[jQuery] Re: Powerfull WYSIWYG editor with upload image capability

2009-09-19 Thread Anush Shetty
On Sat, Sep 19, 2009 at 11:17 PM, morwo lukaszewsk...@gmail.com wrote: On Sep 18, 4:54 pm, Rama Vadakattu rama.vadaka...@gmail.com wrote: Can any one please recommend a powerful WYSIWYG (commercial/open source) editor  which has a image upload capability. What about TinyMCE? It seems good

[jQuery] getJSON returning undefined instead of XMLHttpRequest

2009-09-19 Thread Blixa
I am using getJSON to get results from a different domain and i wanted to get _some_ object back when calling getJSON so that i can insert some variables into the callback scope. Basically, what i wanted to do was this: var new_json = $.getJSON(url, function(data) {

[jQuery] Re: [ why don´t working attr ]

2009-09-19 Thread Lord Gustavo Miguel Angel
Sorry not work! -- From: Mike McNally emmecin...@gmail.com Sent: Saturday, September 19, 2009 1:44 PM To: jquery-en@googlegroups.com Subject: [jQuery] Re: [ why don´t working attr ] On Sat, Sep 19, 2009 at 10:03 AM, adambundy

[jQuery] Re: [ why don´t working attr ]

2009-09-19 Thread Mike McNally
Well the selector was definitely wrong. div.contenedor means select all divs with class 'contenedor'. Your div did not have that class - rather, it had that string as its id value. For that you need div#contenedor. Now, are other things wrong? Maybe; you didn't post anything else. On Sat,

[jQuery] Re: getJSON returning undefined instead of XMLHttpRequest

2009-09-19 Thread Michael Geary
getJSON, like all Ajax and Ajax-style calls, is *asynchronous*. That's what the A in Ajax stands for. Instead of trying to use a return value, you need to use the getJSONcallback function (which you're already providing) to do whatever you want with the data. So your code might look something

[jQuery] Re: [ why don´t working attr ]

2009-09-19 Thread Lord Gustavo Miguel Angel
resolved! 1) thank´s all Was colons. Correct! $(div#contenedor a).attr({ title:asdasdasd, rel:external }); Was div#. correct! Gustavo. -- From: Mike McNally emmecin...@gmail.com Sent: Saturday, September 19, 2009 6:05 PM To:

[jQuery] Re: help to simplify code

2009-09-19 Thread ryan.j
this looks a bit like a homework assignment to be honest ;) for ease of maintenance and to avoid repeating code i'd stick the two anonymous functions into a single own 'proper' function and pass the variables to it. you're also getting the target elements on every single mouseover and mouseout

[jQuery] Re: help to simplify code

2009-09-19 Thread ryan.j
by the way, does that code work? On Sep 19, 10:57 pm, ryan.j ryan.joyce...@googlemail.com wrote: this looks a bit like a homework assignment to be honest  ;) for ease of maintenance and to avoid repeating code i'd stick the two anonymous functions into a single own 'proper' function and pass

[jQuery] Multiple classes selector causing trouble, but why ??

2009-09-19 Thread elpatator
Hi all, i'm struggling with a small yet in,teresting problem. In order to allow users to filter content, i've created a small checkbox list. To each checkbox is attached an ID , and too some divs on the page are attached these id's too (in the class attr that is); one div can be attached to

[jQuery] Re: Multiple classes selector causing trouble, but why ??

2009-09-19 Thread Mike McNally
Code the class qualifier with a .? Like, $(.zoneCoupon , div. + idCoupons).each(function(){ On Sat, Sep 19, 2009 at 5:30 PM, elpatator romain.simi...@gmail.com wrote: Hi all, i'm struggling with a small yet in,teresting problem. In order to allow users to filter content, i've created a

[jQuery] Re: getJSON returning undefined instead of XMLHttpRequest

2009-09-19 Thread Blixa
Hi Mike, I think you might have misread my post and the code attached. I am quite aware of the fact that the callback function only runs upon a successful completion of the request and is run asynchronously. If you look at the code i've written you'll see that i am in fact _counting_ on that

[jQuery] A very simple newbie problem

2009-09-19 Thread Yuzem
Hello, I have a link: a href=some_url onclick=popup() In the script, I have myFunction and I want to use the href: function popup() { $(#popup) .fadeIn('slow') .load(this.href) return false } But it doesn't work. How do I access href? Thanks

[jQuery] Re: Powerfull WYSIWYG editor with upload image capability

2009-09-19 Thread DavGarcia
I have used xstandard for many years now. I am currently evaluating ckeditor though because the plugin architecture makes it extrendable, which would be useful for my web apps. If xstandard works for your environment though, it is something I would recommend. @DavGarcia On Sep 19, 4:19 pm,

[jQuery] Re: help to simplify code

2009-09-19 Thread alienfactory
wow really! not sure what to say about that. Here is a development link to the actual project http://alienfactory.com/vision1/ if any one would like to help out on the javascript jquery question above Thanks in advance for any help

[jQuery] Re: A very simple newbie problem

2009-09-19 Thread Ralph Whitbeck
I would structure things a little differently. don't use the onclick event handler. a href=http://jquery.com; class=popup-linkjQuery/a Then in your javascript use jQuery: $().ready(function(){ $(.popup-link).click(function(){ var $popuplink = $(this); $(#popup)

[jQuery] Re: A very simple newbie problem

2009-09-19 Thread Yuzem
The problem is that the link is dynamically loaded after the original page, the document ready function doesn't affect it. Any idea? -- View this message in context: http://www.nabble.com/A-very-simple-newbie-problem-tp25526787s27240p25527753.html Sent from the jQuery General Discussion

[jQuery] Re: A very simple newbie problem

2009-09-19 Thread Ralph Whitbeck
Then you just need to use the live method to catch the bubbled up DOM elements and attach the click event. See here: $().ready(function(){ $(.popup-link).live(click, function(){ var $popuplink = $(this); $(#popup) .fadeIn(slow)