[jQuery] Using Jquery Form and Block UI together

2007-10-21 Thread wattaka
I have this function that triggers an AJAX call to the server $('#advert_settings_form').ajaxForm(function() { $.blockUI('h1img src=busy.gif / Just a moment.../h1'); //alert(Thank you for your comment!); }); Where do I put the blockUI and unblockUI functions in

[jQuery] Changing a background image with .css() function

2007-10-21 Thread debussy007
Hello ! I am trying to change the background image of a div when clicking on an element. This is my code : [...] $('#accordion').css('background-image', '/public/images/icons/slideDown.jpg'); alert($('#accordion').css('background-image')); [...] But the alert box will never

[jQuery] Re: jQuery Logging (to firebug)

2007-10-21 Thread Byron
yep, use typeof: (function($){ // block scope $.fn.log = function(msg){ if ( typeof window.console !== 'undefined' typeof console.firebug !== 'undefined'){ msg = msg || ''; if(msg !== '') msg += ': '; console.log(%s%o, msg, this);

[jQuery] how to select this ?

2007-10-21 Thread photoboy
I'm just starting out with jQuery and am already staring at a wall. The goal: attach a mouse event to all links in a paragraph with id 'para' and display the text of the link. this is what I've come up with, which obviously doesn't work: $(#para a).click(function(){ var linkContent =

[jQuery] Re: how to select this ?

2007-10-21 Thread Mike Alsup
var linkContent = $(this).text(); $(this) returns a jQuery object, not a DOM element. On 10/21/07, photoboy [EMAIL PROTECTED] wrote: I'm just starting out with jQuery and am already staring at a wall. The goal: attach a mouse event to all links in a paragraph with id 'para' and display the

[jQuery] Re: Changing a background image with .css() function

2007-10-21 Thread debussy007
Ok, I found out thanks to the jquery IRC channel. It had to be url('/public/images/icons/slideDown.jpg') Thank you. debussy007 wrote: Hello ! I am trying to change the background image of a div when clicking on an element. This is my code : [...]

[jQuery] Re: how to select this ?

2007-10-21 Thread photoboy
Wow Mike, thanks. I'm not sure why that worked, but it definitely did the trick! Much appreciated. On Oct 21, 3:01 pm, Mike Alsup [EMAIL PROTECTED] wrote: var linkContent = $(this).text(); $(this) returns a jQuery object, not a DOM element. On 10/21/07, photoboy [EMAIL PROTECTED] wrote:

[jQuery] slideUp/slideDown - Bug in IE with images

2007-10-21 Thread debussy007
Hi, slideUp() slideDown() is not working well when there are images in IE. I made a sample page about this issue : http://matthew16.free.fr/temp/test.html Click on Click Here to animate (slideUp / slideDown). In Mozilla FF it is very smooth, but you will notice the difference in IE. Thank

[jQuery] Re: jqModal ajax question

2007-10-21 Thread Brice Burgess
Dan Richman wrote: Is the onShow callback in place of the ajax parameter passed to .jqm ? Or something like this? onShow: function() { myUrl = document.foo.bar.value; }, ajax: 'myscript.cgi?q=' + myUrl , I really appreciate the help. I'm a perl guy trying to muddle my way thru. Dan,

[jQuery] Can the cycle plugin return an index?

2007-10-21 Thread Tobias Parent
Hey, gang - I've got the cycle plugin working, just great, it's a beautiful thing. However, I have a after callback that needs to get the index of the currently displayed slide. Basically, it's displaying %% of %%% (for those who've got an RPG-II background...). I need to show what number of

[jQuery] Re: Can the cycle plugin return an index?

2007-10-21 Thread Tobias Parent
Never mind, I answered my own question. For those who may need to know, you can use the index() call, so long as you provide a context. For example: var myPlayerWindow = $(#my-player-window); myPlayerWindow.cycle({after: afterSwitch}); function afterSwitch(incoming, outgoing, options) {

[jQuery] Re: Getting window portal size in 1.2.1

2007-10-21 Thread Jeffrey Kretz
Karl, Thanks much, rebuilding jquery from the latest SVN solved the window dimensions. The document.body height is still off, however. If you could take a look at this page again: http://www.scorpiontechnology.com/Cobalt/windowtest.htm The body width is correct - it matches the

[jQuery] Re: how to select this ?

2007-10-21 Thread Klaus Hartl
On 21 Okt., 15:25, photoboy [EMAIL PROTECTED] wrote: Wow Mike, thanks. I'm not sure why that worked, but it definitely did the trick! Much appreciated. Because in your code you're assigning the text method of the jQuery object: $(this).text; That's why the content of the alert is a

[jQuery] Re: how to select this ?

2007-10-21 Thread Jack Killpatrick
I see via other replies that the .text() instead of .text issue has been resolved, but maybe worth pointing out, too (though affecting your issue), is that you say you're looking for multiple p's with the same id. Each id should only be present once on a page. Instead, use a class and select

[jQuery] Re: jQuery Logging (to firebug)

2007-10-21 Thread Dave Methvin
Why check for console.firebug if you really care about console.log though? $.fn.log = function(msg){ window.console window.console.log window.console.log(%s%s%o, msg||, msg?: :, this); return this; };

[jQuery] Re: slideUp/slideDown - Bug in IE with images

2007-10-21 Thread MichaelEvangelista
just a thought, probably better ways - but could you use the same css() to set 'background:none' at the same time you trigger the slideup? -- -- Michael Evangelista, Evangelista Design Web : www.mredesign.com Newsgroups: news://forums.mredesign.com Blog : www.miuaiga.com debussy007 [EMAIL

[jQuery] Re: jqModal ajax question

2007-10-21 Thread Shelane
I brought this up back in May at this post: http://groups.google.com/group/jquery-en/browse_thread/thread/40137ddd2b5cfdcc/ Of which I end it with my workaround to the problem. However, I would love it if jqModal were updated to handle this without my workaround. On Oct 21, 7:26 am, Brice

[jQuery] Re: g has no properties?

2007-10-21 Thread David Foster
The hover method requires two arguments; an error will be thrown on blur if the second argument is omitted. The first argument is a function to be executed on mouseover, the second, a function to be executed on mouseout. By the looks of things, you do not require an action on mouseout, and if

[jQuery] Build plugins throws an error

2007-10-21 Thread Klaus Hartl
All, is it just me or is the current plugin build file somewhat broken? Whenever I try to minify and pack a file I get the following error: js: uncaught JavaScript runtime exception: TypeError: Cannot read property 0.0 from null Java Result: 3 Does anybody know what is going on? --Klaus

[jQuery] $.get content refresh

2007-10-21 Thread Nicolas Leuenberger
Hi, i'm working on a song-ticker for a non-commercial radio station. Now the following code is supposed to call a script which reads the current song out of a database and displays it: script language=javascript function get_tracklist(){ $.get(

[jQuery] Re: search through ajax object

2007-10-21 Thread Wizzud
... success : function(html){ $(html).find('#mydiv').appendTo('#content'); } ... On Oct 20, 11:43 pm, brobro [EMAIL PROTECTED] wrote: Hi, if I use $.ajax() to fetch a file. Would it be possible to search throught that file for a certain element and use that? like

[jQuery] Re: how to select this ?

2007-10-21 Thread Wizzud
Jack, he actually says all links in a paragraph with id 'para', so using $('#para a') is perfectly correct. On Oct 21, 8:43 pm, Jack Killpatrick [EMAIL PROTECTED] wrote: I see via other replies that the .text() instead of .text issue has been resolved, but maybe worth pointing out, too (though

[jQuery] Re: slideUp/slideDown - Bug in IE with images

2007-10-21 Thread Wizzud
Remove 'position:relative;' from your #headerphoto css. On Oct 21, 10:05 pm, MichaelEvangelista [EMAIL PROTECTED] wrote: just a thought, probably better ways - but could you use the same css() to set 'background:none' at the same time you trigger the slideup? -- -- Michael Evangelista,

[jQuery] Re: how to select this ?

2007-10-21 Thread Jack Killpatrick
Hi. I meant to recommend against using the same id for more than one DOM node. I know the selector will work and that dup id's usually don't cause any new headaches, but I've also debugged pages where someone has used the same id more than once for different things, leading to unexpected

[jQuery] Re: Sorting links alphabetically with jQuery

2007-10-21 Thread Yansky
Sorry to bump (and for the double post), but I was really hoping to get this working. I'm trying to sort links alphabetically by their text content. I'd really like to be able to hold on to the jQuery object element reference after sorting the links. Can anyone give me a hand? Cheers. On Oct

[jQuery] Re: how to select this ?

2007-10-21 Thread Jack Killpatrick
ahhhI see that I left a word out here...ooof: (though affecting your issue) I meant to say though *not* affecting your issue. Nine lashes with a wet noodle. - Jack Jack Killpatrick wrote: Hi. I meant to recommend against using the same id for more than one DOM node. I know the

[jQuery] Re: Getting window portal size in 1.2.1

2007-10-21 Thread Karl Swedberg
Hi Jeffrey, I took a look at your page, and the only thing that is off for me (in FF 2.0.x Mac) is the $(document).width() and $('body').width() -- and that's because of a bug in FF that had a hack in Dimensions to work around it, which didn't go into core because it was too hackish.

[jQuery] Gotcha in the ajax call

2007-10-21 Thread M. A. Sridhar
When making a GET call via jQuery.ajax, jQuery 1.2.1 adds a URL parameter named '_' (the single underscore character) whose value is the current time stamp. I'm not sure I understand why, and in any case, this caused me some grief when I tried to use it in a Facebook app. The reason is that the

[jQuery] Re: Gotcha in the ajax call

2007-10-21 Thread Erik Beeson
That parameter is added when you set the 'cache' property to false. Are you doing that? --Erik On 10/21/07, M. A. Sridhar [EMAIL PROTECTED] wrote: When making a GET call via jQuery.ajax, jQuery 1.2.1 adds a URL parameter named '_' (the single underscore character) whose value is the