Re: [jQuery] How to add event handler to XMLHttpRequest.onreadystatechange?

2007-02-21 Thread Klaus Hartl
George Adamson schrieb:
> Hi folks,
> 
> Anyone know if it is possible to add a custom event handler for the
> onreadystatechange events of JQuery AJAX calls?
> 
> I'm accessing a url that is slow to complete but does add to its output as
> it progresses.
> It would be nice to be able to catch each new fragment to inform the user of
> progress.
> 
> I've experimented with the 'beforeSend' ajax argument to fiddle with the
> XMLHttpRequest object's properties before making the ajax call but had no
> luck.
> 
> Many thanks,
> 
> George

$.ajax returns the XmlHttpRequest object, thus you can do:

var xhr = $.ajax({ ... });
xhr._cachedOnreadystatechange = xhr.onreadystatechange;
xhr.onreadystatechange = function() {
 xhr._cachedOnreadystatechange();
 // do something else
};


-- Klaus


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] $.cookie expires problem...Help!

2007-02-21 Thread Klaus Hartl
Ⓙⓐⓚⓔ schrieb:
> well it's not my birthday... but I understand that it works... without
> going thru how the cookie was made (the plugin) I know that arbitrary
> older dates always work. It may be a time zone thing or something else
> that is weird! did you ever try -100 days to see if that kills the
> cookie?
> 
> 
> On 2/21/07, Clodelio C. Delfino <[EMAIL PROTECTED]> wrote:
>> Thanks Jake for the reply, but below codes works for me now...in both
>> ie,ff and opera.
>>
>> $("#div_logout").click(function() {
>> var cuser = $.cookie('my_cookie');
>> var lgout_msg = "Logout user " + cuser + " from the system?";
>>
>> if (confirm(lgout_msg))
>> {
>> alert(cuser + " was succesfully logged out.");
>>
>> if ($.browser.msie)
>> {
>> $.cookie('my_cookie','',{expires: -1});
>> }
>> else
>> {
>> document.cookie = "my_cookie=''; expires=Sun, 01
>> Jan 1970 00:00:01 UTC; path=/"
>> }
>>
>>
>> $(".jqmClose").click();
>>
>> location.reload();
>> }
>>
>> return false;
>> });

I think it works simply because you changed the cookie name consistently 
to "my_cookie". There shouldn't be required a branch for IE. The test 
page works fine in IE.


-- Klaus

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] $.cookie expires problem...Help!

2007-02-21 Thread Klaus Hartl
Clodelio C. Delfino schrieb:
> Hi All,
> 
> $.cookie('my_cookie','',{expires: -1}) doesn't seem to work in FF2.0
> and Opera 9 but working well in IE 6/7 browser.
> 
> May I ask how to ensure that "my_cookie" is assured
> deleted/removed...thanks in advance.
> 
> Btw, below is a snippet of code.
> $(function() {
>   $("#div_logout").click(function() {
>   var cuser = $.cookie('my_cookie');
> var lgout_msg = "Logout user " + cuser + " from the system?";
> 
> if (confirm(lgout_msg))
> {
>   alert(cuser + " was succesfully logged out.");
> 
> $.cookie('sjo_cookie','',{expires: -1});
> 
> $(".jqmClose").click();
> 
> location.reload();
> }
> 
> return false;
>   });
> });
> 
> Cheers,
> cdelfino

Are you sure you are using the correct cookie name when deleting? You 
are using two different cookies here ("my_cookie" and "sjo_cookie") but 
I cannot see where they are saved in this code...

-- Klaus

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] RTFM

2007-02-21 Thread Christopher Jordan
I've got to agree with you about the jQuery community. This is the most 
friendly, and *ACTIVE* mailing list I've ever been a part of.


You may well, be right about YUI-ext getting the better end of the deal. 
I dunno. I've not ever tried to use YUI.


jQuery rules!

Cheers mate!
Chris

Glen Lipka wrote:

Ive been trying all day to figure out this out:

jQuery code:
$(".readOnly").hide();
$(".editable").fadeIn("slow");

YUI-ext code:
---still trying to figure it out

I read the documentation. (very technical, no examples)
I searched the forums. (Couldn't find it)
I searched google. (no dice)
I posted to the forums. (14 views so far, no replies)
I posted to the YUI mailing list. (Nothing yet)
I found this Manual and FAQ, for the first time: 
http://www.yui-ext.com/manual/faq


Read the part where it says, "How do I figure out what error X is and 
why it's happening?"

RTFM.  RTFS.  My mouth dropped when I read that.

I appreciate the partnership between YUI-ext and jQuery. 
But for me, it's YUI-ext that is getting the best part of the deal.  
Access to this community.
I seriously believe that this community and jQuery is something 
totally different and special.


I go to sleep each night praying that I can write jQuery code again soon.

Glen



___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/
  


--
http://cjordan.info

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] $.cookie expires problem...Help!

2007-02-21 Thread Clodelio C. Delfino
Nope it doesn't work...using -100 days.

On 2/22/07, Ⓙⓐⓚⓔ <[EMAIL PROTECTED]> wrote:
> well it's not my birthday... but I understand that it works... without
> going thru how the cookie was made (the plugin) I know that arbitrary
> older dates always work. It may be a time zone thing or something else
> that is weird! did you ever try -100 days to see if that kills the
> cookie?
>
>
> On 2/21/07, Clodelio C. Delfino <[EMAIL PROTECTED]> wrote:
> > Thanks Jake for the reply, but below codes works for me now...in both
> > ie,ff and opera.
> >
> > $("#div_logout").click(function() {
> > var cuser = $.cookie('my_cookie');
> > var lgout_msg = "Logout user " + cuser + " from the system?";
> >
> > if (confirm(lgout_msg))
> > {
> > alert(cuser + " was succesfully logged out.");
> >
> > if ($.browser.msie)
> > {
> > $.cookie('my_cookie','',{expires: -1});
> > }
> > else
> > {
> > document.cookie = "my_cookie=''; expires=Sun, 01
> > Jan 1970 00:00:01 UTC; path=/"
> > }
> >
> >
> > $(".jqmClose").click();
> >
> > location.reload();
> > }
> >
> > return false;
> > });
> >
> > On 2/22/07, Ⓙⓐⓚⓔ <[EMAIL PROTECTED]> wrote:
> > > Cookies get sticky when you alternate www.somewhere.org and
> > > somewhere.org, and you haven't specified the domain for the cookies.
> > >
> > > let's say you set one on somewhere.com then try to clobber it from
> > > www.somewhere.com you can get into trouble,
> > >
> > > this is just general cookie advice. not sure if your cookie has domain 
> > > problems.
> > >
> > > On 2/21/07, Clodelio C. Delfino <[EMAIL PROTECTED]> wrote:
> > > > Hi All,
> > > >
> > > > $.cookie('my_cookie','',{expires: -1}) doesn't seem to work in FF2.0
> > > > and Opera 9 but working well in IE 6/7 browser.
> > > >
> > > > May I ask how to ensure that "my_cookie" is assured
> > > > deleted/removed...thanks in advance.
> > > >
> > > > Btw, below is a snippet of code.
> > > > $(function() {
> > > > $("#div_logout").click(function() {
> > > > var cuser = $.cookie('my_cookie');
> > > > var lgout_msg = "Logout user " + cuser + " from the system?";
> > > >
> > > > if (confirm(lgout_msg))
> > > > {
> > > > alert(cuser + " was succesfully logged out.");
> > > >
> > > > $.cookie('sjo_cookie','',{expires: -1});
> > > >
> > > > $(".jqmClose").click();
> > > >
> > > > location.reload();
> > > > }
> > > >
> > > > return false;
> > > > });
> > > > });
> > > >
> > > > Cheers,
> > > > cdelfino
> > > >
> > > > ___
> > > > jQuery mailing list
> > > > discuss@jquery.com
> > > > http://jquery.com/discuss/
> > > >
> > >
> > >
> > > --
> > > Ⓙⓐⓚⓔ - יעקב   ʝǡǩȩ   ᎫᎪᏦᎬ
> > > ___
> > > jQuery mailing list
> > > discuss@jquery.com
> > > http://jquery.com/discuss/
> > >
> > ___
> > jQuery mailing list
> > discuss@jquery.com
> > http://jquery.com/discuss/
> >
>
>
> --
> Ⓙⓐⓚⓔ - יעקב   ʝǡǩȩ   ᎫᎪᏦᎬ
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] RTFM

2007-02-21 Thread Ⓙⓐⓚⓔ
if it wasn't  for jquery, pure xml,  my puppy and the good people
here, I would have gone crazy long ago!

sleep tight!

On 2/21/07, Glen Lipka <[EMAIL PROTECTED]> wrote:
> Ive been trying all day to figure out this out:
>
> jQuery code:
> $(".readOnly").hide();
> $(".editable").fadeIn("slow");
>
> YUI-ext code:
> ---still trying to figure it out
>
>  I read the documentation. (very technical, no examples)
> I searched the forums. (Couldn't find it)
> I searched google. (no dice)
> I posted to the forums. (14 views so far, no replies)
> I posted to the YUI mailing list. (Nothing yet)
> I found this Manual and FAQ, for the first time:
> http://www.yui-ext.com/manual/faq
>
> Read the part where it says, "How do I figure out what error X is and why
> it's happening?"
> RTFM.  RTFS.  My mouth dropped when I read that.
>
> I appreciate the partnership between YUI-ext and jQuery.
> But for me, it's YUI-ext that is getting the best part of the deal.  Access
> to this community.
>  I seriously believe that this community and jQuery is something totally
> different and special.
>
> I go to sleep each night praying that I can write jQuery code again soon.
>
>  Glen
>
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>
>


-- 
Ⓙⓐⓚⓔ - יעקב   ʝǡǩȩ   ᎫᎪᏦᎬ
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] $.cookie expires problem...Help!

2007-02-21 Thread Ⓙⓐⓚⓔ
well it's not my birthday... but I understand that it works... without
going thru how the cookie was made (the plugin) I know that arbitrary
older dates always work. It may be a time zone thing or something else
that is weird! did you ever try -100 days to see if that kills the
cookie?


On 2/21/07, Clodelio C. Delfino <[EMAIL PROTECTED]> wrote:
> Thanks Jake for the reply, but below codes works for me now...in both
> ie,ff and opera.
>
> $("#div_logout").click(function() {
> var cuser = $.cookie('my_cookie');
> var lgout_msg = "Logout user " + cuser + " from the system?";
>
> if (confirm(lgout_msg))
> {
> alert(cuser + " was succesfully logged out.");
>
> if ($.browser.msie)
> {
> $.cookie('my_cookie','',{expires: -1});
> }
> else
> {
> document.cookie = "my_cookie=''; expires=Sun, 01
> Jan 1970 00:00:01 UTC; path=/"
> }
>
>
> $(".jqmClose").click();
>
> location.reload();
> }
>
> return false;
> });
>
> On 2/22/07, Ⓙⓐⓚⓔ <[EMAIL PROTECTED]> wrote:
> > Cookies get sticky when you alternate www.somewhere.org and
> > somewhere.org, and you haven't specified the domain for the cookies.
> >
> > let's say you set one on somewhere.com then try to clobber it from
> > www.somewhere.com you can get into trouble,
> >
> > this is just general cookie advice. not sure if your cookie has domain 
> > problems.
> >
> > On 2/21/07, Clodelio C. Delfino <[EMAIL PROTECTED]> wrote:
> > > Hi All,
> > >
> > > $.cookie('my_cookie','',{expires: -1}) doesn't seem to work in FF2.0
> > > and Opera 9 but working well in IE 6/7 browser.
> > >
> > > May I ask how to ensure that "my_cookie" is assured
> > > deleted/removed...thanks in advance.
> > >
> > > Btw, below is a snippet of code.
> > > $(function() {
> > > $("#div_logout").click(function() {
> > > var cuser = $.cookie('my_cookie');
> > > var lgout_msg = "Logout user " + cuser + " from the system?";
> > >
> > > if (confirm(lgout_msg))
> > > {
> > > alert(cuser + " was succesfully logged out.");
> > >
> > > $.cookie('sjo_cookie','',{expires: -1});
> > >
> > > $(".jqmClose").click();
> > >
> > > location.reload();
> > > }
> > >
> > > return false;
> > > });
> > > });
> > >
> > > Cheers,
> > > cdelfino
> > >
> > > ___
> > > jQuery mailing list
> > > discuss@jquery.com
> > > http://jquery.com/discuss/
> > >
> >
> >
> > --
> > Ⓙⓐⓚⓔ - יעקב   ʝǡǩȩ   ᎫᎪᏦᎬ
> > ___
> > jQuery mailing list
> > discuss@jquery.com
> > http://jquery.com/discuss/
> >
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>


-- 
Ⓙⓐⓚⓔ - יעקב   ʝǡǩȩ   ᎫᎪᏦᎬ
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] RTFM

2007-02-21 Thread Glen Lipka

Ive been trying all day to figure out this out:

jQuery code:
$(".readOnly").hide();
$(".editable").fadeIn("slow");

YUI-ext code:
---still trying to figure it out

I read the documentation. (very technical, no examples)
I searched the forums. (Couldn't find it)
I searched google. (no dice)
I posted to the forums. (14 views so far, no replies)
I posted to the YUI mailing list. (Nothing yet)
I found this Manual and FAQ, for the first time:
http://www.yui-ext.com/manual/faq

Read the part where it says, "How do I figure out what error X is and why
it's happening?"
RTFM.  RTFS.  My mouth dropped when I read that.

I appreciate the partnership between YUI-ext and jQuery.
But for me, it's YUI-ext that is getting the best part of the deal.  Access
to this community.
I seriously believe that this community and jQuery is something totally
different and special.

I go to sleep each night praying that I can write jQuery code again soon.

Glen
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] jqUploader: flash-based file upload

2007-02-21 Thread Chris Domigan

This is awesome! Didn't know you could use flash to do that :)

Chris
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] $.cookie expires problem...Help!

2007-02-21 Thread Clodelio C. Delfino
Thanks Jake for the reply, but below codes works for me now...in both
ie,ff and opera.

$("#div_logout").click(function() {
var cuser = $.cookie('my_cookie');
var lgout_msg = "Logout user " + cuser + " from the system?";

if (confirm(lgout_msg))
{
alert(cuser + " was succesfully logged out.");

if ($.browser.msie)
{
$.cookie('my_cookie','',{expires: -1});
}
else
{
document.cookie = "my_cookie=''; expires=Sun, 01
Jan 1970 00:00:01 UTC; path=/"
}


$(".jqmClose").click();

location.reload();
}

return false;
});

On 2/22/07, Ⓙⓐⓚⓔ <[EMAIL PROTECTED]> wrote:
> Cookies get sticky when you alternate www.somewhere.org and
> somewhere.org, and you haven't specified the domain for the cookies.
>
> let's say you set one on somewhere.com then try to clobber it from
> www.somewhere.com you can get into trouble,
>
> this is just general cookie advice. not sure if your cookie has domain 
> problems.
>
> On 2/21/07, Clodelio C. Delfino <[EMAIL PROTECTED]> wrote:
> > Hi All,
> >
> > $.cookie('my_cookie','',{expires: -1}) doesn't seem to work in FF2.0
> > and Opera 9 but working well in IE 6/7 browser.
> >
> > May I ask how to ensure that "my_cookie" is assured
> > deleted/removed...thanks in advance.
> >
> > Btw, below is a snippet of code.
> > $(function() {
> > $("#div_logout").click(function() {
> > var cuser = $.cookie('my_cookie');
> > var lgout_msg = "Logout user " + cuser + " from the system?";
> >
> > if (confirm(lgout_msg))
> > {
> > alert(cuser + " was succesfully logged out.");
> >
> > $.cookie('sjo_cookie','',{expires: -1});
> >
> > $(".jqmClose").click();
> >
> > location.reload();
> > }
> >
> > return false;
> > });
> > });
> >
> > Cheers,
> > cdelfino
> >
> > ___
> > jQuery mailing list
> > discuss@jquery.com
> > http://jquery.com/discuss/
> >
>
>
> --
> Ⓙⓐⓚⓔ - יעקב   ʝǡǩȩ   ᎫᎪᏦᎬ
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] $.cookie expires problem...Help!

2007-02-21 Thread Ⓙⓐⓚⓔ
Cookies get sticky when you alternate www.somewhere.org and
somewhere.org, and you haven't specified the domain for the cookies.

let's say you set one on somewhere.com then try to clobber it from
www.somewhere.com you can get into trouble,

this is just general cookie advice. not sure if your cookie has domain problems.

On 2/21/07, Clodelio C. Delfino <[EMAIL PROTECTED]> wrote:
> Hi All,
>
> $.cookie('my_cookie','',{expires: -1}) doesn't seem to work in FF2.0
> and Opera 9 but working well in IE 6/7 browser.
>
> May I ask how to ensure that "my_cookie" is assured
> deleted/removed...thanks in advance.
>
> Btw, below is a snippet of code.
> $(function() {
> $("#div_logout").click(function() {
> var cuser = $.cookie('my_cookie');
> var lgout_msg = "Logout user " + cuser + " from the system?";
>
> if (confirm(lgout_msg))
> {
> alert(cuser + " was succesfully logged out.");
>
> $.cookie('sjo_cookie','',{expires: -1});
>
> $(".jqmClose").click();
>
> location.reload();
> }
>
> return false;
> });
> });
>
> Cheers,
> cdelfino
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>


-- 
Ⓙⓐⓚⓔ - יעקב   ʝǡǩȩ   ᎫᎪᏦᎬ
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] zindex issue

2007-02-21 Thread bmsterling

Looks like Brice got this fixed, thanks anyway.
-- 
Benjamin Sterling
http://www.KenzoMedia.com
http://www.KenzoHosting.com
-- 
View this message in context: 
http://www.nabble.com/zindex-issue-tf3270667.html#a9094242
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] zindex issue

2007-02-21 Thread Benjamin Sterling

Hey guys and gals,
I am trying to figure out why the zindex is not working on my app.

url: http://ov-staging.informationexperts.com/d.htm  /barebones example
url: http://ov-staging.informationexperts.com/index.htm  //actually
production site, login then click on the circle x in the first table.

the zindex of the modal is 5000, the zindex for the overlay and the activeX
fix is 4999 and 4998 respectively.  In my brain, the 5000 should be on top
of all of them, but that is not the case.

css for each element:
the modal: z-index: 200;
overlay: z-index: 198; opacity: 0; height: 603px; width: 100%; position:
absolute; left: 0px; top: 0px; cursor: wait;
activeX: z-index: 199; opacity: 0.5; height: 603px; width: 100%; position:
absolute; left: 0px; top: 0px; cursor: wait;

any help would be appreciated.

--
Benjamin Sterling
http://www.KenzoMedia.com
http://www.KenzoHosting.com
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Introduction and Masked Input Plugin

2007-02-21 Thread Ⓙⓐⓚⓔ
and it does it well!   Perhaps someone else wants to add more options!

On 2/21/07, mrcarxpert <[EMAIL PROTECTED]> wrote:
>
> I'll repeat what I just posted above.  This is really beyond the scope of
> this plugin.  I'm not concerned with validating the input values, only the
> format of the input.  Validation of the values would be better handled by
> something like
> http://bassistance.de/jquery-plugins/jquery-plugin-validation/
> http://bassistance.de/jquery-plugins/jquery-plugin-validation/
>
> I'd rather have this plugin do one thing and do it well. :)
>
> Josh
>
>
>
> Ⓙⓐⓚⓔ wrote:
> >
> > that's pretty sweet for alpha code!
> >
> > I could see the need for money validation $$.00 and other
> > non-fixed length zzz number fields and something like xxx for
> > non-fixed length alpha.
> >
> > I think and object for the format char => the regexp would cut the
> > size of the plugin that would grow with more format types.
> >
> > I've not seen such a sweet handling of validation before!
> >
> > thanks!
> >
> > On 2/13/07, mrcarxpert <[EMAIL PROTECTED]> wrote:
> >>
> >> Hello everyone.  I just wanted to take this opportunity to introduce
> >> myself
> >> and start giving back to the community.
> >>
> >> I've been using jQuery for about 6 months now, and in the process I've
> >> produced a few plugins.  As I clean up the code in these I will be
> >> releasing
> >> them.  The first of which is a masked input plugin for dates,SSNs,phone
> >> numbers, etc.
> >>
> >> I've made the source code and examples for this project available at
> >> http://digitalbush.com/projects/masked-input-plugin
> >> http://digitalbush.com/projects/masked-input-plugin .
> >>
> >> I've tested this in Firefox and IE7 with the latest jQuery library.  If
> >> you
> >> don't mind I'd like to get some feedback on the plugin and how I can make
> >> it
> >> better.  I'd also like to know if there are any problems on other
> >> platforms.
> >>
> >> Since this is my first plugin I'm sure I'm missing a few things, but I
> >> tried
> >> to follow the patterns from some other plugins on the jQuery site.  One
> >> thing I know I'm missing is, what's the best way to ensure that this
> >> masking
> >> is only applied to a text input?  Right now my code returns this.each(
> >> /*code*/), but I'm guessing I might want to
> >> this.find("[EMAIL PROTECTED]'text']").each(/*code*/).  What is the most
> >> elegant
> >> way to do this?
> >>
> >> Anyway, I look forward to some feedback.  I'll consider myself formally
> >> introduced. :)
> >>
> >> Josh
> >> --
> >> View this message in context:
> >> http://www.nabble.com/Introduction-and-Masked-Input-Plugin-tf3224850.html#a8957581
> >> Sent from the JQuery mailing list archive at Nabble.com.
> >>
> >>
> >> ___
> >> jQuery mailing list
> >> discuss@jquery.com
> >> http://jquery.com/discuss/
> >>
> >
> >
> > --
> > Ⓙⓐⓚⓔ - יעקב   ʝǡǩȩ   ᎫᎪᏦᎬ
> > ___
> > jQuery mailing list
> > discuss@jquery.com
> > http://jquery.com/discuss/
> >
> >
>
> --
> View this message in context: 
> http://www.nabble.com/Introduction-and-Masked-Input-Plugin-tf3224850.html#a9093348
> Sent from the JQuery mailing list archive at Nabble.com.
>
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>


-- 
Ⓙⓐⓚⓔ - יעקב   ʝǡǩȩ   ᎫᎪᏦᎬ
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] jqUploader: flash-based file upload

2007-02-21 Thread Benjamin Sterling

Alex,
Tested example 2 in ff2, ie6, ie7, opera 9 and all work great.  Had to click
to activate it in ie6 tho, but really nice.

--
Benjamin Sterling
http://www.KenzoMedia.com
http://www.KenzoHosting.com
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Introduction and Masked Input Plugin

2007-02-21 Thread mrcarxpert

I'll repeat what I just posted above.  This is really beyond the scope of
this plugin.  I'm not concerned with validating the input values, only the
format of the input.  Validation of the values would be better handled by
something like 
http://bassistance.de/jquery-plugins/jquery-plugin-validation/
http://bassistance.de/jquery-plugins/jquery-plugin-validation/ 

I'd rather have this plugin do one thing and do it well. :)

Josh



Ⓙⓐⓚⓔ wrote:
> 
> that's pretty sweet for alpha code!
> 
> I could see the need for money validation $$.00 and other
> non-fixed length zzz number fields and something like xxx for
> non-fixed length alpha.
> 
> I think and object for the format char => the regexp would cut the
> size of the plugin that would grow with more format types.
> 
> I've not seen such a sweet handling of validation before!
> 
> thanks!
> 
> On 2/13/07, mrcarxpert <[EMAIL PROTECTED]> wrote:
>>
>> Hello everyone.  I just wanted to take this opportunity to introduce
>> myself
>> and start giving back to the community.
>>
>> I've been using jQuery for about 6 months now, and in the process I've
>> produced a few plugins.  As I clean up the code in these I will be
>> releasing
>> them.  The first of which is a masked input plugin for dates,SSNs,phone
>> numbers, etc.
>>
>> I've made the source code and examples for this project available at
>> http://digitalbush.com/projects/masked-input-plugin
>> http://digitalbush.com/projects/masked-input-plugin .
>>
>> I've tested this in Firefox and IE7 with the latest jQuery library.  If
>> you
>> don't mind I'd like to get some feedback on the plugin and how I can make
>> it
>> better.  I'd also like to know if there are any problems on other
>> platforms.
>>
>> Since this is my first plugin I'm sure I'm missing a few things, but I
>> tried
>> to follow the patterns from some other plugins on the jQuery site.  One
>> thing I know I'm missing is, what's the best way to ensure that this
>> masking
>> is only applied to a text input?  Right now my code returns this.each(
>> /*code*/), but I'm guessing I might want to
>> this.find("[EMAIL PROTECTED]'text']").each(/*code*/).  What is the most
>> elegant
>> way to do this?
>>
>> Anyway, I look forward to some feedback.  I'll consider myself formally
>> introduced. :)
>>
>> Josh
>> --
>> View this message in context:
>> http://www.nabble.com/Introduction-and-Masked-Input-Plugin-tf3224850.html#a8957581
>> Sent from the JQuery mailing list archive at Nabble.com.
>>
>>
>> ___
>> jQuery mailing list
>> discuss@jquery.com
>> http://jquery.com/discuss/
>>
> 
> 
> -- 
> Ⓙⓐⓚⓔ - יעקב   ʝǡǩȩ   ᎫᎪᏦᎬ
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Introduction-and-Masked-Input-Plugin-tf3224850.html#a9093348
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Introduction and Masked Input Plugin

2007-02-21 Thread mrcarxpert

This is really beyond the scope of this plugin.  I'm not concerned with
validating the input values, only the format of the input.  Validation of
the values would be better handled by something like 
http://bassistance.de/jquery-plugins/jquery-plugin-validation/
http://bassistance.de/jquery-plugins/jquery-plugin-validation/ 


Josh


jpf wrote:
> 
> Very slick plugin, I will for sure use this on my next application. An
> enhancement might be to provide a elegant way of handling non fixed length
> numbers, such as currency inputs. So I guess its not so much masking, but
> pattern matching.
> 
> $("#amount").maskedinput("999,999.99");
> 
> Nice job!
> 
> 
> 
> --- mrcarxpert <[EMAIL PROTECTED]> wrote:
> 
>> 
>> So I'm reading that FF, Opera, and Safari support the
>> DOMCharacterDataModified event.  I'll try to look into this further to
>> produce something to handle pastes.  I've never messed with this event
>> before, so I'm just shooting the dark here.  Any direction from the
>> crowd?
>> 
>> Josh
>> 
>> 
>> John Resig wrote:
>> > 
>> > This is so awesome. I love how the backspace key forces you into the
>> > correct
>> > space.
>> > 
>> > The tricky bit, that I found, is that if you paste in a block of text
>> > (either correct, or incorrect) or if the browser's autocomplete fills
>> in
>> > an
>> > incorrect value it doesn't "correct" it until you hit another key
>> inside
>> > the
>> > field.
>> > 
>> > Offhand, I think the best way to "solve" this is to have a
>> > setInterval(...)
>> > check the fields at a specified rate (a couple times a second? or
>> whatever
>> > seems reasonable). This should solve both issues.
>> > 
>> > Again, this is really really great, I'll be putting this into place,
>> like,
>> > tomorrow.
>> > 
>> > --John
>> > 
>> > On 2/13/07, mrcarxpert <[EMAIL PROTECTED]> wrote:
>> >>
>> >>
>> >> Hello everyone.  I just wanted to take this opportunity to introduce
>> >> myself
>> >> and start giving back to the community.
>> >>
>> >> I've been using jQuery for about 6 months now, and in the process
>> I've
>> >> produced a few plugins.  As I clean up the code in these I will be
>> >> releasing
>> >> them.  The first of which is a masked input plugin for
>> dates,SSNs,phone
>> >> numbers, etc.
>> >>
>> >> I've made the source code and examples for this project available at
>> >> http://digitalbush.com/projects/masked-input-plugin
>> >> http://digitalbush.com/projects/masked-input-plugin .
>> >>
>> >> I've tested this in Firefox and IE7 with the latest jQuery library. 
>> If
>> >> you
>> >> don't mind I'd like to get some feedback on the plugin and how I can
>> make
>> >> it
>> >> better.  I'd also like to know if there are any problems on other
>> >> platforms.
>> >>
>> >> Since this is my first plugin I'm sure I'm missing a few things, but
>> I
>> >> tried
>> >> to follow the patterns from some other plugins on the jQuery site. 
>> One
>> >> thing I know I'm missing is, what's the best way to ensure that this
>> >> masking
>> >> is only applied to a text input?  Right now my code returns
>> this.each(
>> >> /*code*/), but I'm guessing I might want to
>> >> this.find("[EMAIL PROTECTED]'text']").each(/*code*/).  What is the most
>> >> elegant
>> >> way to do this?
>> >>
>> >> Anyway, I look forward to some feedback.  I'll consider myself
>> formally
>> >> introduced. :)
>> >>
>> >> Josh
>> >> --
>> >> View this message in context:
>> >>
>>
> http://www.nabble.com/Introduction-and-Masked-Input-Plugin-tf3224850.html#a8957581
>> >> Sent from the JQuery mailing list archive at Nabble.com.
>> >>
>> >>
>> >> ___
>> >> jQuery mailing list
>> >> discuss@jquery.com
>> >> http://jquery.com/discuss/
>> >>
>> > 
>> > ___
>> > jQuery mailing list
>> > discuss@jquery.com
>> > http://jquery.com/discuss/
>> > 
>> > 
>> 
>> -- 
>> View this message in context:
>>
> http://www.nabble.com/Introduction-and-Masked-Input-Plugin-tf3224850.html#a8970941
>> Sent from the JQuery mailing list archive at Nabble.com.
>> 
>> 
>> ___
>> jQuery mailing list
>> discuss@jquery.com
>> http://jquery.com/discuss/
>> 
> 
> 
> 
>  
> 
> Do you Yahoo!?
> Everyone is raving about the all-new Yahoo! Mail beta.
> http://new.mail.yahoo.com
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Introduction-and-Masked-Input-Plugin-tf3224850.html#a9093330
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Introduction and Masked Input Plugin

2007-02-21 Thread mrcarxpert

These are the exact 2 events I was looking at.  Does Opera or Safari support
either of these 2 methods?  


Kristinn Sigmundsson wrote:
> 
> this is something that I did for a friend not to long ago:
> 
>   jQuery.fn.paste = function(func) {
>   if (typeof func == "function") {
>   jQuery(this).each( function () {
>   if ($.browser.msie) {
>   this.onpaste= function() {
>   
> setTimeout(func+"(this)", 100);
>   };
>   $(this).bind('keyup', 
> function(e) {
>   func(this);
>   });
>   }
>   else if ($.browser.mozilla) {
>   this.addEventListener('input', 
> function() {
>   func(this);
>   }, false);
>   }
>   });
>   }
>   }
> 
> it only needed to support FF and IE, so that's what it supports right
> now... I don't know if there are similar events for non mozilla
> browser that can be added, but you could start with this and see what
> you could make of it.
> 
> you call it with $(obj).paste(callback), pretty straightforward, the
> callback gets passed the object thats changed... hope it helps, oh and
> awesome plugin, I might use that in the near future. Thanks!
> 
> //Kristinn
> 
> On 2/21/07, Jonathan Freeman <[EMAIL PROTECTED]> wrote:
>> Very slick plugin, I will for sure use this on my next application. An
>> enhancement might be to provide a elegant way of handling non fixed
>> length
>> numbers, such as currency inputs. So I guess its not so much masking, but
>> pattern matching.
>>
>> $("#amount").maskedinput("999,999.99");
>>
>> Nice job!
>>
>>
>>
>> --- mrcarxpert <[EMAIL PROTECTED]> wrote:
>>
>> >
>> > So I'm reading that FF, Opera, and Safari support the
>> > DOMCharacterDataModified event.  I'll try to look into this further to
>> > produce something to handle pastes.  I've never messed with this event
>> > before, so I'm just shooting the dark here.  Any direction from the
>> > crowd?
>> >
>> > Josh
>> >
>> >
>> > John Resig wrote:
>> > >
>> > > This is so awesome. I love how the backspace key forces you into the
>> > > correct
>> > > space.
>> > >
>> > > The tricky bit, that I found, is that if you paste in a block of text
>> > > (either correct, or incorrect) or if the browser's autocomplete fills
>> > in
>> > > an
>> > > incorrect value it doesn't "correct" it until you hit another key
>> > inside
>> > > the
>> > > field.
>> > >
>> > > Offhand, I think the best way to "solve" this is to have a
>> > > setInterval(...)
>> > > check the fields at a specified rate (a couple times a second? or
>> > whatever
>> > > seems reasonable). This should solve both issues.
>> > >
>> > > Again, this is really really great, I'll be putting this into place,
>> > like,
>> > > tomorrow.
>> > >
>> > > --John
>> > >
>> > > On 2/13/07, mrcarxpert <[EMAIL PROTECTED]> wrote:
>> > >>
>> > >>
>> > >> Hello everyone.  I just wanted to take this opportunity to introduce
>> > >> myself
>> > >> and start giving back to the community.
>> > >>
>> > >> I've been using jQuery for about 6 months now, and in the process
>> > I've
>> > >> produced a few plugins.  As I clean up the code in these I will be
>> > >> releasing
>> > >> them.  The first of which is a masked input plugin for
>> > dates,SSNs,phone
>> > >> numbers, etc.
>> > >>
>> > >> I've made the source code and examples for this project available at
>> > >> http://digitalbush.com/projects/masked-input-plugin
>> > >> http://digitalbush.com/projects/masked-input-plugin .
>> > >>
>> > >> I've tested this in Firefox and IE7 with the latest jQuery library.
>> > If
>> > >> you
>> > >> don't mind I'd like to get some feedback on the plugin and how I can
>> > make
>> > >> it
>> > >> better.  I'd also like to know if there are any problems on other
>> > >> platforms.
>> > >>
>> > >> Since this is my first plugin I'm sure I'm missing a few things, but
>> > I
>> > >> tried
>> > >> to follow the patterns from some other plugins on the jQuery site.
>> > One
>> > >> thing I know I'm missing is, what's the best way to ensure that this
>> > >> masking
>> > >> is only applied to a text input?  Right now my code returns
>> > this.each(
>> > >> /*code*/), but I'm guessing I might want to
>> > >> this.find("[EMAIL PROTECTED]'text']").each(/*code*/).  What is the most
>> > >> elegant
>> > >> way to do this?
>> > >>
>> > >> Anyway, I look forward to some feedback.  I'll consider myself
>> > formally
>> > >> introdu

[jQuery] jqUploader: flash-based file upload

2007-02-21 Thread Alexandre Plennevaux
Hello,
 
my Plugin replacing file input fields with a richer Flash based upload field 
(with progress bar) is ready for your delicate use:
HYPERLINK 
"http://www.pixeline.be/test/jquery/jqUploader/index.html"http://www.pixeline.be/test/jquery/jqUploader/index.html
 
 
I haven't been able to test it on other platforms than IE7 and FF2 on Windows 
XP. So shoot me if it does not work on your platform.
 
 
 
Special thanks to Vlada and Alex Cook for your help and advise!
 
 
Alexandre
 
 

Alexandre Plennevaux - LAb[au] asbl.vzw / MediaRuimte
Lakensestraat/Rue de Laeken 104
B-1000 Brussel-Bruxelles-Brussels
Belgie-Belgique-Belgium

Tel:+32(0)2.219.65.55
Fax:+32(0)2.426.69.86
Mobile:+32(0)476.23.21.42
HYPERLINK "blocked::http://www.lab-au.com/"http://www.lab-au.com
HYPERLINK "blocked::http://www.mediaruimte.be/"http://www.mediaruimte.be

HYPERLINK 
"blocked::http://www.mediaruimte.be/"__

The information in this e-mail is intended only for the addressee named above.  
If you are not that addressee, please note that any disclosure, distribution or 
copying of this e-mail is prohibited.
Because e-mail can be electronically altered, the integrity of this 
communication cannot be guaranteed.

__

 

-- 
Ce message Envoi est certifié sans virus connu.
Analyse effectuée par AVG.
Version: 7.5.441 / Base de données virus: 268.18.3/694 - Date: 20/02/2007 13:44
 
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] $.cookie expires problem...Help!

2007-02-21 Thread Clodelio C. Delfino
Hi All,

$.cookie('my_cookie','',{expires: -1}) doesn't seem to work in FF2.0
and Opera 9 but working well in IE 6/7 browser.

May I ask how to ensure that "my_cookie" is assured
deleted/removed...thanks in advance.

Btw, below is a snippet of code.
$(function() {
$("#div_logout").click(function() {
var cuser = $.cookie('my_cookie');
var lgout_msg = "Logout user " + cuser + " from the system?";

if (confirm(lgout_msg))
{
alert(cuser + " was succesfully logged out.");

$.cookie('sjo_cookie','',{expires: -1});

$(".jqmClose").click();

location.reload();
}

return false;
});
});

Cheers,
cdelfino

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Introduction and Masked Input Plugin

2007-02-21 Thread Ⓙⓐⓚⓔ
I also noticed that the code is currently ascii-centric. While great
for codes and numbers wouldn't work well for names like José or Jörn.

On 2/21/07, Ⓙⓐⓚⓔ <[EMAIL PROTECTED]> wrote:
> that's pretty sweet for alpha code!
>
> I could see the need for money validation $$.00 and other
> non-fixed length zzz number fields and something like xxx for
> non-fixed length alpha.
>
> I think and object for the format char => the regexp would cut the
> size of the plugin that would grow with more format types.
>
> I've not seen such a sweet handling of validation before!
>
> thanks!
>
> On 2/13/07, mrcarxpert <[EMAIL PROTECTED]> wrote:
> >
> > Hello everyone.  I just wanted to take this opportunity to introduce myself
> > and start giving back to the community.
> >
> > I've been using jQuery for about 6 months now, and in the process I've
> > produced a few plugins.  As I clean up the code in these I will be releasing
> > them.  The first of which is a masked input plugin for dates,SSNs,phone
> > numbers, etc.
> >
> > I've made the source code and examples for this project available at
> > http://digitalbush.com/projects/masked-input-plugin
> > http://digitalbush.com/projects/masked-input-plugin .
> >
> > I've tested this in Firefox and IE7 with the latest jQuery library.  If you
> > don't mind I'd like to get some feedback on the plugin and how I can make it
> > better.  I'd also like to know if there are any problems on other platforms.
> >
> > Since this is my first plugin I'm sure I'm missing a few things, but I tried
> > to follow the patterns from some other plugins on the jQuery site.  One
> > thing I know I'm missing is, what's the best way to ensure that this masking
> > is only applied to a text input?  Right now my code returns this.each(
> > /*code*/), but I'm guessing I might want to
> > this.find("[EMAIL PROTECTED]'text']").each(/*code*/).  What is the most 
> > elegant
> > way to do this?
> >
> > Anyway, I look forward to some feedback.  I'll consider myself formally
> > introduced. :)
> >
> > Josh
> > --
> > View this message in context: 
> > http://www.nabble.com/Introduction-and-Masked-Input-Plugin-tf3224850.html#a8957581
> > Sent from the JQuery mailing list archive at Nabble.com.
> >
> >
> > ___
> > jQuery mailing list
> > discuss@jquery.com
> > http://jquery.com/discuss/
> >
>
>
> --
> Ⓙⓐⓚⓔ - יעקב   ʝǡǩȩ   ᎫᎪᏦᎬ
>


-- 
Ⓙⓐⓚⓔ - יעקב   ʝǡǩȩ   ᎫᎪᏦᎬ
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Gmail-style updates

2007-02-21 Thread Daemach

I always seem to read about closures when my brain is fried at the end of the
day.  I can't seem to get my head around the concept :)

Thanks for the help - I'll read more tomorrow.



Blair Mitchelmore-2 wrote:
> 
> Well first off, my plugin's code can be found at 
>  but I haven't yet set up a 
> page which explains the plug-in's capabilities and I haven't optimised 
> the code or really debugged it as I wrote it on a lark a while ago and 
> haven't put much thought to it since. So after all these disclaimers I 
> suggest you use it with caution. In fact, I've taken the liberty of 
> re-writing my previous code with regular setTimeouts...
> 
> Example:
> var timer;
> var fn = function(e) {
>   if (e && e.type == 'blur') {
>   if (timer)
>   window.clearTimeout(timer);
>   }
>   // Do stuff
> }
> $(whatever).blur(fn).keyup(function() {
>   timer = window.setTimeout(fn,2000);
> }).keydown(function() {
>   if (timer) window.clearTimeout(timer);
> });
> 
> This previous example also takes advantage of another feature you 
> require: closures. The basic idea behind closures is that you can create 
> an anonymous function which takes advantage of data currently in scope 
> even if not existence in the scope the function is ultimately called. 
> You see this when I create the timer variable and then use it inside the 
> fn function I created. Any variables in scope when you define your 
> function can be accessed later on by that function. It's one of the 
> coolest and most powerful features of JavaScript. Hope all that helped.
> 
> -blair
> 
> Daemach wrote:
>> Would you mind posting a link to your timer plugin?
>>
>> If I'm going to use an external function I will need to pass additional
>> parameters.  How do you force passing the event type along with extra
>> data? 
>> I'm newish to javascript...
>>
>>
>>
>> Blair Mitchelmore-2 wrote:
>>> It might be better if you didn't use an anonymous function so you could 
>>> reference it multiple times. (I'm going to use a plugin I wrote that 
>>> jQuerizizes timer events cause it really simplifies the syntax of the 
>>> solution but something equivalent could be done without it.)
>>>
>>> Example:
>>> var fn = function(e) {
>>> if (e.type == 'blur') $(this).stop();
>>> // Do stuff
>>> }
>>> $(whatever).blur(fn).keyup(function() {
>>> $(this).once(2000,fn);
>>> }).keydown(function() {
>>> $(this).stop();
>>> });
>>>
>>> Hope that helps.
>>>
>>> -blair
>>>
>>> Daemach wrote:
 I have a form with which I want to do ajax updates as they type.  If
 they
 stop typing for more than 2 seconds it should update the field.  If the
 field blurs before the 2 seconds are up it should update the field.  

 I have the ajax side of it worked out, and currently the updates work
 properly when the field blurs.  I just need some ideas on how to write
 the
 timer function for the keypresses and how it integrates with the blur
 function so the function doesn't get called twice and so there are no
 memory
 leaks from timers set then abandoned because the blur event got to it
 first.

 I'm going for elegance here :)  I could write an outside function that
 gets
 called from both event handlers but that seems cheezy.  There must be a
 way
 to do this with an anonymous function...
>>>
>>> ___
>>> jQuery mailing list
>>> discuss@jquery.com
>>> http://jquery.com/discuss/
>>>
>>>
>>
> 
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Gmail-style-updates-tf3269331.html#a9093056
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] specifying count for rss feed display with each function

2007-02-21 Thread John W

My mistake.  I hard coded the value in the code I pasted by accident.

this:
 $("item", xml).lt(10).each(function(){

should be
 $("item", xml).lt(items_count).each(function(){



Kristinn Sigmundsson wrote:
> 
> hmm, shouldn't you variable items_count, be used in lt(items_count)?
> can't see where it's used in you script.
> 
> //Kristinn
> 
> On 2/22/07, John W <[EMAIL PROTECTED]> wrote:
>>
>> Just thought Id post the full deal (well the itty bitty jquery script)
>> for
>> anyone else that is looking for something similiar to put rss feeds in
>> their
>> website. the cool thing is that with the latest version of jquery this
>> works
>> with remote urls. In the past I had to grab the file locally on my
>> domain.
>>
>> Have to give credit to Jim Davis since I found his post on the topic
>> earlier.
>> http://www.nabble.com/RSS-Feed-Reader---Re-visit-tf1915606.html#a5244340
>>
>>
>> 
>> 
>> > type=text/javascript>
>> 
>>
>> var html = '';
>> // count for lines display
>> var items_count = 10;
>> // feed location
>> var feed = 'http://rss.movies.yahoo.com/dvd/topsellers.xml';
>> // replace url for link
>> var u =
>> 'mainitem.html?hdSearchType=Catalog&radCateg=DVD&selSearchOption=Begins&selSortType=descr&chkDetailView=off&txtSearch='
>>
>> $(document).ready(function(){
>>   $.get(feed, function(xml){
>>   $("item", xml).lt(10).each(function(){
>>   $(this).find("item").each(function(){
>>   html += "";
>>   }).end().find("title").each(function(){
>>   html += " " + u + this.text + " " + this.text +
>> "
>> 
"; >> }); >> }); >> >> $("#rss").html(html).slideDown("slow"); >> >> }); >> }); >> >> >> >> >> Loading... >> >> >> -- >> View this message in context: >> http://www.nabble.com/specifying-count-for-rss-feed-display-with-each-function-tf3269015.html#a9091666 >> Sent from the JQuery mailing list archive at Nabble.com. >> >> >> ___ >> jQuery mailing list >> discuss@jquery.com >> http://jquery.com/discuss/ >> > > ___ > jQuery mailing list > discuss@jquery.com > http://jquery.com/discuss/ > > -- View this message in context: http://www.nabble.com/specifying-count-for-rss-feed-display-with-each-function-tf3269015.html#a9093057 Sent from the JQuery mailing list archive at Nabble.com. ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/

Re: [jQuery] Introduction and Masked Input Plugin

2007-02-21 Thread Ⓙⓐⓚⓔ
that's pretty sweet for alpha code!

I could see the need for money validation $$.00 and other
non-fixed length zzz number fields and something like xxx for
non-fixed length alpha.

I think and object for the format char => the regexp would cut the
size of the plugin that would grow with more format types.

I've not seen such a sweet handling of validation before!

thanks!

On 2/13/07, mrcarxpert <[EMAIL PROTECTED]> wrote:
>
> Hello everyone.  I just wanted to take this opportunity to introduce myself
> and start giving back to the community.
>
> I've been using jQuery for about 6 months now, and in the process I've
> produced a few plugins.  As I clean up the code in these I will be releasing
> them.  The first of which is a masked input plugin for dates,SSNs,phone
> numbers, etc.
>
> I've made the source code and examples for this project available at
> http://digitalbush.com/projects/masked-input-plugin
> http://digitalbush.com/projects/masked-input-plugin .
>
> I've tested this in Firefox and IE7 with the latest jQuery library.  If you
> don't mind I'd like to get some feedback on the plugin and how I can make it
> better.  I'd also like to know if there are any problems on other platforms.
>
> Since this is my first plugin I'm sure I'm missing a few things, but I tried
> to follow the patterns from some other plugins on the jQuery site.  One
> thing I know I'm missing is, what's the best way to ensure that this masking
> is only applied to a text input?  Right now my code returns this.each(
> /*code*/), but I'm guessing I might want to
> this.find("[EMAIL PROTECTED]'text']").each(/*code*/).  What is the most 
> elegant
> way to do this?
>
> Anyway, I look forward to some feedback.  I'll consider myself formally
> introduced. :)
>
> Josh
> --
> View this message in context: 
> http://www.nabble.com/Introduction-and-Masked-Input-Plugin-tf3224850.html#a8957581
> Sent from the JQuery mailing list archive at Nabble.com.
>
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>


-- 
Ⓙⓐⓚⓔ - יעקב   ʝǡǩȩ   ᎫᎪᏦᎬ
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Gmail-style updates

2007-02-21 Thread Daemach

AjaxCFC is a framework created by Rob Gonda.  It's fantastic for ajax + cold
fusion.  Spread the word...

You can find it here:  http://www.robgonda.com/blog/projects/ajaxcfc/

The original version wasn't jquery compatible so he created a jquery plugin
that interfaces very nicely.  You'll have to dig through his blog for the
updates:  http://www.robgonda.com/blog/


Web Specialist wrote:
> 
> Hi. Great cfc invocation! Do you have used ajaxcfc? What's $.AjaxCFC? A
> function? Do you can share that code with us(CFers)? jQuery integration
> for
> ajax calls and CFC backend is a great marriage!
> 
> Cheers
> 
> 2007/2/21, Daemach <[EMAIL PROTECTED]>:
>>
>>
>> In what context does the timer run?  Each field will have its own
>> timer/ajax
>> function.  If I have multiple text fields, and people are typing and
>> tabbing
>> through them quickly the updates still need to happen reliably.
>>
>> Currently it works like this:
>>
>> $(document).ready( function() {
>> $('[EMAIL PROTECTED]').each( function() {
>> $(this).blur( function() {
>> $.AjaxCFC({url:
>> "/namechangedtoprotecttheinnocent.cfc", method:
>> "updateAttendee", data:
>> {fid:this.id,field:this.id.split("_")[0],id:this.id.split("_")[1],value:
>> this.value},
>> success: function(r){$('#'+r).css("backgroundColor","#ddFFdd");}});
>> $(this).css("backgroundColor","#FF");
>> });
>> });
>> });
>>
>>
>>
>> Jörn Zaefferer wrote:
>> >
>> > Daemach schrieb:
>> >> I have a form with which I want to do ajax updates as they type.  If
>> they
>> >> stop typing for more than 2 seconds it should update the field.  If
>> the
>> >> field blurs before the 2 seconds are up it should update the field.
>> >>
>> >> I have the ajax side of it worked out, and currently the updates work
>> >> properly when the field blurs.  I just need some ideas on how to write
>> >> the
>> >> timer function for the keypresses and how it integrates with the blur
>> >> function so the function doesn't get called twice and so there are no
>> >> memory
>> >> leaks from timers set then abandoned because the blur event got to it
>> >> first.
>> >>
>> >> I'm going for elegance here :)  I could write an outside function that
>> >> gets
>> >> called from both event handlers but that seems cheezy.  There must be
>> a
>> >> way
>> >> to do this with an anonymous function...
>> >>
>> > Well, sounds like you need to start a timeout on keyup/press and clear
>> > that with the blur function, in case it is still running. So you need
>> > the timeout id and a updated-flag.
>> >
>> > Hope that helps.
>> >
>> > --
>> > Jörn Zaefferer
>> >
>> > http://bassistance.de
>> >
>> >
>> > ___
>> > jQuery mailing list
>> > discuss@jquery.com
>> > http://jquery.com/discuss/
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Gmail-style-updates-tf3269331.html#a9089663
>> Sent from the JQuery mailing list archive at Nabble.com.
>>
>>
>> ___
>> jQuery mailing list
>> discuss@jquery.com
>> http://jquery.com/discuss/
>>
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Gmail-style-updates-tf3269331.html#a9092987
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] How to add event handler to XMLHttpRequest.onreadystatechange?

2007-02-21 Thread Benjamin Sterling

George,
Have you tried looking the the timeout param?  Not sure if it does what I
think it does.


--
Benjamin Sterling
http://www.KenzoMedia.com
http://www.KenzoHosting.com
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] using end(), or storing queries as variables

2007-02-21 Thread Daemach

OK I rewrote and tested it with your pseudocode.  This is kind of loose, but
it does work. 


$('div.A/input:checkbox').each(function(){
$(this).click(function(){

$(this).siblings("input:text").attr("value",function() 
{return
($(this).siblings("input:checkbox").attr("checked")) ? "message1" :
"message2" } );
});
});

If you have a predefined naming scheme, such as id="someprefix_someid" it
could tighten things up a bit.  You can then use 

$('div.A/input:checkbox').each(function(){
$(this).click(function(){
message = (this.checked) ? "message1" : "message2";

$('#A_text_'+this.id.split("_")[2]).attr("value",message);
});
}); 




bdanchilla wrote:
> 
> Hello,
>   I am using jquery with a CMS (drupal). I have written code which
> generates html output like the following pseudocode
> 
> 
>  
>  
> 
> 
>  
>  
> 
> ...
> 
>  
>  
> 
>   
> 
> I want a check/uncheck to change the content of the textbox. I have tried
> to write javascript like the following:
> 
> $("div.A").each(
>function(){
>  $(this).find("[EMAIL PROTECTED]@name^=A_").click(){
> function(){ 
>  if(this.checked){
>   $(this).  find("[EMAIL PROTECTED]@name^=A_]").val("msg
> 1");
>  }else{
>$(this).  find("[EMAIL PROTECTED]@name^=A_]").val("msg
> 2");
> }
>   }
>)
>}
>   );  
> }
>  );
> 
> The problem is that I can find the first element (the checkbox) but not
> the textfield for each division, since the second search starts from the
> first element. I am new to jquery. Am I supposed to use end() somewhere
> and store the checkbox reference in a variable of some sort? Should I use
> parents() or some other function? Any help is appreciated.
> 

-- 
View this message in context: 
http://www.nabble.com/using-end%28%29%2C-or-storing-queries-as-variables-tf3269753.html#a9092783
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] specifying count for rss feed display with each function

2007-02-21 Thread Kristinn Sigmundsson
hmm, shouldn't you variable items_count, be used in lt(items_count)?
can't see where it's used in you script.

//Kristinn

On 2/22/07, John W <[EMAIL PROTECTED]> wrote:
>
> Just thought Id post the full deal (well the itty bitty jquery script) for
> anyone else that is looking for something similiar to put rss feeds in their
> website. the cool thing is that with the latest version of jquery this works
> with remote urls. In the past I had to grab the file locally on my domain.
>
> Have to give credit to Jim Davis since I found his post on the topic
> earlier.
> http://www.nabble.com/RSS-Feed-Reader---Re-visit-tf1915606.html#a5244340
>
>
> 
> 
> 
> 
>
> var html = '';
> // count for lines display
> var items_count = 10;
> // feed location
> var feed = 'http://rss.movies.yahoo.com/dvd/topsellers.xml';
> // replace url for link
> var u =
> 'mainitem.html?hdSearchType=Catalog&radCateg=DVD&selSearchOption=Begins&selSortType=descr&chkDetailView=off&txtSearch='
>
> $(document).ready(function(){
>   $.get(feed, function(xml){
>   $("item", xml).lt(10).each(function(){
>   $(this).find("item").each(function(){
>   html += "";
>   }).end().find("title").each(function(){
>   html += " " + u + this.text + " " + this.text + "
> 
"; > }); > }); > > $("#rss").html(html).slideDown("slow"); > > }); > }); > > > > > Loading... > > > -- > View this message in context: > http://www.nabble.com/specifying-count-for-rss-feed-display-with-each-function-tf3269015.html#a9091666 > Sent from the JQuery mailing list archive at Nabble.com. > > > ___ > jQuery mailing list > discuss@jquery.com > http://jquery.com/discuss/ > ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/

Re: [jQuery] Gmail-style updates

2007-02-21 Thread Blair Mitchelmore
Well first off, my plugin's code can be found at 
 but I haven't yet set up a 
page which explains the plug-in's capabilities and I haven't optimised 
the code or really debugged it as I wrote it on a lark a while ago and 
haven't put much thought to it since. So after all these disclaimers I 
suggest you use it with caution. In fact, I've taken the liberty of 
re-writing my previous code with regular setTimeouts...

Example:
var timer;
var fn = function(e) {
if (e && e.type == 'blur') {
if (timer)
window.clearTimeout(timer);
}
// Do stuff
}
$(whatever).blur(fn).keyup(function() {
timer = window.setTimeout(fn,2000);
}).keydown(function() {
if (timer) window.clearTimeout(timer);
});

This previous example also takes advantage of another feature you 
require: closures. The basic idea behind closures is that you can create 
an anonymous function which takes advantage of data currently in scope 
even if not existence in the scope the function is ultimately called. 
You see this when I create the timer variable and then use it inside the 
fn function I created. Any variables in scope when you define your 
function can be accessed later on by that function. It's one of the 
coolest and most powerful features of JavaScript. Hope all that helped.

-blair

Daemach wrote:
> Would you mind posting a link to your timer plugin?
>
> If I'm going to use an external function I will need to pass additional
> parameters.  How do you force passing the event type along with extra data? 
> I'm newish to javascript...
>
>
>
> Blair Mitchelmore-2 wrote:
>> It might be better if you didn't use an anonymous function so you could 
>> reference it multiple times. (I'm going to use a plugin I wrote that 
>> jQuerizizes timer events cause it really simplifies the syntax of the 
>> solution but something equivalent could be done without it.)
>>
>> Example:
>> var fn = function(e) {
>> if (e.type == 'blur') $(this).stop();
>> // Do stuff
>> }
>> $(whatever).blur(fn).keyup(function() {
>> $(this).once(2000,fn);
>> }).keydown(function() {
>> $(this).stop();
>> });
>>
>> Hope that helps.
>>
>> -blair
>>
>> Daemach wrote:
>>> I have a form with which I want to do ajax updates as they type.  If they
>>> stop typing for more than 2 seconds it should update the field.  If the
>>> field blurs before the 2 seconds are up it should update the field.  
>>>
>>> I have the ajax side of it worked out, and currently the updates work
>>> properly when the field blurs.  I just need some ideas on how to write
>>> the
>>> timer function for the keypresses and how it integrates with the blur
>>> function so the function doesn't get called twice and so there are no
>>> memory
>>> leaks from timers set then abandoned because the blur event got to it
>>> first.
>>>
>>> I'm going for elegance here :)  I could write an outside function that
>>> gets
>>> called from both event handlers but that seems cheezy.  There must be a
>>> way
>>> to do this with an anonymous function...
>>
>> ___
>> jQuery mailing list
>> discuss@jquery.com
>> http://jquery.com/discuss/
>>
>>
>


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] jQuery and Rails

2007-02-21 Thread Yehuda Katz

I've carefully read all of the responses to this thread (keep em coming),
and believe that my solution will work very well for almost all of the
concerns expressed here.

I'll announce more details about the mechanism and syntax sometime in the
next week or so, but I believe everyone will be very satisfied.

-- Yehuda

On 2/21/07, Peter De Berdt <[EMAIL PROTECTED]> wrote:


> I realize there is a group of people who'd like to just write everything
in Ruby (i.e. get to
> use javascript without having to know javascript), but I think that's a
red herring.

That's not the main issue, but without MinusMOR, your RJS files would
always look like
page << "some_jquery_code;"
page << "some_jquery_code;"
I don't mind writing JavaScript myself either, but in order for jQuery
for Rails to be easily integrated into existing applications, the
helpers are a must. I have my fair share of applications that combine
both helpers and sporadically some custom JS code, but I don't want to
refactor all my RJS and view code just for being able to integrate
jQuery instead of proto/script. If it could be plug-and-play (and not
plug-and-pray) I wouldn't doubt and just deploy new versions of my
AJAXed apps just for jQuery.

> Here are the main issues I've run into:
> + unobtrusively including js specific to a view

... and a Rails way of keeping the behavior in a separate file
(separate behavior from representation). What I would do now, is
either use a partial to render the JS in the header and put it in my
layout or just add JS files to the public/javascripts directory, but I
don't find it very Rails-like, it doesn't feel like the best solution.

> So, in whatever.rhtml, do something like:
>
>  <% javascript :file => 'path/to/plugin.js' %>
>  <% javascript :text => %{ $('p').css('color','blue'); } %>
>  Whatever...
>  <% javascript :text => %{ $('p').css('font-size', '2em'); }% %>
>
> And get:
>
>  
>
>  
>
>
>  Whatever...
>
>  

Looks like Luke Redpath's UJS4Rails way of doing things :-) It's not a
bad solution, but UJS4Rails has introduced unreliable behavior in some
of the apps I have been working on.

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/





--
Yehuda Katz
Web Developer | Wycats Designs
(ph)  718.877.1325
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] using end(), or storing queries as variables

2007-02-21 Thread Daemach

This is untested, but maybe it will get you on the right path.

$('div.A//input:checkbox').each(function(){}
$(this).click(function(){
$(this).siblings("input:text").attr("value",function() {return
(this.checked) ? "message1" : "message2" } );
});
);



bdanchilla wrote:
> 
> Hello,
>   I am using jquery with a CMS (drupal). I have written code which
> generates html output like the following pseudocode
> 
> 
>  
>  
> 
> 
>  
>  
> 
> ...
> 
>  
>  
> 
>   
> 
> I want a check/uncheck to change the content of the textbox. I have tried
> to write javascript like the following:
> 
> $("div.A").each(
>function(){
>  $(this).find("[EMAIL PROTECTED]@name^=A_").click(){
> function(){ 
>  if(this.checked){
>   $(this).  find("[EMAIL PROTECTED]@name^=A_]").val("msg
> 1");
>  }else{
>$(this).  find("[EMAIL PROTECTED]@name^=A_]").val("msg
> 2");
> }
>   }
>)
>}
>   );  
> }
>  );
> 
> The problem is that I can find the first element (the checkbox) but not
> the textfield for each division, since the second search starts from the
> first element. I am new to jquery. Am I supposed to use end() somewhere
> and store the checkbox reference in a variable of some sort? Should I use
> parents() or some other function? Any help is appreciated.
> 

-- 
View this message in context: 
http://www.nabble.com/using-end%28%29%2C-or-storing-queries-as-variables-tf3269753.html#a9092114
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Gmail-style updates

2007-02-21 Thread Web Specialist

Hi. Great cfc invocation! Do you have used ajaxcfc? What's $.AjaxCFC? A
function? Do you can share that code with us(CFers)? jQuery integration for
ajax calls and CFC backend is a great marriage!

Cheers

2007/2/21, Daemach <[EMAIL PROTECTED]>:



In what context does the timer run?  Each field will have its own
timer/ajax
function.  If I have multiple text fields, and people are typing and
tabbing
through them quickly the updates still need to happen reliably.

Currently it works like this:

$(document).ready( function() {
$('[EMAIL PROTECTED]').each( function() {
$(this).blur( function() {
$.AjaxCFC({url:
"/namechangedtoprotecttheinnocent.cfc", method:
"updateAttendee", data:
{fid:this.id,field:this.id.split("_")[0],id:this.id.split("_")[1],value:
this.value},
success: function(r){$('#'+r).css("backgroundColor","#ddFFdd");}});
$(this).css("backgroundColor","#FF");
});
});
});



Jörn Zaefferer wrote:
>
> Daemach schrieb:
>> I have a form with which I want to do ajax updates as they type.  If
they
>> stop typing for more than 2 seconds it should update the field.  If the
>> field blurs before the 2 seconds are up it should update the field.
>>
>> I have the ajax side of it worked out, and currently the updates work
>> properly when the field blurs.  I just need some ideas on how to write
>> the
>> timer function for the keypresses and how it integrates with the blur
>> function so the function doesn't get called twice and so there are no
>> memory
>> leaks from timers set then abandoned because the blur event got to it
>> first.
>>
>> I'm going for elegance here :)  I could write an outside function that
>> gets
>> called from both event handlers but that seems cheezy.  There must be a
>> way
>> to do this with an anonymous function...
>>
> Well, sounds like you need to start a timeout on keyup/press and clear
> that with the blur function, in case it is still running. So you need
> the timeout id and a updated-flag.
>
> Hope that helps.
>
> --
> Jörn Zaefferer
>
> http://bassistance.de
>
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>
>

--
View this message in context:
http://www.nabble.com/Gmail-style-updates-tf3269331.html#a9089663
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] jQuery and Rails

2007-02-21 Thread Peter De Berdt
> I realize there is a group of people who'd like to just write everything in 
> Ruby (i.e. get to
> use javascript without having to know javascript), but I think that's a red 
> herring.

That's not the main issue, but without MinusMOR, your RJS files would
always look like
page << "some_jquery_code;"
page << "some_jquery_code;"
I don't mind writing JavaScript myself either, but in order for jQuery
for Rails to be easily integrated into existing applications, the
helpers are a must. I have my fair share of applications that combine
both helpers and sporadically some custom JS code, but I don't want to
refactor all my RJS and view code just for being able to integrate
jQuery instead of proto/script. If it could be plug-and-play (and not
plug-and-pray) I wouldn't doubt and just deploy new versions of my
AJAXed apps just for jQuery.

> Here are the main issues I've run into:
> + unobtrusively including js specific to a view

... and a Rails way of keeping the behavior in a separate file
(separate behavior from representation). What I would do now, is
either use a partial to render the JS in the header and put it in my
layout or just add JS files to the public/javascripts directory, but I
don't find it very Rails-like, it doesn't feel like the best solution.

> So, in whatever.rhtml, do something like:
>
>  <% javascript :file => 'path/to/plugin.js' %>
>  <% javascript :text => %{ $('p').css('color','blue'); } %>
>  Whatever...
>  <% javascript :text => %{ $('p').css('font-size', '2em'); }% %>
>
> And get:
>
>  
>
>  
>
>
>  Whatever...
>
>  

Looks like Luke Redpath's UJS4Rails way of doing things :-) It's not a
bad solution, but UJS4Rails has introduced unreliable behavior in some
of the apps I have been working on.

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Gmail-style updates

2007-02-21 Thread Daemach

Would you mind posting a link to your timer plugin?

If I'm going to use an external function I will need to pass additional
parameters.  How do you force passing the event type along with extra data? 
I'm newish to javascript...



Blair Mitchelmore-2 wrote:
> 
> It might be better if you didn't use an anonymous function so you could 
> reference it multiple times. (I'm going to use a plugin I wrote that 
> jQuerizizes timer events cause it really simplifies the syntax of the 
> solution but something equivalent could be done without it.)
> 
> Example:
> var fn = function(e) {
> if (e.type == 'blur') $(this).stop();
> // Do stuff
> }
> $(whatever).blur(fn).keyup(function() {
> $(this).once(2000,fn);
> }).keydown(function() {
> $(this).stop();
> });
> 
> Hope that helps.
> 
> -blair
> 
> Daemach wrote:
>> I have a form with which I want to do ajax updates as they type.  If they
>> stop typing for more than 2 seconds it should update the field.  If the
>> field blurs before the 2 seconds are up it should update the field.  
>>
>> I have the ajax side of it worked out, and currently the updates work
>> properly when the field blurs.  I just need some ideas on how to write
>> the
>> timer function for the keypresses and how it integrates with the blur
>> function so the function doesn't get called twice and so there are no
>> memory
>> leaks from timers set then abandoned because the blur event got to it
>> first.
>>
>> I'm going for elegance here :)  I could write an outside function that
>> gets
>> called from both event handlers but that seems cheezy.  There must be a
>> way
>> to do this with an anonymous function...
> 
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Gmail-style-updates-tf3269331.html#a9091920
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] jQuery and Rails

2007-02-21 Thread Peter De Berdt
On 2/21/07, Klaus Hartl <[EMAIL PROTECTED]> wrote:
> Peter De Berdt schrieb:
> >> 1) Are you using Rails?
> >
> > Yes, close to 24/7 :-)
> >
> >> 3) Would you prefer an approach that generated JS by writing Ruby helpers
> >> that generated jQuery code, or an approach that made is easier to link up
> >> existing jQuery code into Rails?
> >
> > A mix of both actually, it would be great if I could just replace
> > Prototype/scriptaculous with jquery/interface and I wouldn't have to
> > replace my Rails helpers with Javascript code (I prefer to use Rails
> > helpers for the simple stuff and resort to custom JS code if the Rails
> > helpers are not sufficient). The Rails helpers are really great for
> > the day-to-day stuff, but they don't encompass the complete
> > functionality of Proto/script.
>
> This is *exactly* what I'm after - combined with the idea of UOJS, that is.

Indeed, but considering jQuery users already being used to UOJS, I
didn't mention it, it seemed obvious to me :-)

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] and a final example

2007-02-21 Thread John W

Just thought Id post the full deal (well the itty bitty jquery script) for
anyone else that is looking for something similiar to put rss feeds in their
website. the cool thing is that with the latest version of jquery this works
with remote urls. In the past I had to grab the file locally on my domain.

Have to give credit to Jim Davis since I found his post on the topic
earlier.
http://www.nabble.com/RSS-Feed-Reader---Re-visit-tf1915606.html#a5244340







var html = '';
// count for lines display
var items_count = 10;
// feed location
var feed = 'http://rss.movies.yahoo.com/dvd/topsellers.xml'; 
// replace url for link
var u =
'mainitem.html?hdSearchType=Catalog&radCateg=DVD&selSearchOption=Begins&selSortType=descr&chkDetailView=off&txtSearch='

$(document).ready(function(){
  $.get(feed, function(xml){
  $("item", xml).lt(10).each(function(){
  $(this).find("item").each(function(){
  html += "";
  }).end().find("title").each(function(){
  html += " " + u + this.text + " " + this.text + "

"; }); }); $("#rss").html(html).slideDown("slow"); }); }); Loading... -- View this message in context: http://www.nabble.com/specifying-count-for-rss-feed-display-with-each-function-tf3269015.html#a9091708 Sent from the JQuery mailing list archive at Nabble.com. ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/

[jQuery] and a final example

2007-02-21 Thread John W

Just thought Id post the full deal (well the itty bitty jquery script) for
anyone else that is looking for something similiar to put rss feeds in their
website. the cool thing is that with the latest version of jquery this works
with remote urls. In the past I had to grab the file locally on my domain.

Have to give credit to Jim Davis since I found his post on the topic
earlier.
http://www.nabble.com/RSS-Feed-Reader---Re-visit-tf1915606.html#a5244340







var html = '';
// count for lines display
var items_count = 10;
// feed location
var feed = 'http://rss.movies.yahoo.com/dvd/topsellers.xml'; 
// replace url for link
var u =
'mainitem.html?hdSearchType=Catalog&radCateg=DVD&selSearchOption=Begins&selSortType=descr&chkDetailView=off&txtSearch='

$(document).ready(function(){
  $.get(feed, function(xml){
  $("item", xml).lt(10).each(function(){
  $(this).find("item").each(function(){
  html += "";
  }).end().find("title").each(function(){
  html += " " + u + this.text + " " + this.text + "

"; }); }); $("#rss").html(html).slideDown("slow"); }); }); Loading... -- View this message in context: http://www.nabble.com/specifying-count-for-rss-feed-display-with-each-function-tf3269015.html#a9091667 Sent from the JQuery mailing list archive at Nabble.com. ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/

[jQuery] and the final simple little feeder

2007-02-21 Thread John W

Just thought Id post the full deal (well the itty bitty jquery script) for
anyone else that is looking for something similiar to put rss feeds in their
website. the cool thing is that with the latest version of jquery this works
with remote urls. In the past I had to grab the file locally on my domain.

Have to give credit to Jim Davis since I found his post on the topic
earlier.
http://www.nabble.com/RSS-Feed-Reader---Re-visit-tf1915606.html#a5244340







var html = '';
// count for lines display
var items_count = 10;
// feed location
var feed = 'http://rss.movies.yahoo.com/dvd/topsellers.xml'; 
// replace url for link
var u =
'mainitem.html?hdSearchType=Catalog&radCateg=DVD&selSearchOption=Begins&selSortType=descr&chkDetailView=off&txtSearch='

$(document).ready(function(){
  $.get(feed, function(xml){
  $("item", xml).lt(10).each(function(){
  $(this).find("item").each(function(){
  html += "";
  }).end().find("title").each(function(){
  html += " " + u + this.text + " " + this.text + "

"; }); }); $("#rss").html(html).slideDown("slow"); }); }); Loading... -- View this message in context: http://www.nabble.com/specifying-count-for-rss-feed-display-with-each-function-tf3269015.html#a9091664 Sent from the JQuery mailing list archive at Nabble.com. ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/

Re: [jQuery] specifying count for rss feed display with each function

2007-02-21 Thread John W

Just thought Id post the full deal (well the itty bitty jquery script) for
anyone else that is looking for something similiar to put rss feeds in their
website. the cool thing is that with the latest version of jquery this works
with remote urls. In the past I had to grab the file locally on my domain.

Have to give credit to Jim Davis since I found his post on the topic
earlier.
http://www.nabble.com/RSS-Feed-Reader---Re-visit-tf1915606.html#a5244340







var html = '';
// count for lines display
var items_count = 10;
// feed location
var feed = 'http://rss.movies.yahoo.com/dvd/topsellers.xml'; 
// replace url for link
var u =
'mainitem.html?hdSearchType=Catalog&radCateg=DVD&selSearchOption=Begins&selSortType=descr&chkDetailView=off&txtSearch='

$(document).ready(function(){
  $.get(feed, function(xml){
  $("item", xml).lt(10).each(function(){
  $(this).find("item").each(function(){
  html += "";
  }).end().find("title").each(function(){
  html += " " + u + this.text + " " + this.text + "

"; }); }); $("#rss").html(html).slideDown("slow"); }); }); Loading... -- View this message in context: http://www.nabble.com/specifying-count-for-rss-feed-display-with-each-function-tf3269015.html#a9091666 Sent from the JQuery mailing list archive at Nabble.com. ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/

Re: [jQuery] specifying count for rss feed display with each function

2007-02-21 Thread John W

Just thought Id post the full deal (well the itty bitty jquery script) for
anyone else that is looking for something similiar to put rss feeds in their
website. the cool thing is that with the latest version of jquery this works
with remote urls. In the past I had to grab the file locally on my domain.

Have to give credit to Jim Davis since I found his post on the topic
earlier.
http://www.nabble.com/RSS-Feed-Reader---Re-visit-tf1915606.html#a5244340







var html = '';
// count for lines display
var items_count = 10;
// feed location
var feed = 'http://rss.movies.yahoo.com/dvd/topsellers.xml'; 
// replace url for link
var u =
'mainitem.html?hdSearchType=Catalog&radCateg=DVD&selSearchOption=Begins&selSortType=descr&chkDetailView=off&txtSearch='

$(document).ready(function(){
  $.get(feed, function(xml){
  $("item", xml).lt(10).each(function(){
  $(this).find("item").each(function(){
  html += "";
  }).end().find("title").each(function(){
  html += " " + u + this.text + " " + this.text + "

"; }); }); $("#rss").html(html).slideDown("slow"); }); }); Loading... -- View this message in context: http://www.nabble.com/specifying-count-for-rss-feed-display-with-each-function-tf3269015.html#a9091665 Sent from the JQuery mailing list archive at Nabble.com. ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/

Re: [jQuery] Gmail-style updates

2007-02-21 Thread Blair Mitchelmore
It might be better if you didn't use an anonymous function so you could 
reference it multiple times. (I'm going to use a plugin I wrote that 
jQuerizizes timer events cause it really simplifies the syntax of the 
solution but something equivalent could be done without it.)

Example:
var fn = function(e) {
if (e.type == 'blur') $(this).stop();
// Do stuff
}
$(whatever).blur(fn).keyup(function() {
$(this).once(2000,fn);
}).keydown(function() {
$(this).stop();
});

Hope that helps.

-blair

Daemach wrote:
> I have a form with which I want to do ajax updates as they type.  If they
> stop typing for more than 2 seconds it should update the field.  If the
> field blurs before the 2 seconds are up it should update the field.  
>
> I have the ajax side of it worked out, and currently the updates work
> properly when the field blurs.  I just need some ideas on how to write the
> timer function for the keypresses and how it integrates with the blur
> function so the function doesn't get called twice and so there are no memory
> leaks from timers set then abandoned because the blur event got to it first.
>
> I'm going for elegance here :)  I could write an outside function that gets
> called from both event handlers but that seems cheezy.  There must be a way
> to do this with an anonymous function...


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] How to add event handler to XMLHttpRequest.onreadystatechange?

2007-02-21 Thread George Adamson

Hi folks,

Anyone know if it is possible to add a custom event handler for the
onreadystatechange events of JQuery AJAX calls?

I'm accessing a url that is slow to complete but does add to its output as
it progresses.
It would be nice to be able to catch each new fragment to inform the user of
progress.

I've experimented with the 'beforeSend' ajax argument to fiddle with the
XMLHttpRequest object's properties before making the ajax call but had no
luck.

Many thanks,

George
-- 
View this message in context: 
http://www.nabble.com/How-to-add-event-handler-to-XMLHttpRequest.onreadystatechange--tf3270003.html#a9091489
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Introduction and Masked Input Plugin

2007-02-21 Thread Kristinn Sigmundsson
this is something that I did for a friend not to long ago:

jQuery.fn.paste = function(func) {
if (typeof func == "function") {
jQuery(this).each( function () {
if ($.browser.msie) {
this.onpaste= function() {

setTimeout(func+"(this)", 100);
};
$(this).bind('keyup', 
function(e) {
func(this);
});
}
else if ($.browser.mozilla) {
this.addEventListener('input', 
function() {
func(this);
}, false);
}
});
}
}

it only needed to support FF and IE, so that's what it supports right
now... I don't know if there are similar events for non mozilla
browser that can be added, but you could start with this and see what
you could make of it.

you call it with $(obj).paste(callback), pretty straightforward, the
callback gets passed the object thats changed... hope it helps, oh and
awesome plugin, I might use that in the near future. Thanks!

//Kristinn

On 2/21/07, Jonathan Freeman <[EMAIL PROTECTED]> wrote:
> Very slick plugin, I will for sure use this on my next application. An
> enhancement might be to provide a elegant way of handling non fixed length
> numbers, such as currency inputs. So I guess its not so much masking, but
> pattern matching.
>
> $("#amount").maskedinput("999,999.99");
>
> Nice job!
>
>
>
> --- mrcarxpert <[EMAIL PROTECTED]> wrote:
>
> >
> > So I'm reading that FF, Opera, and Safari support the
> > DOMCharacterDataModified event.  I'll try to look into this further to
> > produce something to handle pastes.  I've never messed with this event
> > before, so I'm just shooting the dark here.  Any direction from the
> > crowd?
> >
> > Josh
> >
> >
> > John Resig wrote:
> > >
> > > This is so awesome. I love how the backspace key forces you into the
> > > correct
> > > space.
> > >
> > > The tricky bit, that I found, is that if you paste in a block of text
> > > (either correct, or incorrect) or if the browser's autocomplete fills
> > in
> > > an
> > > incorrect value it doesn't "correct" it until you hit another key
> > inside
> > > the
> > > field.
> > >
> > > Offhand, I think the best way to "solve" this is to have a
> > > setInterval(...)
> > > check the fields at a specified rate (a couple times a second? or
> > whatever
> > > seems reasonable). This should solve both issues.
> > >
> > > Again, this is really really great, I'll be putting this into place,
> > like,
> > > tomorrow.
> > >
> > > --John
> > >
> > > On 2/13/07, mrcarxpert <[EMAIL PROTECTED]> wrote:
> > >>
> > >>
> > >> Hello everyone.  I just wanted to take this opportunity to introduce
> > >> myself
> > >> and start giving back to the community.
> > >>
> > >> I've been using jQuery for about 6 months now, and in the process
> > I've
> > >> produced a few plugins.  As I clean up the code in these I will be
> > >> releasing
> > >> them.  The first of which is a masked input plugin for
> > dates,SSNs,phone
> > >> numbers, etc.
> > >>
> > >> I've made the source code and examples for this project available at
> > >> http://digitalbush.com/projects/masked-input-plugin
> > >> http://digitalbush.com/projects/masked-input-plugin .
> > >>
> > >> I've tested this in Firefox and IE7 with the latest jQuery library.
> > If
> > >> you
> > >> don't mind I'd like to get some feedback on the plugin and how I can
> > make
> > >> it
> > >> better.  I'd also like to know if there are any problems on other
> > >> platforms.
> > >>
> > >> Since this is my first plugin I'm sure I'm missing a few things, but
> > I
> > >> tried
> > >> to follow the patterns from some other plugins on the jQuery site.
> > One
> > >> thing I know I'm missing is, what's the best way to ensure that this
> > >> masking
> > >> is only applied to a text input?  Right now my code returns
> > this.each(
> > >> /*code*/), but I'm guessing I might want to
> > >> this.find("[EMAIL PROTECTED]'text']").each(/*code*/).  What is the most
> > >> elegant
> > >> way to do this?
> > >>
> > >> Anyway, I look forward to some feedback.  I'll consider myself
> > formally
> > >> introduced. :)
> > >>
> > >> Josh
> > >> --
> > >> View this message in context:
> > >>
> >
> http://www.nabble.com/Introduction-and-Masked-Input-Plugin-tf3224850.html#a8957581
> > >> Sent from the JQuery mailing list archive at Nabble.com.
> > >>
> > >>
> > >> ___

Re: [jQuery] jQuery and Jack Slocum's Ext

2007-02-21 Thread Sam Collett
On 21/02/07, Mark D. Lincoln <[EMAIL PROTECTED]> wrote:
> Sam,
>
> If you are going to use rich components like those found in Ext, does this
> matter?  I am looking at porting large parts of rich client application
> functionality to the Web and if a user has scripting disabled, the
> application will not work anyway.
>
> Mark D. Lincoln
>
> Mark D. Lincoln, Director of Research & Development
> Eye On Solutions, LLC
> (866) 253-9366x101
> www.eyeonsolutions.com

If it is an application where JavaScript is a requirement for the user
(i.e. you know what the users browser will be and do not need to worry
about accessibility), then it is not a problem.

One thing I can think of that could degrade is a table of data (e.g.
results from a search, or a list of contacts to edit) that simply is
processed on the server (e.g. by clicking page links, edit buttons,
sorting the results etc) if JavaScript is off and on the client AJAX
if it is on.

Also, the back button may not work as the user expects - i.e. they
search for something, then click back to get what was there before. Or
when bookmarking a page, they don't get the same thing when the use
the bookmark at a later date. I don't know if Ext is capable of this
(I haven't really looked into it in that level of detail).


>
>
> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On
> Behalf Of Sam Collett
> Sent: Wednesday, February 21, 2007 5:53 AM
> To: jQuery Discussion.
> Subject: Re: [jQuery] jQuery and Jack Slocum's Ext
>
> On 20/02/07, Jörn Zaefferer <[EMAIL PROTECTED]> wrote:
> > John Resig schrieb:
> > > Hi Everyone -
> > >
> > > Today, we're proud to announce that the jQuery Project and Jack
> > > Slocum's Ext Project, have partnered to integrate the amazingly
> > > lightweight and powerful jQuery framework with Ext's awesome UI
> > > library. This collaboration will greatly enhance the capabilities of
> > > both projects and expand the functionality available to developers
> > > using the jQuery JavaScript Library and the Ext UI component suite.
> > >
> > For anyone wondering if any jQuery plugins will be replaced by Ext
> > components: While that is possible, there are still good reasons to use
> > jQuery plugins. Most are very lightweight, easy to customize and extend,
> > and most important: unobtrusive. So if you are looking for something to
> > use on a "normal" website, jQuery's plugins are a good choice. If you
> > are looking for components for a rich web application, Ext components
> > offer a much richer experience.
> >
> > I'm looking forward to the first Ext-release with jQuery.
> >
> > --
> > Jörn Zaefferer
> >
> > http://bassistance.de
>
> Can they even be used in a way to degrade nicely? All the examples I
> have looked have don't have a fall-back if you disable JavaScript.
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Text looks choppy in IE7 with Opacity

2007-02-21 Thread David
Hi,

I fixed this in a previous project by applying a background-image rather
than a background-color. I just checked it in IE7 and the text still
appears to be fading in/out smoothly.

Regards,

David

Brandon Aaron wrote:
> This bug used to be fixable by applying a background color but not
> anymore (that I know of anyways).
>
> --
> Brandon Aaron
>
> On 2/21/07, Klaus Hartl <[EMAIL PROTECTED]> wrote:
>   
>> Rey Bango schrieb:
>> 
>>> Hey all,
>>>
>>> Have a buddy of mine thats having an issue and he asked if I can help.
>>>
>>> Here's what he said:
>>>
>>> "Only problem I have had with jQuery is regarding opacity changes with
>>> the hide/show effects in IE7 with cleartype in XP. It makes the text
>>> look choppy after any sort of opacity change on the parent element. Have
>>> tryed to find a solution but with no success."
>>>
>>> You can see it here:
>>>
>>> http://down2night.com/seattle
>>>
>>> Just click on the "What's Down?" button to show the slider results.
>>>
>>> When you swap between FireFox and IE7 and you'll see how the text is choppy.
>>>
>>> Any suggestions?
>>>
>>> Rey...
>>>   
>> Isn't that the bug, that can be fixed by applying a background color to
>> the element that gets its opacity changed?
>>
>>
>> -- Klaus
>>
>>
>> ___
>> jQuery mailing list
>> discuss@jquery.com
>> http://jquery.com/discuss/
>>
>> 
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>
>
>
>   
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Text looks choppy in IE7 with Opacity

2007-02-21 Thread Joel Birch
On 22/02/2007, at 9:26 AM, Mike Alsup wrote:
>> This bug used to be fixable by applying a background color but not
>> anymore (that I know of anyways).
>
> Not that I know of either (but I want to know!)  I had this problem
> with the tabs plugin in ie7 and had to chop some stuff out to get
> around it.
>
> Mike

I also bumped up against the problem with the tabs plugin when  
developing my Income Solutions site. I tried everything. I don't  
think even doing away with animation helped as merely showing/hiding  
triggered the problem. I think I ended up tolerating it - at some  
point you still have to say "to hell with bad browsers". It still  
makes me sad though.

Joel.

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Text looks choppy in IE7 with Opacity

2007-02-21 Thread Joel Birch
On 22/02/2007, at 8:54 AM, Rey Bango wrote:

> Thats what I think Brandon was mentioning.
>
> Rey
>
> Klaus Hartl wrote:
>> Rey Bango schrieb:
>>> Hey all,
>>>
>>> Have a buddy of mine thats having an issue and he asked if I can  
>>> help.
>>>
>>> Here's what he said:
>>>
>>> "Only problem I have had with jQuery is regarding opacity changes  
>>> with
>>> the hide/show effects in IE7 with cleartype in XP. It makes the text
>>> look choppy after any sort of opacity change on the parent  
>>> element. Have
>>> tryed to find a solution but with no success."
>>>
>>> You can see it here:
>>>
>>> http://down2night.com/seattle
>>>
>>> Just click on the "What's Down?" button to show the slider results.
>>>
>>> When you swap between FireFox and IE7 and you'll see how the text  
>>> is choppy.
>>>
>>> Any suggestions?
>>>
>>> Rey...
>>
>> Isn't that the bug, that can be fixed by applying a background  
>> color to
>> the element that gets its opacity changed?
>>
>>
>> -- Klaus
>>

I was caught by this infuriating issue last year. My take on the  
matter is discussed in this thread:

http://www.nabble.com/How-I-use-jQuery-tf2613276.html#a7298722

I don't believe there is a solution. The "fix" MicroSoft applied for  
the "no background" problem is, in my opinion, worse than the  
original problem. At least with IE6 you *could* add a background as a  
workaround.

Joel.



___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Big problem with FF2, flickering on all animate effect

2007-02-21 Thread Sanyi

Sorry, fucking Gmail...

I would like to make a simple animation effect:
1. hide a Div
2. load content into div (picture)
3. show Div with new picture

by step 3 the picture is showing for a short time and animation appears.

I tried a lot of animation effects and plugins, but this always happens.
I slowly begin to be very anry about it. I spent about 10 Hours to find a
solution but (I think) I missed something in JQuery.

You can see an example at:

http://gocsejinvesthu.w3h.hu/referencia1/index.html

when you click on the left lower corner on the Képek menu, there will appear
some Albums for the pictures, only the first will work (white color)

when you click after on the right showing symbol the next image will be
shown.

My Question is, how to use JQuery that the flickering by the next image
won't happen in FF2?

In IE it works fine.

When I hide the div that contains the picture and change the picture behind,
and let show with animation. The picture will be shown for a very short time
before the animation effect will happen.
As it would get an show() and a hide() effects right before the animatin
starts.

Thx in advance
Alex (Sanyi)

On 2/21/07, Sanyi <[EMAIL PROTECTED]> wrote:


Hi All,

I would like to make a simple animation effect:


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Text looks choppy in IE7 with Opacity

2007-02-21 Thread Mike Alsup
> This bug used to be fixable by applying a background color but not
> anymore (that I know of anyways).

Not that I know of either (but I want to know!)  I had this problem
with the tabs plugin in ie7 and had to chop some stuff out to get
around it.

Mike

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] release: treeview plugin 1.1

2007-02-21 Thread abba bryant

In my case it was more that the 2 trees weren't separated by enough
whitespace for me to realize they were separate. I just though the space
between one and the other was a rendering glitch.

My mistake. Great work as usual.
Abba


Jörn Zaefferer wrote:
> 
> abba bryant schrieb:
>> On the black and grey demo in ff 1.5 ( only browser I checked ) the
>> background art isn;t correct. There is a vertical gap in the art between
>> the
>> main nodes.
>>   
> That's intentional to demonstrate that multiple trees can be controlled 
> with one treecontrol ("two trees with one tree control, black and gray 
> image set").
> 
> I should have made the gap a bit bigger.
> 
> -- 
> Jörn Zaefferer
> 
> http://bassistance.de
> 
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/release%3A-treeview-plugin-1.1-tf3263448.html#a9090474
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] blockUI and CPU intensive form processing

2007-02-21 Thread Felix Geisendörfer
Why make it so complicated? Afaik if you give all your 
input[type=submit] buttons the same 'name' attribute but different 
'value's then the server will receive the data just like it would from a 
normal text input field, only that the 'value' of 'name' will equate to 
the button that was clicked.


-- Felix
--
http://www.thinkingphp.org
http://www.fg-webdesign.de


Jörn Zaefferer wrote:

RCS Computers schrieb:
  
Thank you.  That is actually what I am doing.  However, when I do that, 
I lose track of which button submitted the form (the server side code 
uses the button that was clicked to determine its action).  I am trying 
to work this out right now.
  

Ok. As there doesn't seem to be much of an alternative: Check the target 
property of the submit event. Maybe you can get the submit button from 
there, and create a hidden form field with name and value of that button.


  
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] Sortables: trouble editing a textfield that is a sortable

2007-02-21 Thread dalvarado
Hi, Let's say my web page consists solely of









Item 1

Item 3
Item 4
Item 5
Item 6
Item 7


$(document).ready(
function () {
$('#todoList').Sortable(
{
accept :'sidebarToDo',
helperclass :   'sorthelper',
activeclass :   'sortableactive',
hoverclass :'sortablehover',
opacity:0.8,
fx: 100,
axis:   'vertically',
opacity:0.4,
revert: true
}
)
}
);




On PC Firefox (haven't tested in IE), I'm having a problem trying to edit the 
value of the text field.  Whenever I focus my cursor on it, it treats it like 
I'm trying to move it and won't let me edit the field.  How can I adjust the 
above so I'm still able to edit that field?

Thanks, - Dave

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] blockUI and CPU intensive form processing

2007-02-21 Thread Mike Alsup
> A reference to the submitting element is temporarily stored on the
> form element in the 'clk' variable when using ajaxForm.

Oops, sorry.  When I was writing that I was thinking that ajaxForm was
being used.  Ignore me!

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Text looks choppy in IE7 with Opacity

2007-02-21 Thread Brandon Aaron
This bug used to be fixable by applying a background color but not
anymore (that I know of anyways).

--
Brandon Aaron

On 2/21/07, Klaus Hartl <[EMAIL PROTECTED]> wrote:
> Rey Bango schrieb:
> > Hey all,
> >
> > Have a buddy of mine thats having an issue and he asked if I can help.
> >
> > Here's what he said:
> >
> > "Only problem I have had with jQuery is regarding opacity changes with
> > the hide/show effects in IE7 with cleartype in XP. It makes the text
> > look choppy after any sort of opacity change on the parent element. Have
> > tryed to find a solution but with no success."
> >
> > You can see it here:
> >
> > http://down2night.com/seattle
> >
> > Just click on the "What's Down?" button to show the slider results.
> >
> > When you swap between FireFox and IE7 and you'll see how the text is choppy.
> >
> > Any suggestions?
> >
> > Rey...
>
> Isn't that the bug, that can be fixed by applying a background color to
> the element that gets its opacity changed?
>
>
> -- Klaus
>
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] blockUI and CPU intensive form processing

2007-02-21 Thread Felix Geisendörfer
Oh wait, this won't work since we are submitting the form manually. 
Ignore me as well and listen to Jörn!


-- Felix
--
http://www.thinkingphp.org
http://www.fg-webdesign.de


Felix Geisendörfer wrote:
Why make it so complicated? Afaik if you give all your 
input[type=submit] buttons the same 'name' attribute but different 
'value's then the server will receive the data just like it would from 
a normal text input field, only that the 'value' of 'name' will equate 
to the button that was clicked.


-- Felix
--
http://www.thinkingphp.org
http://www.fg-webdesign.de


Jörn Zaefferer wrote:

RCS Computers schrieb:
  
Thank you.  That is actually what I am doing.  However, when I do that, 
I lose track of which button submitted the form (the server side code 
uses the button that was clicked to determine its action).  I am trying 
to work this out right now.
  

Ok. As there doesn't seem to be much of an alternative: Check the target 
property of the submit event. Maybe you can get the submit button from 
there, and create a hidden form field with name and value of that button.


  
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] blockUI and CPU intensive form processing

2007-02-21 Thread Mike Alsup
> RCS Computers schrieb:
> > Thank you.  That is actually what I am doing.  However, when I do that,
> > I lose track of which button submitted the form (the server side code
> > uses the button that was clicked to determine its action).  I am trying
> > to work this out right now.
> >
> Ok. As there doesn't seem to be much of an alternative: Check the target
> property of the submit event. Maybe you can get the submit button from
> there, and create a hidden form field with name and value of that button.


A reference to the submitting element is temporarily stored on the
form element in the 'clk' variable when using ajaxForm.

Mike

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] blockUI and CPU intensive form processing

2007-02-21 Thread Jörn Zaefferer
RCS Computers schrieb:
> Thank you.  That is actually what I am doing.  However, when I do that, 
> I lose track of which button submitted the form (the server side code 
> uses the button that was clicked to determine its action).  I am trying 
> to work this out right now.
>   
Ok. As there doesn't seem to be much of an alternative: Check the target 
property of the submit event. Maybe you can get the submit button from 
there, and create a hidden form field with name and value of that button.

-- 
Jörn Zaefferer

http://bassistance.de


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Applyng classes to table rows?

2007-02-21 Thread rolfsf

of course - that's why I posted it. I've gotten a lot of help from this
community so it's nice to have a chance to help someone else.

I suspect you can still accomplish what you're doing by adding a function
that hides the siblings of the tr with the id or class that you want
collapsed. 

r.


Shane Graber - jQuery wrote:
> 
> Holy smoke, that's almost exactly what I'm trying to do.  The only
> thing I'm wanting to do different is to make certain table rows
> collapsed by default when the page is first viewed, which is why I am
> applying classes to rows.
> 
> May I use your code a bit in what I'm working on?
> 
> Shane
> 
> On 2/21/07, rolfsf <[EMAIL PROTECTED]> wrote:
>>
>> sorry - wrong url
>> http://www.monkeypuzzle.net/testfiles/jquery/Accordion_table/index_2.html
>>
>> Rolf
>>
>>
>>
>> rolfsf wrote:
>> >
>> > I could be wrong, but it sounds like you're trying to do something very
>> > similar to what I was working on yesterday - collapsing a set of rows
>> by
>> > clicking on another row. You can see what I did (I didn't have to add
>> any
>> > classes to the rows I was collapsing) :
>> > http://www.monkeypuzzle.net/testfiles/jquery/Accordion_table/
>> >
>> > Rolf
>> >
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Applyng-classes-to-table-rows--tf3267824.html#a9087379
>> Sent from the JQuery mailing list archive at Nabble.com.
>>
>>
>> ___
>> jQuery mailing list
>> discuss@jquery.com
>> http://jquery.com/discuss/
>>
> 
> 
> -- 
> -
> Bender: "Amy, you like cute things so I baked you a pony."
> -
> 
> http://www.reefs.org - Where reefkeeping begins on the internet.
> http://www.advancedaquarist.com - High quality, free monthly publication
> for
> the reef keeping hobbyist.
> http://www.aquaristcourses.org - Distance learning courses for the
> marine aquarist.
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Applyng-classes-to-table-rows--tf3267824.html#a9088072
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Text looks choppy in IE7 with Opacity

2007-02-21 Thread Rey Bango
Thats what I think Brandon was mentioning.

Rey

Klaus Hartl wrote:
> Rey Bango schrieb:
>> Hey all,
>>
>> Have a buddy of mine thats having an issue and he asked if I can help.
>>
>> Here's what he said:
>>
>> "Only problem I have had with jQuery is regarding opacity changes with 
>> the hide/show effects in IE7 with cleartype in XP. It makes the text 
>> look choppy after any sort of opacity change on the parent element. Have
>> tryed to find a solution but with no success."
>>
>> You can see it here:
>>
>> http://down2night.com/seattle
>>
>> Just click on the "What's Down?" button to show the slider results.
>>
>> When you swap between FireFox and IE7 and you'll see how the text is choppy.
>>
>> Any suggestions?
>>
>> Rey...
> 
> Isn't that the bug, that can be fixed by applying a background color to 
> the element that gets its opacity changed?
> 
> 
> -- Klaus
> 
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Text looks choppy in IE7 with Opacity

2007-02-21 Thread Klaus Hartl
Rey Bango schrieb:
> Hey all,
> 
> Have a buddy of mine thats having an issue and he asked if I can help.
> 
> Here's what he said:
> 
> "Only problem I have had with jQuery is regarding opacity changes with 
> the hide/show effects in IE7 with cleartype in XP. It makes the text 
> look choppy after any sort of opacity change on the parent element. Have
> tryed to find a solution but with no success."
> 
> You can see it here:
> 
> http://down2night.com/seattle
> 
> Just click on the "What's Down?" button to show the slider results.
> 
> When you swap between FireFox and IE7 and you'll see how the text is choppy.
> 
> Any suggestions?
> 
> Rey...

Isn't that the bug, that can be fixed by applying a background color to 
the element that gets its opacity changed?


-- Klaus


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] blockUI and CPU intensive form processing

2007-02-21 Thread Felix Geisendörfer
Oh boy I got to get some sleep. Put the unbind comment in the if 
statement checking the validation results and probably declare the 
retval variable in the local scope of that closure - that should work.


Sorry for spamming the list : /.

-- Felix
--
http://www.thinkingphp.org
http://www.fg-webdesign.de

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] blockUI and CPU intensive form processing

2007-02-21 Thread RCS Computers
Thank you.  That is actually what I am doing.  However, when I do that, 
I lose track of which button submitted the form (the server side code 
uses the button that was clicked to determine its action).  I am trying 
to work this out right now.

--
Randy Syring
RCS Computers & Web Solutions
502-644-4776
http://www.rcs-comp.com

"Whether, then, you eat or drink or 
whatever you do, do all to the glory
of God." 1 Cor 10:31



Jörn Zaefferer wrote:
> RCS Computers schrieb:
>> Notice that I use the return value of checkForm to stop submission of 
>> the form if there are invalid values.  Using the timeout function 
>> seems to break this as the form is always being submitted.  How do I 
>> get the results of retval back from the setTimeout() function?
> You could always return false to stop the normal submit and then 
> trigger the submit again when the form is valid.
>

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Big problem with FF2, flickering on all animate effect

2007-02-21 Thread Brandon Aaron
This issue has been resolved since 1.1.1 release. Please update to the
latest SVN or grab one of the nightlies
http://jquery.com/src/nightlies/.

--
Brandon Aaron

On 2/21/07, Sanyi <[EMAIL PROTECTED]> wrote:
> Hi All,
>
> I would like to make a simple animation effect:
>
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>
>

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] blockUI and CPU intensive form processing

2007-02-21 Thread Felix Geisendörfer
Just noticed two issues with the code I send you. One was that you had 
an 'return' in front of the setTimeout function which will return the 
timer reference and cause the callbackClosure to not return false. The 
other was that I didn't really have to bind/unbind for each validation 
attempt, but only unbind once if the validation was successful.


See if that works for you:

// when submitting the form, check the values to make sure they are numeric
$("#lePlanForm").submit(function() {
   var retval;
  
   // Give the user a processing message

   $.blockUI();

   var form = this;

   setTimeout(function()
   {
   retval = checkForm();

   // Undo the processing message

   $.unblockUI();
 
   jQuery(form).unbind('submit');

   if (retval==true)
   {
   form.submit();
   }
   }, 10);

   return false;
});


-- Felix
--
http://www.thinkingphp.org
http://www.fg-webdesign.de


RCS Computers wrote:

Felix,

Thank you, that did indeed give blockUI enough time to bring up the 
message.  However, it created another problem.


// when submitting the form, check the values to make sure they 
are numeric

$("#lePlanForm").submit(function() {
var retval;
 
// Give the user a processing message

$.blockUI();
   
return setTimeout(function()

{
*retval = checkForm();*
   
// Undo the processing message

$.unblockUI();
}, 10);
   
return retval;

});

Notice that I use the return value of checkForm to stop submission of 
the form if there are invalid values.  Using the timeout function 
seems to break this as the form is always being submitted.  How do I 
get the results of retval back from the setTimeout() function?


Thanks.
--
Randy Syring
RCS Computers & Web Solutions
502-644-4776
http://www.rcs-comp.com

"Whether, then, you eat or drink or 
whatever you do, do all to the glory

of God." 1 Cor 10:31
  



Felix Geisendörfer wrote:
I've just looked at this real quick, but would something like this 
maybe work:



|$.blockUI(messageElement); |

setTimeout(function()
{
|retval = checkForm();

||$.unblockUI(); |
|}, 100);
|
|
|It should give blockUI some time to come up before the current 
thread get's pinned.


-- Felix Geisendörfer aka the_undefined
--
http://www.thinkingphp.org
http://www.fg-webdesign.de


Mike Alsup wrote:

That's a problem.  I see what you're doing, and I understand why
you're doing it, but I don't know of any way to force the browser to
render changes while you've got the current thread pinned.  You really
need async behavior to make this work, but that's not an option for
you in your use case.

I don't have an answer for this.  Anyone have any ideas?

Mike


On 2/21/07, RCS Computers <[EMAIL PROTECTED]> wrote:
  

 Basically, I have some CPU intensive form validation that takes about 3
seconds to complete. I would like blockUI to start before the form
processing and stop after the form processing. However, the blockUI message
doesn't ever show up. When I comment out $.unblockUI(), the blockUI message
shows up AFTER the form processing is completed. Code can be found here (57
lines):

 http://sh.nu/p/9301

 I can arrange for the full HTML and JS if needed.
 --
--
Randy Syring
RCS Computers & Web Solutions
502-644-4776
http://www.rcs-comp.com

"Whether, then, you eat or drink or
whatever you do, do all to the glory
of God." 1 Cor 10:31


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/





___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/

  



___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/
  



___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/
  
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] blockUI and CPU intensive form processing

2007-02-21 Thread Jörn Zaefferer
RCS Computers schrieb:
> Notice that I use the return value of checkForm to stop submission of 
> the form if there are invalid values.  Using the timeout function 
> seems to break this as the form is always being submitted.  How do I 
> get the results of retval back from the setTimeout() function?
You could always return false to stop the normal submit and then trigger 
the submit again when the form is valid.

-- 
Jörn Zaefferer

http://bassistance.de


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Text looks choppy in IE7 with Opacity

2007-02-21 Thread Brandon Aaron
This Microsoft's solution to the previous issue of using opacity with
clear-type text and it looking *REALLY* bad without a background
color. When you set an opacity or any other filter the clear-type is
removed. Sucks...

--
Brandon Aaron

On 2/21/07, Rey Bango <[EMAIL PROTECTED]> wrote:
> Hey all,
>
> Have a buddy of mine thats having an issue and he asked if I can help.
>
> Here's what he said:
>
> "Only problem I have had with jQuery is regarding opacity changes with
> the hide/show effects in IE7 with cleartype in XP. It makes the text
> look choppy after any sort of opacity change on the parent element. Have
> tryed to find a solution but with no success."
>
> You can see it here:
>
> http://down2night.com/seattle
>
> Just click on the "What's Down?" button to show the slider results.
>
> When you swap between FireFox and IE7 and you'll see how the text is choppy.
>
> Any suggestions?
>
> Rey...
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] blockUI and CPU intensive form processing

2007-02-21 Thread Felix Geisendörfer
Well you are now making your form processing somewhat asynchronous, at 
least to the degree that your submit event handler function will return 
before the actual form validation starts. Fixing this should would 
probably look like this:


---
// when submitting the form, check the values to make sure they are numeric
$("#lePlanForm").submit(function() {
   var retval;
   
   // Give the user a processing message

   $.blockUI();
 
   var form = jQuery(form).unbind('submit')[0];

   var callbackClosure = arguments.callee;
 
   return setTimeout(function()

   {
   retval = checkForm();
 
   // Undo the processing message

   $.unblockUI();
  
   if (retval==true)

   {
   form.submit();
   }
   else
   {
   form.bind('submit', callbackClosure);
   }  
   }, 10);
 
   return false;

});
---

The basic idea is to always cancel the form submition per default. Then 
when the now semi-asynchronous checkForm function has finished we decide 
if we still want to submit the form or if validation has failed. Also 
note that you have to unbind the 'submit' event before manually 
submitting the form after validation as this would probably cause an 
endless loop.


Let me know if this works,
-- Felix
--
http://www.thinkingphp.org
http://www.fg-webdesign.de


RCS Computers wrote:

Felix,

Thank you, that did indeed give blockUI enough time to bring up the 
message.  However, it created another problem.


// when submitting the form, check the values to make sure they 
are numeric

$("#lePlanForm").submit(function() {
var retval;
 
// Give the user a processing message

$.blockUI();
   
return setTimeout(function()

{
*retval = checkForm();*
   
// Undo the processing message

$.unblockUI();
}, 10);
   
return retval;

});

Notice that I use the return value of checkForm to stop submission of 
the form if there are invalid values.  Using the timeout function 
seems to break this as the form is always being submitted.  How do I 
get the results of retval back from the setTimeout() function?


Thanks.
--
Randy Syring
RCS Computers & Web Solutions
502-644-4776
http://www.rcs-comp.com

"Whether, then, you eat or drink or 
whatever you do, do all to the glory

of God." 1 Cor 10:31
  



Felix Geisendörfer wrote:
I've just looked at this real quick, but would something like this 
maybe work:



|$.blockUI(messageElement); |

setTimeout(function()
{
|retval = checkForm();

||$.unblockUI(); |
|}, 100);
|
|
|It should give blockUI some time to come up before the current 
thread get's pinned.


-- Felix Geisendörfer aka the_undefined
--
http://www.thinkingphp.org
http://www.fg-webdesign.de


Mike Alsup wrote:

That's a problem.  I see what you're doing, and I understand why
you're doing it, but I don't know of any way to force the browser to
render changes while you've got the current thread pinned.  You really
need async behavior to make this work, but that's not an option for
you in your use case.

I don't have an answer for this.  Anyone have any ideas?

Mike


On 2/21/07, RCS Computers <[EMAIL PROTECTED]> wrote:
  

 Basically, I have some CPU intensive form validation that takes about 3
seconds to complete. I would like blockUI to start before the form
processing and stop after the form processing. However, the blockUI message
doesn't ever show up. When I comment out $.unblockUI(), the blockUI message
shows up AFTER the form processing is completed. Code can be found here (57
lines):

 http://sh.nu/p/9301

 I can arrange for the full HTML and JS if needed.
 --
--
Randy Syring
RCS Computers & Web Solutions
502-644-4776
http://www.rcs-comp.com

"Whether, then, you eat or drink or
whatever you do, do all to the glory
of God." 1 Cor 10:31


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/





___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/

  



___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/
  



___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/
  
___
jQuery mailing list
discu

[jQuery] Big problem with FF2, flickering on all animate effect

2007-02-21 Thread Sanyi

Hi All,

I would like to make a simple animation effect:
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Gmail-style updates

2007-02-21 Thread Daemach

In what context does the timer run?  Each field will have its own timer/ajax
function.  If I have multiple text fields, and people are typing and tabbing
through them quickly the updates still need to happen reliably.

Currently it works like this:

$(document).ready( function() { 
$('[EMAIL PROTECTED]').each( function() {
$(this).blur( function() {
$.AjaxCFC({url: "/namechangedtoprotecttheinnocent.cfc", 
method:
"updateAttendee", data:
{fid:this.id,field:this.id.split("_")[0],id:this.id.split("_")[1],value:this.value},
success: function(r){$('#'+r).css("backgroundColor","#ddFFdd");}});
$(this).css("backgroundColor","#FF");
});
});
}); 



Jörn Zaefferer wrote:
> 
> Daemach schrieb:
>> I have a form with which I want to do ajax updates as they type.  If they
>> stop typing for more than 2 seconds it should update the field.  If the
>> field blurs before the 2 seconds are up it should update the field.  
>>
>> I have the ajax side of it worked out, and currently the updates work
>> properly when the field blurs.  I just need some ideas on how to write
>> the
>> timer function for the keypresses and how it integrates with the blur
>> function so the function doesn't get called twice and so there are no
>> memory
>> leaks from timers set then abandoned because the blur event got to it
>> first.
>>
>> I'm going for elegance here :)  I could write an outside function that
>> gets
>> called from both event handlers but that seems cheezy.  There must be a
>> way
>> to do this with an anonymous function...
>>   
> Well, sounds like you need to start a timeout on keyup/press and clear 
> that with the blur function, in case it is still running. So you need 
> the timeout id and a updated-flag.
> 
> Hope that helps.
> 
> -- 
> Jörn Zaefferer
> 
> http://bassistance.de
> 
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Gmail-style-updates-tf3269331.html#a9089663
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] Text looks choppy in IE7 with Opacity

2007-02-21 Thread Rey Bango
Hey all,

Have a buddy of mine thats having an issue and he asked if I can help.

Here's what he said:

"Only problem I have had with jQuery is regarding opacity changes with 
the hide/show effects in IE7 with cleartype in XP. It makes the text 
look choppy after any sort of opacity change on the parent element. Have
tryed to find a solution but with no success."

You can see it here:

http://down2night.com/seattle

Just click on the "What's Down?" button to show the slider results.

When you swap between FireFox and IE7 and you'll see how the text is choppy.

Any suggestions?

Rey...

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Gmail-style updates

2007-02-21 Thread Jörn Zaefferer
Daemach schrieb:
> I have a form with which I want to do ajax updates as they type.  If they
> stop typing for more than 2 seconds it should update the field.  If the
> field blurs before the 2 seconds are up it should update the field.  
>
> I have the ajax side of it worked out, and currently the updates work
> properly when the field blurs.  I just need some ideas on how to write the
> timer function for the keypresses and how it integrates with the blur
> function so the function doesn't get called twice and so there are no memory
> leaks from timers set then abandoned because the blur event got to it first.
>
> I'm going for elegance here :)  I could write an outside function that gets
> called from both event handlers but that seems cheezy.  There must be a way
> to do this with an anonymous function...
>   
Well, sounds like you need to start a timeout on keyup/press and clear 
that with the blur function, in case it is still running. So you need 
the timeout id and a updated-flag.

Hope that helps.

-- 
Jörn Zaefferer

http://bassistance.de


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] blockUI and CPU intensive form processing

2007-02-21 Thread RCS Computers

Felix,

Thank you, that did indeed give blockUI enough time to bring up the 
message.  However, it created another problem.


   // when submitting the form, check the values to make sure they are 
numeric

   $("#lePlanForm").submit(function() {
   var retval;

   // Give the user a processing message

   $.blockUI();
  
   return setTimeout(function()

   {
   *retval = checkForm();*
  
   // Undo the processing message

   $.unblockUI();
   }, 10);
  
   return retval;

   });

Notice that I use the return value of checkForm to stop submission of 
the form if there are invalid values.  Using the timeout function seems 
to break this as the form is always being submitted.  How do I get the 
results of retval back from the setTimeout() function?


Thanks.

--
Randy Syring
RCS Computers & Web Solutions
502-644-4776
http://www.rcs-comp.com

"Whether, then, you eat or drink or 
whatever you do, do all to the glory

of God." 1 Cor 10:31



Felix Geisendörfer wrote:
I've just looked at this real quick, but would something like this 
maybe work:



|$.blockUI(messageElement); |

setTimeout(function()
{
|retval = checkForm();

||$.unblockUI(); |
|}, 100);
|
|
|It should give blockUI some time to come up before the current thread 
get's pinned.


-- Felix Geisendörfer aka the_undefined
--
http://www.thinkingphp.org
http://www.fg-webdesign.de


Mike Alsup wrote:

That's a problem.  I see what you're doing, and I understand why
you're doing it, but I don't know of any way to force the browser to
render changes while you've got the current thread pinned.  You really
need async behavior to make this work, but that's not an option for
you in your use case.

I don't have an answer for this.  Anyone have any ideas?

Mike


On 2/21/07, RCS Computers <[EMAIL PROTECTED]> wrote:
  

 Basically, I have some CPU intensive form validation that takes about 3
seconds to complete. I would like blockUI to start before the form
processing and stop after the form processing. However, the blockUI message
doesn't ever show up. When I comment out $.unblockUI(), the blockUI message
shows up AFTER the form processing is completed. Code can be found here (57
lines):

 http://sh.nu/p/9301

 I can arrange for the full HTML and JS if needed.
 --
--
Randy Syring
RCS Computers & Web Solutions
502-644-4776
http://www.rcs-comp.com

"Whether, then, you eat or drink or
whatever you do, do all to the glory
of God." 1 Cor 10:31


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/





___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/

  



___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/
  
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] Gmail-style updates

2007-02-21 Thread Daemach

I have a form with which I want to do ajax updates as they type.  If they
stop typing for more than 2 seconds it should update the field.  If the
field blurs before the 2 seconds are up it should update the field.  

I have the ajax side of it worked out, and currently the updates work
properly when the field blurs.  I just need some ideas on how to write the
timer function for the keypresses and how it integrates with the blur
function so the function doesn't get called twice and so there are no memory
leaks from timers set then abandoned because the blur event got to it first.

I'm going for elegance here :)  I could write an outside function that gets
called from both event handlers but that seems cheezy.  There must be a way
to do this with an anonymous function...
-- 
View this message in context: 
http://www.nabble.com/Gmail-style-updates-tf3269331.html#a9089305
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] dimensions.js lesson needed

2007-02-21 Thread rolfsf

Thanks Brandon, I'll look through the YUI grids...
While much of it can be done with css, I just don't see how I can get the
autoscroll to function properly unless I've set a fixed height and width,
which I can't think of how to do accurately with css on a flexible height
and width page. But... I'll go dig...



Brandon Aaron wrote:
> 
> I believe you are better off letting CSS deal with this. The
> performance of the CSS is going to greatly outweigh the JavaScript in
> this scenario. You should check out the YUI Grids CSS [1], maybe it
> can help you get what you need without too much overhead.
> 
> [1]: http://developer.yahoo.com/yui/grids/
> 
> --
> Brandon Aaron
> 
> On 2/21/07, rolfsf <[EMAIL PROTECTED]> wrote:
>>
>> I've got a basic layout that looks like this:
>>
>> 
>> 
>>   
>> 
>> 
>>
>> All divs are flexible in height and width depending on the viewport,
>> except
>> #leftPane, which has a fixed width.
>> I want to set:
>> #container width to be equal to viewport width
>> #container height to be equal to (viewport height - #top height)
>> #leftPane height to be equal to #container height
>> #rightPane height to be equal to #container  height
>> #leftPane width is equal to 300px;
>> #rightPane width to be equal to (#container width - #leftPane width)
>>
>> (what I'm trying to get to is to have #leftPane and #rightPane with
>> autoscroll, and have #rightPane expand when #leftPane slides left and
>> closes, and all divs adjust when the viewport is resized)
>>
>> My question: How do go about a) getting these dimensions, b) setting
>> dimensions based on a,  c) updating when the viewport is resized. Hints
>> are
>> appreciated!
>>
>>
>> --
>> View this message in context:
>> http://www.nabble.com/dimensions.js-lesson-needed-tf3269066.html#a9088452
>> Sent from the JQuery mailing list archive at Nabble.com.
>>
>>
>> ___
>> jQuery mailing list
>> discuss@jquery.com
>> http://jquery.com/discuss/
>>
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/dimensions.js-lesson-needed-tf3269066.html#a9089266
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] specifying count for rss feed display with each function

2007-02-21 Thread John W

Ahh I see.  THank you guys this really helps.  Jquery is great.



Karl Swedberg-2 wrote:
> 
> Hi John,
> 
> It works just like a "for" loop. You can put the "i" in the anonymous  
> function argument for .each(). For example:
> 
> $('p').each(function(index) {
>alert('This is paragraph number ' + index);
> });
> 
> (I used "index" instead of "i" because I'm kind of dense, and it  
> helps to remind me what it is).
> 
> 
> --Karl
> _
> Karl Swedberg
> www.englishrules.com
> www.learningjquery.com
> 
> 
> 
> On Feb 21, 2007, at 3:11 PM, john smith wrote:
> 
>> Sorry all Im still a newb to jquery. Ive been messing around with  
>> using jquery for grabbing and displaying rss feed info. A lot less  
>> code then using straight javascript. what Im not quite clear on is  
>> how you grab a specific count from doing an .each
>>
>> For example if I grab a feed with the jquery code below
>>
>> // count for lines display
>> var items_count = 10;
>>
>> // feed location
>> var feed = my.xml';
>>
>> // replace url for link
>> var u = 'http://www.mypage.html?txtSearch='
>>
>> $(document).ready(function(){
>>   $.get(feed, function(xml){
>>   $("item", xml).each(function(){
>>   $(this).find("item").each(function(){
>>   html += "";
>>   }).end().find("title").each(function(){
>>   html += " '" + u + this.text +  
  "'>" + this.text + " ";
>>   });
>>   });
>>   $("#feed").html(html).slideDown("slow");
>>
>>   });
>> });
>>
>> Using jquery how do I do a for each count like:
>> for(var i=0; i>
>> Access over 1 million songs - Yahoo! Music Unlimited.
>> ___
>> jQuery mailing list
>> discuss@jquery.com
>> http://jquery.com/discuss/
> 
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/specifying-count-for-rss-feed-display-with-each-function-tf3269015.html#a9089093
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] blockUI and CPU intensive form processing

2007-02-21 Thread Felix Geisendörfer
I've just looked at this real quick, but would something like this maybe 
work:



|$.blockUI(messageElement); |

setTimeout(function()
{
|retval = checkForm();

||$.unblockUI(); |
|}, 100);
|
|
|It should give blockUI some time to come up before the current thread 
get's pinned.


-- Felix Geisendörfer aka the_undefined
--
http://www.thinkingphp.org
http://www.fg-webdesign.de


Mike Alsup wrote:

That's a problem.  I see what you're doing, and I understand why
you're doing it, but I don't know of any way to force the browser to
render changes while you've got the current thread pinned.  You really
need async behavior to make this work, but that's not an option for
you in your use case.

I don't have an answer for this.  Anyone have any ideas?

Mike


On 2/21/07, RCS Computers <[EMAIL PROTECTED]> wrote:
  

 Basically, I have some CPU intensive form validation that takes about 3
seconds to complete. I would like blockUI to start before the form
processing and stop after the form processing. However, the blockUI message
doesn't ever show up. When I comment out $.unblockUI(), the blockUI message
shows up AFTER the form processing is completed. Code can be found here (57
lines):

 http://sh.nu/p/9301

 I can arrange for the full HTML and JS if needed.
 --
--
Randy Syring
RCS Computers & Web Solutions
502-644-4776
http://www.rcs-comp.com

"Whether, then, you eat or drink or
whatever you do, do all to the glory
of God." 1 Cor 10:31


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/





___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/

  
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] dimensions.js lesson needed

2007-02-21 Thread Brandon Aaron
I believe you are better off letting CSS deal with this. The
performance of the CSS is going to greatly outweigh the JavaScript in
this scenario. You should check out the YUI Grids CSS [1], maybe it
can help you get what you need without too much overhead.

[1]: http://developer.yahoo.com/yui/grids/

--
Brandon Aaron

On 2/21/07, rolfsf <[EMAIL PROTECTED]> wrote:
>
> I've got a basic layout that looks like this:
>
> 
> 
>   
> 
> 
>
> All divs are flexible in height and width depending on the viewport, except
> #leftPane, which has a fixed width.
> I want to set:
> #container width to be equal to viewport width
> #container height to be equal to (viewport height - #top height)
> #leftPane height to be equal to #container height
> #rightPane height to be equal to #container  height
> #leftPane width is equal to 300px;
> #rightPane width to be equal to (#container width - #leftPane width)
>
> (what I'm trying to get to is to have #leftPane and #rightPane with
> autoscroll, and have #rightPane expand when #leftPane slides left and
> closes, and all divs adjust when the viewport is resized)
>
> My question: How do go about a) getting these dimensions, b) setting
> dimensions based on a,  c) updating when the viewport is resized. Hints are
> appreciated!
>
>
> --
> View this message in context: 
> http://www.nabble.com/dimensions.js-lesson-needed-tf3269066.html#a9088452
> Sent from the JQuery mailing list archive at Nabble.com.
>
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Easiest way to add elements on the fly?

2007-02-21 Thread Karl Rudd
$(function(){
  $('#todoList').append( '' );
});

http://docs.jquery.com/DOM/Manipulation#append.28_content_.29

You might like to break the HTML into a string per line and join them
via +. For example:

'' +
  '' +
'' +
  etc...

Karl Rudd

On 2/22/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> Hi,
>
> If, after the document has fully loaded, I want to append a DIV to the end of 
> another DIV with id = "todoList", what is the easiest way to do that?  The 
> HTML code that I want to append is below ...
>
> 
> 
> 
>
> id="newItem">
> src="images/edit.gif" alt="Edit" border="0">
> src="images/deleteLink.gif" alt="Delete" border="0">
> 
> 
> 
>
> Thanks, - Dave
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] blockUI and CPU intensive form processing

2007-02-21 Thread Mike Alsup
That's a problem.  I see what you're doing, and I understand why
you're doing it, but I don't know of any way to force the browser to
render changes while you've got the current thread pinned.  You really
need async behavior to make this work, but that's not an option for
you in your use case.

I don't have an answer for this.  Anyone have any ideas?

Mike


On 2/21/07, RCS Computers <[EMAIL PROTECTED]> wrote:
>
>  Basically, I have some CPU intensive form validation that takes about 3
> seconds to complete. I would like blockUI to start before the form
> processing and stop after the form processing. However, the blockUI message
> doesn't ever show up. When I comment out $.unblockUI(), the blockUI message
> shows up AFTER the form processing is completed. Code can be found here (57
> lines):
>
>  http://sh.nu/p/9301
>
>  I can arrange for the full HTML and JS if needed.
>  --
> --
> Randy Syring
> RCS Computers & Web Solutions
> 502-644-4776
> http://www.rcs-comp.com
>
> "Whether, then, you eat or drink or
> whatever you do, do all to the glory
> of God." 1 Cor 10:31
>
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>
>

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Applyng classes to table rows?

2007-02-21 Thread Kristinn Sigmundsson
Ah, I re-read your post again... silly me, but glad you worked it out!

//Kristinn

On 2/21/07, Shane Graber - jQuery <[EMAIL PROTECTED]> wrote:
> Awesome!  Thanks for the code.  :)
>
> I agree, I should not set the id as id's are unique identifiers.  What
> I wanted to do was take the class name and id name from a previous  /> and combine them into a new class name like so:
>
> from:   class="row" id="blah-one"
> to: class="row blah-one"
>
> I modified your code a bit to achieve this.  Thank you!
>
> Shane
>
> On 2/21/07, Kristinn Sigmundsson <[EMAIL PROTECTED]> wrote:
> > this does it for the classes
> > $("table tr:not([EMAIL PROTECTED])").each(function() {
> > $(this).attr("class", $(this).prev("[EMAIL 
> > PROTECTED]").attr("class"));
> > });
> > you might be able to get it down to one row...
> >
> > I would not recommend setting the IDs as you want, because the
> > standars clearly states that IDs should be UNIQUE!
> >
> > //Kristinn
> >
> > On 2/21/07, Shane Graber - jQuery <[EMAIL PROTECTED]> wrote:
> > > I'm stumped on how to do this with jQuery.  I have a table like this:
> > >
> > > 
> > >
> > > 
> > > 
> > > 
> > > 
> > >
> > > 
> > > 
> > > 
> > > 
> > >
> > > 
> > > 
> > > 
> > > 
> > >
> > > 
> > > 
> > > 
> > > 
> > >
> > > 
> > > 
> > > 
> > > 
> > >
> > > 
> > > 
> > > 
> > > 
> > >
> > > 
> > >
> > > I need to convert it to:
> > >
> > > 
> > >
> > > 
> > > 
> > > 
> > > 
> > >
> > > 
> > > 
> > > 
> > > 
> > >
> > > 
> > > 
> > > 
> > > 
> > >
> > > 
> > > 
> > > 
> > > 
> > >
> > > 
> > > 
> > > 
> > > 
> > >
> > > 
> > > 
> > > 
> > > 
> > >
> > > 
> > >
> > > Basically, I want to look at each table row and if it does not have a
> > > class, I want to look up the table row by row till it finds a row that
> > > has a class and id set on it and then take that class and id and apply
> > > it to that row that does not have its class set.
> > >
> > > What I am attempting to do is to write a show/hide script for phpBB so
> > > that I can dynamically show/hide sections of the forum tree either
> > > collapsed or expanded.  So far I have been successful at applying a
> > > class and id to each table row section but not the rows directly
> > > beneath it yet.
> > >
> > > Any help would be appreciated.  Thanks!
> > >
> > > Shane
> > >
> > > --
> > > -
> > > Bender: "Amy, you like cute things so I baked you a pony."
> > > -
> > >
> > > http://www.reefs.org - Where reefkeeping begins on the internet.
> > > http://www.advancedaquarist.com - High quality, free monthly publication 
> > > for
> > > the reef keeping hobbyist.
> > > http://www.aquaristcourses.org - Distance learning courses for the
> > > marine aquarist.
> > >
> > > ___
> > > jQuery mailing list
> > > discuss@jquery.com
> > > http://jquery.com/discuss/
> > >
> >
> > ___
> > jQuery mailing list
> > discuss@jquery.com
> > http://jquery.com/discuss/
> >
>
>
> --
> -
> Bender: "Amy, you like cute things so I baked you a pony."
> -
>
> http://www.reefs.org - Where reefkeeping begins on the internet.
> http://www.advancedaquarist.com - High quality, free monthly publication for
> the reef keeping hobbyist.
> http://www.aquaristcourses.org - Distance learning courses for the
> marine aquarist.
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] specifying count for rss feed display with each function

2007-02-21 Thread Kristinn Sigmundsson
you can use the .lt() command before the .each to narrow the results,
so if you want the first 10, you would use something like
$(this).lt(10).each...

//Kristinn

On 2/21/07, john smith <[EMAIL PROTECTED]> wrote:
> Sorry all Im still a newb to jquery. Ive been messing around with using
> jquery for grabbing and displaying rss feed info. A lot less code then using
> straight javascript. what Im not quite clear on is how you grab a specific
> count from doing an .each
>
> For example if I grab a feed with the jquery code below
>
> // count for lines display
> var items_count = 10;
>
> // feed location
> var feed = my.xml';
>
> // replace url for link
> var u = 'http://www.mypage.html?txtSearch='
>
> $(document).ready(function(){
>   $.get(feed, function(xml){
>   $("item", xml).each(function(){
>   $(this).find("item").each(function(){
>   html += "";
>   }).end().find("title").each(function(){
>   html += "" +
> this.text + "";
>   });
>   });
>   $("#feed").html(html).slideDown("slow");
>
>   });
> });
>
> Using jquery how do I do a for each count like:
> for(var i=0; i
>  
> Access over 1 million songs - Yahoo! Music Unlimited.
>
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>
>

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] specifying count for rss feed display with each function

2007-02-21 Thread Karl Swedberg

Hi John,

It works just like a "for" loop. You can put the "i" in the anonymous  
function argument for .each(). For example:


$('p').each(function(index) {
  alert('This is paragraph number ' + index);
});

(I used "index" instead of "i" because I'm kind of dense, and it  
helps to remind me what it is).



--Karl
_
Karl Swedberg
www.englishrules.com
www.learningjquery.com



On Feb 21, 2007, at 3:11 PM, john smith wrote:

Sorry all Im still a newb to jquery. Ive been messing around with  
using jquery for grabbing and displaying rss feed info. A lot less  
code then using straight javascript. what Im not quite clear on is  
how you grab a specific count from doing an .each


For example if I grab a feed with the jquery code below

// count for lines display
var items_count = 10;

// feed location
var feed = my.xml';

// replace url for link
var u = 'http://www.mypage.html?txtSearch='

$(document).ready(function(){
  $.get(feed, function(xml){
  $("item", xml).each(function(){
  $(this).find("item").each(function(){
  html += "";
  }).end().find("title").each(function(){
  html += "" + this.text + "";

  });
  });
  $("#feed").html(html).slideDown("slow");

  });
});

Using jquery how do I do a for each count like:
for(var i=0; ihttp://jquery.com/discuss/


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] blockUI and CPU intensive form processing

2007-02-21 Thread RCS Computers

Thanks for the help.  Here you go:

http://rcs-comp.com/tmp/LaborEffPlanGrid.asp.htm

--
Randy Syring
RCS Computers & Web Solutions
502-644-4776
http://www.rcs-comp.com

"Whether, then, you eat or drink or 
whatever you do, do all to the glory

of God." 1 Cor 10:31



Benjamin Sterling wrote:

If we can take a look at the test page, that would be helpful.


--
Benjamin Sterling
http://www.KenzoMedia.com
http://www.KenzoHosting.com 
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] dimensions.js lesson needed

2007-02-21 Thread rolfsf

I've got a basic layout that looks like this:



  



All divs are flexible in height and width depending on the viewport, except
#leftPane, which has a fixed width. 
I want to set: 
#container width to be equal to viewport width
#container height to be equal to (viewport height - #top height)
#leftPane height to be equal to #container height 
#rightPane height to be equal to #container  height 
#leftPane width is equal to 300px;
#rightPane width to be equal to (#container width - #leftPane width)

(what I'm trying to get to is to have #leftPane and #rightPane with
autoscroll, and have #rightPane expand when #leftPane slides left and
closes, and all divs adjust when the viewport is resized)

My question: How do go about a) getting these dimensions, b) setting
dimensions based on a,  c) updating when the viewport is resized. Hints are
appreciated!


-- 
View this message in context: 
http://www.nabble.com/dimensions.js-lesson-needed-tf3269066.html#a9088452
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Loop Checkbox Action Question

2007-02-21 Thread Karl Rudd
I stand corrected. :) I did a quick search and couldn't find a
"normal" string in jQuery core so I assumed it would just default to
hide/show. I now see that "normal" defaults to using the fade-shrink /
fade-expand animation. Much smoother than the raw hide / show.

Karl Rudd

On 2/22/07, Karl Swedberg <[EMAIL PROTECTED]> wrote:
> Actually, "normal" is not default for .show() and .hide() -- even though it
> is the default for all the .slideX() methods and .fadeIn()/.fadeOut().
> Without a parameter, .show() and .hide() act differently -- just applying
> the display=none or display=block/inline to the matched set of elements. For
> them to use the animation, a parameter must be inlcluded.
>
>
> --Karl
> _
> Karl Swedberg
> www.englishrules.com
> www.learningjquery.com
>
>
>
>
>
> On Feb 21, 2007, at 7:01 AM, Gorkfu wrote:
>
>
> Thx, that does clean it up a lot. =)
>
> As for normal being default for show and hide, I think the default doesn't
> work correctly, or there is no default. Testing it blank in IE7 and
> Firefox2, the checkboxes disapear faster than when set to normal setting.
>
>
> Karl Rudd wrote:
>
> You could combine those two and stick them both in the document HEAD,
> since they both run on "ready" (see other email for why).
>
> There's no need to for the "filter()" function in this case, the
> "each()" function will do fine. Both iterate over the collection of
> objects, but "filter" is meant for "filtering", as in removing some
> elements.
>
> Hmmm and there's some other small optimisations. For example factoring
> the hide/show code into it's own function. Can change
> "[EMAIL PROTECTED]'checkbox']" to ":checkbox".
>
> Also "normal" is default for show() and hide().
>
> If I may suggest the following (untested):
>
> $(document).ready(function(){
>
>  function visibleCheck() {
>  var $this = $(this);
>  var ul = $this.siblings("ul");
>  if ($this.is(":checked"))
>  ul.hide();
>  else
>  ul.show();
>  }
>
>
>  $(":checkbox")
>  .click(visibleCheck)
>  .each(visibleCheck);
> });
>
> Karl Rudd
>
>
>
> --
> View this message in context:
> http://www.nabble.com/Loop-Checkbox-Action-Question-tf3246372.html#a9079695
> Sent from the JQuery mailing list archive at Nabble.com.
>
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>
>

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] specifying count for rss feed display with each function

2007-02-21 Thread john smith
Sorry all Im still a newb to jquery. Ive been messing around with using jquery 
for grabbing and displaying rss feed info. A lot less code then using straight 
javascript. what Im not quite clear on is how you grab a specific count from 
doing an .each

For example if I grab a feed with the jquery code below
   
  // count for lines display
var items_count = 10;
  
// feed location
var feed = my.xml';
   
// replace url for link
var u = 'http://www.mypage.html?txtSearch='
   
  $(document).ready(function(){
  $.get(feed, function(xml){
  $("item", xml).each(function(){
  $(this).find("item").each(function(){
  html += "";
  }).end().find("title").each(function(){
  html += "" + 
this.text + "";
  }); 
  });
$("#feed").html(html).slideDown("slow");
  
  });
});
   
  Using jquery how do I do a for each count like:
  for(var i=0; i___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] blockUI and CPU intensive form processing

2007-02-21 Thread Benjamin Sterling

If we can take a look at the test page, that would be helpful.


--
Benjamin Sterling
http://www.KenzoMedia.com
http://www.KenzoHosting.com
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Introduction and Masked Input Plugin

2007-02-21 Thread Jonathan Freeman
Very slick plugin, I will for sure use this on my next application. An
enhancement might be to provide a elegant way of handling non fixed length
numbers, such as currency inputs. So I guess its not so much masking, but
pattern matching.

$("#amount").maskedinput("999,999.99");

Nice job!



--- mrcarxpert <[EMAIL PROTECTED]> wrote:

> 
> So I'm reading that FF, Opera, and Safari support the
> DOMCharacterDataModified event.  I'll try to look into this further to
> produce something to handle pastes.  I've never messed with this event
> before, so I'm just shooting the dark here.  Any direction from the
> crowd?
> 
> Josh
> 
> 
> John Resig wrote:
> > 
> > This is so awesome. I love how the backspace key forces you into the
> > correct
> > space.
> > 
> > The tricky bit, that I found, is that if you paste in a block of text
> > (either correct, or incorrect) or if the browser's autocomplete fills
> in
> > an
> > incorrect value it doesn't "correct" it until you hit another key
> inside
> > the
> > field.
> > 
> > Offhand, I think the best way to "solve" this is to have a
> > setInterval(...)
> > check the fields at a specified rate (a couple times a second? or
> whatever
> > seems reasonable). This should solve both issues.
> > 
> > Again, this is really really great, I'll be putting this into place,
> like,
> > tomorrow.
> > 
> > --John
> > 
> > On 2/13/07, mrcarxpert <[EMAIL PROTECTED]> wrote:
> >>
> >>
> >> Hello everyone.  I just wanted to take this opportunity to introduce
> >> myself
> >> and start giving back to the community.
> >>
> >> I've been using jQuery for about 6 months now, and in the process
> I've
> >> produced a few plugins.  As I clean up the code in these I will be
> >> releasing
> >> them.  The first of which is a masked input plugin for
> dates,SSNs,phone
> >> numbers, etc.
> >>
> >> I've made the source code and examples for this project available at
> >> http://digitalbush.com/projects/masked-input-plugin
> >> http://digitalbush.com/projects/masked-input-plugin .
> >>
> >> I've tested this in Firefox and IE7 with the latest jQuery library. 
> If
> >> you
> >> don't mind I'd like to get some feedback on the plugin and how I can
> make
> >> it
> >> better.  I'd also like to know if there are any problems on other
> >> platforms.
> >>
> >> Since this is my first plugin I'm sure I'm missing a few things, but
> I
> >> tried
> >> to follow the patterns from some other plugins on the jQuery site. 
> One
> >> thing I know I'm missing is, what's the best way to ensure that this
> >> masking
> >> is only applied to a text input?  Right now my code returns
> this.each(
> >> /*code*/), but I'm guessing I might want to
> >> this.find("[EMAIL PROTECTED]'text']").each(/*code*/).  What is the most
> >> elegant
> >> way to do this?
> >>
> >> Anyway, I look forward to some feedback.  I'll consider myself
> formally
> >> introduced. :)
> >>
> >> Josh
> >> --
> >> View this message in context:
> >>
>
http://www.nabble.com/Introduction-and-Masked-Input-Plugin-tf3224850.html#a8957581
> >> Sent from the JQuery mailing list archive at Nabble.com.
> >>
> >>
> >> ___
> >> jQuery mailing list
> >> discuss@jquery.com
> >> http://jquery.com/discuss/
> >>
> > 
> > ___
> > jQuery mailing list
> > discuss@jquery.com
> > http://jquery.com/discuss/
> > 
> > 
> 
> -- 
> View this message in context:
>
http://www.nabble.com/Introduction-and-Masked-Input-Plugin-tf3224850.html#a8970941
> Sent from the JQuery mailing list archive at Nabble.com.
> 
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 



 

Do you Yahoo!?
Everyone is raving about the all-new Yahoo! Mail beta.
http://new.mail.yahoo.com

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Applyng classes to table rows?

2007-02-21 Thread Shane Graber - jQuery
Holy smoke, that's almost exactly what I'm trying to do.  The only
thing I'm wanting to do different is to make certain table rows
collapsed by default when the page is first viewed, which is why I am
applying classes to rows.

May I use your code a bit in what I'm working on?

Shane

On 2/21/07, rolfsf <[EMAIL PROTECTED]> wrote:
>
> sorry - wrong url
> http://www.monkeypuzzle.net/testfiles/jquery/Accordion_table/index_2.html
>
> Rolf
>
>
>
> rolfsf wrote:
> >
> > I could be wrong, but it sounds like you're trying to do something very
> > similar to what I was working on yesterday - collapsing a set of rows by
> > clicking on another row. You can see what I did (I didn't have to add any
> > classes to the rows I was collapsing) :
> > http://www.monkeypuzzle.net/testfiles/jquery/Accordion_table/
> >
> > Rolf
> >
> >
> >
>
> --
> View this message in context: 
> http://www.nabble.com/Applyng-classes-to-table-rows--tf3267824.html#a9087379
> Sent from the JQuery mailing list archive at Nabble.com.
>
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>


-- 
-
Bender: "Amy, you like cute things so I baked you a pony."
-

http://www.reefs.org - Where reefkeeping begins on the internet.
http://www.advancedaquarist.com - High quality, free monthly publication for
the reef keeping hobbyist.
http://www.aquaristcourses.org - Distance learning courses for the
marine aquarist.

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] dimensions and IE offset problem

2007-02-21 Thread Glenn Bach

Awesome! Thanks so much. It worked perfectly.

Glenn

On 2/21/07, Brandon Aaron <[EMAIL PROTECTED]> wrote:


Hey Glen I've got a fix but it looks as if SVN is down right now. You
can grab the patched version from here[1] but the revision and last
modified tags will not be up-to-date until SVN is back up.

[1]: http://brandon.jquery.com/plugins/dimensions/

--
Brandon Aaron

On 2/21/07, Brandon Aaron <[EMAIL PROTECTED]> wrote:
> Thanks for the report Glenn. I'm going to do some testing and see what
> I can figure out.
>
> --
> Brandon Aaron
>
> On 2/21/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> > I am seeing some behavior in IE that I don't understand and that I
don't see in Firefox.
> > The offset is being shifted by the margins of the body. If I
explicitly set the body to
> > have no margin, it lines up, if I just leave the default, it is
shifted. I can demonstrate
> > it with:
> >
> > 
> > 
> > 
> > 
> > 
> >
> > $(document).ready(function()
> > {
> > var offset = {};
> > var options = {}
> > $("#bar").offset(options, offset);
> > $("#movetest").css(offset);
> > });
> > 
> >
> > 
> > #movetest{ height: 100px; width: 100px; background: #dd; border:
1px solid black;
> > position: absolute;}
> > #bar {height: 100px; width: 100px; background: #ee; border: 1px
solid #dd;}
> >
> > 
> > 
> > 
> >
> > 
> > 
> >
> > 
> > 
> >
> > 
> > 
> >
> >
> > ___
> > jQuery mailing list
> > discuss@jquery.com
> > http://jquery.com/discuss/
> >
>

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] dimensions and IE offset problem

2007-02-21 Thread Brandon Aaron
This is now in SVN.

--
Brandon Aaron

On 2/21/07, Brandon Aaron <[EMAIL PROTECTED]> wrote:
> Hey Glen I've got a fix but it looks as if SVN is down right now. You
> can grab the patched version from here[1] but the revision and last
> modified tags will not be up-to-date until SVN is back up.
>
> [1]: http://brandon.jquery.com/plugins/dimensions/
>
> --
> Brandon Aaron
>
> On 2/21/07, Brandon Aaron <[EMAIL PROTECTED]> wrote:
> > Thanks for the report Glenn. I'm going to do some testing and see what
> > I can figure out.
> >
> > --
> > Brandon Aaron
> >
> > On 2/21/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> > > I am seeing some behavior in IE that I don't understand and that I don't 
> > > see in Firefox.
> > > The offset is being shifted by the margins of the body. If I explicitly 
> > > set the body to
> > > have no margin, it lines up, if I just leave the default, it is shifted. 
> > > I can demonstrate
> > > it with:
> > >
> > > 
> > > 
> > > 
> > > 
> > > 
> > >
> > > $(document).ready(function()
> > > {
> > > var offset = {};
> > > var options = {}
> > > $("#bar").offset(options, offset);
> > > $("#movetest").css(offset);
> > > });
> > > 
> > >
> > > 
> > > #movetest{ height: 100px; width: 100px; background: #dd; border: 1px 
> > > solid black;
> > > position: absolute;}
> > > #bar {height: 100px; width: 100px; background: #ee; border: 1px solid 
> > > #dd;}
> > >
> > > 
> > > 
> > > 
> > >
> > > 
> > > 
> > >
> > > 
> > > 
> > >
> > > 
> > > 
> > >
> > >
> > > ___
> > > jQuery mailing list
> > > discuss@jquery.com
> > > http://jquery.com/discuss/
> > >
> >
>

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] blockUI and CPU intensive form processing

2007-02-21 Thread RCS Computers
Basically, I have some CPU intensive form validation that takes about 3 
seconds to complete. I would like blockUI to start before the form 
processing and stop after the form processing. However, the blockUI 
message doesn't ever show up. When I comment out $.unblockUI(), the 
blockUI message shows up AFTER the form processing is completed. Code 
can be found here (57 lines): 


http://sh.nu/p/9301

I can arrange for the full HTML and JS if needed.

--
--
Randy Syring
RCS Computers & Web Solutions
502-644-4776
http://www.rcs-comp.com

"Whether, then, you eat or drink or 
whatever you do, do all to the glory

of God." 1 Cor 10:31

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Applyng classes to table rows?

2007-02-21 Thread rolfsf

sorry - wrong url
http://www.monkeypuzzle.net/testfiles/jquery/Accordion_table/index_2.html

Rolf



rolfsf wrote:
> 
> I could be wrong, but it sounds like you're trying to do something very
> similar to what I was working on yesterday - collapsing a set of rows by
> clicking on another row. You can see what I did (I didn't have to add any
> classes to the rows I was collapsing) :
> http://www.monkeypuzzle.net/testfiles/jquery/Accordion_table/ 
> 
> Rolf
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Applyng-classes-to-table-rows--tf3267824.html#a9087379
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Applyng classes to table rows?

2007-02-21 Thread rolfsf

I could be wrong, but it sounds like you're trying to do something very
similar to what I was working on yesterday - collapsing a set of rows by
clicking on another row. You can see what I did (I didn't have to add any
classes to the rows I was collapsing) :
http://www.monkeypuzzle.net/testfiles/jquery/Accordion_table/ 

Rolf



Shane Graber - jQuery wrote:
> 
> Awesome!  Thanks for the code.  :)
> 
> I agree, I should not set the id as id's are unique identifiers.  What
> I wanted to do was take the class name and id name from a previous  /> and combine them into a new class name like so:
> 
> from:   class="row" id="blah-one"
> to: class="row blah-one"
> 
> I modified your code a bit to achieve this.  Thank you!
> 
> Shane
> 
> On 2/21/07, Kristinn Sigmundsson <[EMAIL PROTECTED]> wrote:
>> this does it for the classes
>> $("table tr:not([EMAIL PROTECTED])").each(function() {
>> $(this).attr("class",
>> $(this).prev("[EMAIL PROTECTED]").attr("class"));
>> });
>> you might be able to get it down to one row...
>>
>> I would not recommend setting the IDs as you want, because the
>> standars clearly states that IDs should be UNIQUE!
>>
>> //Kristinn
>>
>> On 2/21/07, Shane Graber - jQuery <[EMAIL PROTECTED]> wrote:
>> > I'm stumped on how to do this with jQuery.  I have a table like this:
>> >
>> > 
>> >
>> > 
>> > 
>> > 
>> > 
>> >
>> > 
>> > 
>> > 
>> > 
>> >
>> > 
>> > 
>> > 
>> > 
>> >
>> > 
>> > 
>> > 
>> > 
>> >
>> > 
>> > 
>> > 
>> > 
>> >
>> > 
>> > 
>> > 
>> > 
>> >
>> > 
>> >
>> > I need to convert it to:
>> >
>> > 
>> >
>> > 
>> > 
>> > 
>> > 
>> >
>> > 
>> > 
>> > 
>> > 
>> >
>> > 
>> > 
>> > 
>> > 
>> >
>> > 
>> > 
>> > 
>> > 
>> >
>> > 
>> > 
>> > 
>> > 
>> >
>> > 
>> > 
>> > 
>> > 
>> >
>> > 
>> >
>> > Basically, I want to look at each table row and if it does not have a
>> > class, I want to look up the table row by row till it finds a row that
>> > has a class and id set on it and then take that class and id and apply
>> > it to that row that does not have its class set.
>> >
>> > What I am attempting to do is to write a show/hide script for phpBB so
>> > that I can dynamically show/hide sections of the forum tree either
>> > collapsed or expanded.  So far I have been successful at applying a
>> > class and id to each table row section but not the rows directly
>> > beneath it yet.
>> >
>> > Any help would be appreciated.  Thanks!
>> >
>> > Shane
>> >
>> > --
>> > -
>> > Bender: "Amy, you like cute things so I baked you a pony."
>> > -
>> >
>> > http://www.reefs.org - Where reefkeeping begins on the internet.
>> > http://www.advancedaquarist.com - High quality, free monthly
>> publication for
>> > the reef keeping hobbyist.
>> > http://www.aquaristcourses.org - Distance learning courses for the
>> > marine aquarist.
>> >
>> > ___
>> > jQuery mailing list
>> > discuss@jquery.com
>> > http://jquery.com/discuss/
>> >
>>
>> ___
>> jQuery mailing list
>> discuss@jquery.com
>> http://jquery.com/discuss/
>>
> 
> 
> -- 
> -
> Bender: "Amy, you like cute things so I baked you a pony."
> -
> 
> http://www.reefs.org - Where reefkeeping begins on the internet.
> http://www.advancedaquarist.com - High quality, free monthly publication
> for
> the reef keeping hobbyist.
> http://www.aquaristcourses.org - Distance learning courses for the
> marine aquarist.
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Applyng-classes-to-table-rows--tf3267824.html#a9087342
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Set selected option

2007-02-21 Thread Arne-Kolja Bachstein
Jörn Zaefferer wrote:
>> If for example your option values would look like "02/21/2007" etc. you
>> could easily set the selected one with:
>>
>> $('#date').val('02/22/2007');
>>
>>
>> 
>>  ...
>>  02/21/2007
>>  ...
>> 
>>   
>> 
> Or, in case you have seperated selects for each value:
>
> $("#year option:contains(2007)").attr("selected", true);
>
>   

thx to both of you! but why would the last one be better? i can set
single values with the first one too.
btw: only the first one seems to work. is there an error within the
contains-selector?

greets,

Arne
http://www.arnekolja.com

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] dimensions and IE offset problem

2007-02-21 Thread Brandon Aaron
Hey Glen I've got a fix but it looks as if SVN is down right now. You
can grab the patched version from here[1] but the revision and last
modified tags will not be up-to-date until SVN is back up.

[1]: http://brandon.jquery.com/plugins/dimensions/

--
Brandon Aaron

On 2/21/07, Brandon Aaron <[EMAIL PROTECTED]> wrote:
> Thanks for the report Glenn. I'm going to do some testing and see what
> I can figure out.
>
> --
> Brandon Aaron
>
> On 2/21/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> > I am seeing some behavior in IE that I don't understand and that I don't 
> > see in Firefox.
> > The offset is being shifted by the margins of the body. If I explicitly set 
> > the body to
> > have no margin, it lines up, if I just leave the default, it is shifted. I 
> > can demonstrate
> > it with:
> >
> > 
> > 
> > 
> > 
> > 
> >
> > $(document).ready(function()
> > {
> > var offset = {};
> > var options = {}
> > $("#bar").offset(options, offset);
> > $("#movetest").css(offset);
> > });
> > 
> >
> > 
> > #movetest{ height: 100px; width: 100px; background: #dd; border: 1px 
> > solid black;
> > position: absolute;}
> > #bar {height: 100px; width: 100px; background: #ee; border: 1px solid 
> > #dd;}
> >
> > 
> > 
> > 
> >
> > 
> > 
> >
> > 
> > 
> >
> > 
> > 
> >
> >
> > ___
> > jQuery mailing list
> > discuss@jquery.com
> > http://jquery.com/discuss/
> >
>

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] accordion table, instead of an accordion list/menu?

2007-02-21 Thread Rick Faircloth
After trying about everything I could think of to make a 2nd row
slide & hide smoothly, I finally decided to make two tables

The first table contains the visible information, such as event name,
date, & time (this is an experiment for a calendar).

The second table right beneath it contains all the details of the
event.

I applied an id directly to the first table to make it clickable,
and then wrapped the second table in a div.

After doing that I get very smooth show and hide and it looks
no different than it would if it were all in one table.

Rick

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On
Behalf Of Sam Collett
Sent: Wednesday, February 21, 2007 11:49 AM
To: jQuery Discussion.
Subject: Re: [jQuery] accordion table, instead of an accordion list/menu?

On 21/02/07, Kristinn Sigmundsson <[EMAIL PROTECTED]> wrote:
> Thing is that even if you have a callback to the slideToggle and set
> the display property to table-row, it still comes out wierd...
>
> maybe a wrapping div is the best solution?

I have tried wrapping with DIV's, but they don't seem to work for me
(around tr, tbody and wrapping the contents of cells).

I have not come across any method in JavaScript that can slide up/down
a row. I am not sure if Prototype or YUI are capable of this.





___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Set selected option

2007-02-21 Thread Jörn Zaefferer
Klaus Hartl schrieb:
> Arne-Kolja Bachstein schrieb:
>   
>> Hi,
>>
>> does anyone know how I can set the selected option in an option list?
>> I got several dropdowns to select a date and would like to preselect the
>> current date using JS (cannot use a server side language atm). I know
>> how to find out the date, but how could I (easily) select the
>> corresponding option?
>>
>> Greets,
>>
>> Arne
>> http://www.arnekolja.com
>> 
>
>
> If for example your option values would look like "02/21/2007" etc. you 
> could easily set the selected one with:
>
> $('#date').val('02/22/2007');
>
>
> 
>  ...
>  02/21/2007
>  ...
> 
>   
Or, in case you have seperated selects for each value:

$("#year option:contains(2007)").attr("selected", true);

-- 
Jörn Zaefferer

http://bassistance.de


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Applyng classes to table rows?

2007-02-21 Thread Shane Graber - jQuery
Awesome!  Thanks for the code.  :)

I agree, I should not set the id as id's are unique identifiers.  What
I wanted to do was take the class name and id name from a previous  and combine them into a new class name like so:

from:   class="row" id="blah-one"
to: class="row blah-one"

I modified your code a bit to achieve this.  Thank you!

Shane

On 2/21/07, Kristinn Sigmundsson <[EMAIL PROTECTED]> wrote:
> this does it for the classes
> $("table tr:not([EMAIL PROTECTED])").each(function() {
> $(this).attr("class", $(this).prev("[EMAIL 
> PROTECTED]").attr("class"));
> });
> you might be able to get it down to one row...
>
> I would not recommend setting the IDs as you want, because the
> standars clearly states that IDs should be UNIQUE!
>
> //Kristinn
>
> On 2/21/07, Shane Graber - jQuery <[EMAIL PROTECTED]> wrote:
> > I'm stumped on how to do this with jQuery.  I have a table like this:
> >
> > 
> >
> > 
> > 
> > 
> > 
> >
> > 
> > 
> > 
> > 
> >
> > 
> > 
> > 
> > 
> >
> > 
> > 
> > 
> > 
> >
> > 
> > 
> > 
> > 
> >
> > 
> > 
> > 
> > 
> >
> > 
> >
> > I need to convert it to:
> >
> > 
> >
> > 
> > 
> > 
> > 
> >
> > 
> > 
> > 
> > 
> >
> > 
> > 
> > 
> > 
> >
> > 
> > 
> > 
> > 
> >
> > 
> > 
> > 
> > 
> >
> > 
> > 
> > 
> > 
> >
> > 
> >
> > Basically, I want to look at each table row and if it does not have a
> > class, I want to look up the table row by row till it finds a row that
> > has a class and id set on it and then take that class and id and apply
> > it to that row that does not have its class set.
> >
> > What I am attempting to do is to write a show/hide script for phpBB so
> > that I can dynamically show/hide sections of the forum tree either
> > collapsed or expanded.  So far I have been successful at applying a
> > class and id to each table row section but not the rows directly
> > beneath it yet.
> >
> > Any help would be appreciated.  Thanks!
> >
> > Shane
> >
> > --
> > -
> > Bender: "Amy, you like cute things so I baked you a pony."
> > -
> >
> > http://www.reefs.org - Where reefkeeping begins on the internet.
> > http://www.advancedaquarist.com - High quality, free monthly publication for
> > the reef keeping hobbyist.
> > http://www.aquaristcourses.org - Distance learning courses for the
> > marine aquarist.
> >
> > ___
> > jQuery mailing list
> > discuss@jquery.com
> > http://jquery.com/discuss/
> >
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>


-- 
-
Bender: "Amy, you like cute things so I baked you a pony."
-

http://www.reefs.org - Where reefkeeping begins on the internet.
http://www.advancedaquarist.com - High quality, free monthly publication for
the reef keeping hobbyist.
http://www.aquaristcourses.org - Distance learning courses for the
marine aquarist.

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] dimensions and IE offset problem

2007-02-21 Thread Brandon Aaron
Thanks for the report Glenn. I'm going to do some testing and see what
I can figure out.

--
Brandon Aaron

On 2/21/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> I am seeing some behavior in IE that I don't understand and that I don't see 
> in Firefox.
> The offset is being shifted by the margins of the body. If I explicitly set 
> the body to
> have no margin, it lines up, if I just leave the default, it is shifted. I 
> can demonstrate
> it with:
>
> 
> 
> 
> 
> 
>
> $(document).ready(function()
> {
> var offset = {};
> var options = {}
> $("#bar").offset(options, offset);
> $("#movetest").css(offset);
> });
> 
>
> 
> #movetest{ height: 100px; width: 100px; background: #dd; border: 1px 
> solid black;
> position: absolute;}
> #bar {height: 100px; width: 100px; background: #ee; border: 1px solid 
> #dd;}
>
> 
> 
> 
>
> 
> 
>
> 
> 
>
> 
> 
>
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


  1   2   >