Re: [jQuery] Please help (again, sorry)..NextUntil not working

2006-10-17 Thread Greg Bird

Hi John,  


thanks again for your help, unfortunately I have deployed your suggestions
and am still unable to get it to work.  You can view my testpage at:
http://members.optusnet.com.au/greg.bird/mm/collapse.html

My .js now reads:

$(document).ready(function(){
  BuildNav();
});
//DEFINE NextUntil FUNCTION

$.fn.nextUntil = function(expr) {
var match = [];

this.each(function(){
var cur = this.nextSibling;
while ( cur && jQuery.filter( expr, [cur] ).r.length ) {
match = jQuery.merge( match, [ cur ] );
cur = cur.nextSibling;
}
console.log(this,cur,match);
});

return this.pushStack( match, arguments );
};

/*BUILD SIDE NAVIGATION*/
function BuildNav() {
$("#content h2").each(function(){
$(this).nextUntil("h2").wrap("");
});
}

I have logged the script and it appears that the "match" array is not being
populated.  I suspect that the Jquery.merge function is not triggering
properly

Does this function work with JQUERY 1.0.2?  In note in the JQUERY doco that
the function call is now $.merge.  Trialled this without success.

My aim here is to put a unique div around each section of the page and then
dynamically create an expand/collapse navigation system.  Have already
achieved a similar result with a sliding navigation system.  You can see
this at:

http://members.optusnet.com.au/greg.bird/mm/index.html

This was easier as I didn't need to wrap div's around anything, but simply
anchor to the existing H2's


Have you got any suggestions?  Do you have any test pages so that I can view
your implementation?

Thanks in advance, Greg

John Resig wrote:
> 
> Hi Greg -
> 
> I created a plugin a while back that can help with this, called nextUntil:
> 
> $.fn.nextUntil = function(expr) {
> var match = [];
> 
> this.each(function(){
> var cur = this.nextSibling;
> while ( cur && jQuery.filter( expr, [cur] ).r.length ) {
> match = jQuery.merge( match, [ cur ] );
> cur = cur.nextSibling;
> }
> });
> 
> return this.pushStack( match, arguments );
> };
> 
> Just include that after you include jquery.js then do the following:
> 
> $("#content h2").each(function(){
> $(this).nextUntil("h2").wrap("");
> });
> 
> Just 3 lines! Not too shabby :)
> 
> --John
> 
> On 10/18/06, Greg Bird <[EMAIL PROTECTED]> wrote:
>>
>> Hi everyone.
>>
>> I am attempting to develop some dynamic "in page" navigation. I am a big
>> fan of structural markup.
>>
>> Each H2 represents a new section of the current document.
>>
>> I wish to:
>> 1. Find each H2
>> 2. Wrap this in a unique div, up to (but not including) the next H2. This
>> will then be used to further manipulate the page
>>
>>
>>
>> 
>> 
>> 
>> First section
>> ...[arbitary HTML]
>> 
>>
>> 
>> second section
>> ...[arbitary HTML]
>> 
>> third section
>> .
>> 
>>
>> Here is the JQuery that I have developed to date:
>>
>> $(document).ready(function(){
>> BuildNav();
>> });
>> /*BUILD SIDE NAVIGATION*/
>> function BuildNav() {
>> //add back to top links before each H2
>> $('#content h2').each(function(i){
>> if(i==0){//FIRST H2
>> $(this).before('')//START A NEW DIV WITH
>> UNIQUE ID
>> }
>> else {
>> $(this).before('');//TERMINATE
>> PREVIOUS DIV, BEGIN NEW ONE
>> }
>> })
>> $('#content').append('');//TERMINATE FINAL DIV
>> }
>>
>> This looks sensible to me but fails. It appears you cannot inject
>> unterminated tags and that JQUERY automatically closes tags on insertion,
>> resulting in:
>>
>> 
>> First section
>> ...[arbitary HTML]
>> 
>> second section
>> ...[arbitary HTML]
>> 
>> third section
>> .
>> 
>>
>> Can anyone give me any clues? Thanks in advance, Greg Bird
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 
Quoted from: 
http://www.nabble.com/Please-help%21-Dynamically-Wrapping-DIV%27s-around-structural-markup.-tf2464168.html#a6869443

-- 
View this message in context: 
http://www.nabble.com/Please-help%21-Dynamically-Wrapping-DIV%27s-around-structural-markup.-tf2464168.html#a6870422
Sent from the JQuery mailing list archive at Nabble.com.


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


Re: [jQuery] Replying to threads

2006-10-17 Thread Klaus Hartl


Ⓙⓐⓚⓔ schrieb:
> I use gmail, it threads like a champ macintosh mail.app is also good,
> 
> What other threaded mail readers do you guys use that we can recommend
> for the aol crowd?

Thunderbird of course. I found that Mac's Mail.app is not capable of 
showing threads in a reaonable way (there's only one level of 
"indentation")...


-- Klaus

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


Re: [jQuery] Selectors [EMAIL PROTECTED]|=val] and [EMAIL PROTECTED] Have they been removed?

2006-10-17 Thread Ⓙⓐⓚⓔ
Ok... I recognized ^= , $=  and that was plenty for me! |= seemed
weird, and I thought ~= was for a regex.

On 10/17/06, John Resig <[EMAIL PROTECTED]> wrote:
> > when I saw hreflang, I assumed you supported any attr...  what
> > atttibutes do you support?
>
> Ah, you misunderstand me. Any attribute is supported - that's not the
> problem. The |= and ~= operators are not supported. For example ~=
> (which is used with hreflang and lang attributes) parses some strange
> combination of a hyphenated list. Honestly, I've never seen anyone use
> the lang attribute - let alone have a need to select it using a CSS
> selector. Hence the reason for removing it.
>
> --John
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>


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


Re: [jQuery] Please help! Dynamically Wrapping DIV's around structural markup.

2006-10-17 Thread Greg Bird

Fantastic John  Exactly what I was looking for.  Thanks for the prompt
assistance.  I will deploy and test tonight and let you know how I go. 

I notice how prolific you are on this mailing list...great to see people
as switched on as yourself willing to help the "intellectually less
fortunate"

Thanks again, Greg



John Resig wrote:
> 
> Hi Greg -
> 
> I created a plugin a while back that can help with this, called nextUntil:
> 
> $.fn.nextUntil = function(expr) {
> var match = [];
> 
> this.each(function(){
> var cur = this.nextSibling;
> while ( cur && jQuery.filter( expr, [cur] ).r.length ) {
> match = jQuery.merge( match, [ cur ] );
> cur = cur.nextSibling;
> }
> });
> 
> return this.pushStack( match, arguments );
> };
> 
> Just include that after you include jquery.js then do the following:
> 
> $("#content h2").each(function(){
> $(this).nextUntil("h2").wrap("");
> });
> 
> Just 3 lines! Not too shabby :)
> 
> --John
> 
> On 10/18/06, Greg Bird <[EMAIL PROTECTED]> wrote:
>>
>> Hi everyone.
>>
>> I am attempting to develop some dynamic "in page" navigation. I am a big
>> fan of structural markup.
>>
>> Each H2 represents a new section of the current document.
>>
>> I wish to:
>> 1. Find each H2
>> 2. Wrap this in a unique div, up to (but not including) the next H2. This
>> will then be used to further manipulate the page
>>
>>
>>
>> 
>> 
>> 
>> First section
>> ...[arbitary HTML]
>> 
>>
>> 
>> second section
>> ...[arbitary HTML]
>> 
>> third section
>> .
>> 
>>
>> Here is the JQuery that I have developed to date:
>>
>> $(document).ready(function(){
>> BuildNav();
>> });
>> /*BUILD SIDE NAVIGATION*/
>> function BuildNav() {
>> //add back to top links before each H2
>> $('#content h2').each(function(i){
>> if(i==0){//FIRST H2
>> $(this).before('')//START A NEW DIV WITH
>> UNIQUE ID
>> }
>> else {
>> $(this).before('');//TERMINATE
>> PREVIOUS DIV, BEGIN NEW ONE
>> }
>> })
>> $('#content').append('');//TERMINATE FINAL DIV
>> }
>>
>> This looks sensible to me but fails. It appears you cannot inject
>> unterminated tags and that JQUERY automatically closes tags on insertion,
>> resulting in:
>>
>> 
>> First section
>> ...[arbitary HTML]
>> 
>> second section
>> ...[arbitary HTML]
>> 
>> third section
>> .
>> 
>>
>> Can anyone give me any clues? Thanks in advance, Greg Bird
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Please-help%21-Dynamically-Wrapping-DIV%27s-around-structural-markup.-tf2464168.html#a6869715
Sent from the JQuery mailing list archive at Nabble.com.


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


Re: [jQuery] Please help! Dynamically Wrapping DIV's around structural markup.

2006-10-17 Thread John Resig
Hi Greg -

I created a plugin a while back that can help with this, called nextUntil:

$.fn.nextUntil = function(expr) {
var match = [];

this.each(function(){
var cur = this.nextSibling;
while ( cur && jQuery.filter( expr, [cur] ).r.length ) {
match = jQuery.merge( match, [ cur ] );
cur = cur.nextSibling;
}
});

return this.pushStack( match, arguments );
};

Just include that after you include jquery.js then do the following:

$("#content h2").each(function(){
$(this).nextUntil("h2").wrap("");
});

Just 3 lines! Not too shabby :)

--John

On 10/18/06, Greg Bird <[EMAIL PROTECTED]> wrote:
>
> Hi everyone.
>
> I am attempting to develop some dynamic "in page" navigation. I am a big
> fan of structural markup.
>
> Each H2 represents a new section of the current document.
>
> I wish to:
> 1. Find each H2
> 2. Wrap this in a unique div, up to (but not including) the next H2. This
> will then be used to further manipulate the page
>
>
>
> 
> 
> 
> First section
> ...[arbitary HTML]
> 
>
> 
> second section
> ...[arbitary HTML]
> 
> third section
> .
> 
>
> Here is the JQuery that I have developed to date:
>
> $(document).ready(function(){
> BuildNav();
> });
> /*BUILD SIDE NAVIGATION*/
> function BuildNav() {
> //add back to top links before each H2
> $('#content h2').each(function(i){
> if(i==0){//FIRST H2
> $(this).before('')//START A NEW DIV WITH
> UNIQUE ID
> }
> else {
> $(this).before('');//TERMINATE
> PREVIOUS DIV, BEGIN NEW ONE
> }
> })
> $('#content').append('');//TERMINATE FINAL DIV
> }
>
> This looks sensible to me but fails. It appears you cannot inject
> unterminated tags and that JQUERY automatically closes tags on insertion,
> resulting in:
>
> 
> First section
> ...[arbitary HTML]
> 
> second section
> ...[arbitary HTML]
> 
> third section
> .
> 
>
> Can anyone give me any clues? Thanks in advance, Greg Bird

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


[jQuery] Please help! Dynamically Wrapping DIV's around structural markup.

2006-10-17 Thread Greg Bird

Hi everyone.

I am attempting to develop some dynamic "in page" navigation. I am a big
fan of structural markup. 

Each H2 represents a new section of the current document.

I wish to:
1. Find each H2
2. Wrap this in a unique div, up to (but not including) the next H2. This
will then be used to further manipulate the page






First section
...[arbitary HTML]



second section
...[arbitary HTML]

third section
.


Here is the JQuery that I have developed to date:

$(document).ready(function(){
BuildNav();
});
/*BUILD SIDE NAVIGATION*/
function BuildNav() {
//add back to top links before each H2
$('#content h2').each(function(i){
if(i==0){//FIRST H2
$(this).before('')//START A NEW DIV WITH
UNIQUE ID
}
else {
$(this).before('');//TERMINATE
PREVIOUS DIV, BEGIN NEW ONE
}
})
$('#content').append('');//TERMINATE FINAL DIV
}

This looks sensible to me but fails. It appears you cannot inject
unterminated tags and that JQUERY automatically closes tags on insertion,
resulting in:


First section
...[arbitary HTML]

second section
...[arbitary HTML]

third section
.


Can anyone give me any clues? Thanks in advance, Greg Bird

-- 
View this message in context: 
http://www.nabble.com/Please-help%21-Dynamically-Wrapping-DIV%27s-around-structural-markup.-tf2464168.html#a6869370
Sent from the JQuery mailing list archive at Nabble.com.


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


Re: [jQuery] Selectors [EMAIL PROTECTED]|=val] and [EMAIL PROTECTED] Have they been removed?

2006-10-17 Thread John Resig
> when I saw hreflang, I assumed you supported any attr...  what
> atttibutes do you support?

Ah, you misunderstand me. Any attribute is supported - that's not the
problem. The |= and ~= operators are not supported. For example ~=
(which is used with hreflang and lang attributes) parses some strange
combination of a hyphenated list. Honestly, I've never seen anyone use
the lang attribute - let alone have a need to select it using a CSS
selector. Hence the reason for removing it.

--John

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


Re: [jQuery] Radio button bug

2006-10-17 Thread John Resig
Steven -

After doing some testing of my own, and looking through your code,
I've come to a similar conclusion. It only occurs when:
1) The item that you're hiding/showing is within a form.
2) The item that you're hiding/showing contains a checked radio button.
3) That radio button has a name applied to it.

It makes sense as to why it happens - as only one radio button can be
checked at a time. In total, the code to understand this can be
reduced to:

$("")
.appendTo("body")
.clone()
.appendTo("body");

There'll be two radio buttons, but the second one will be the only one
that's checked.

I reduced your patch to adding the line:
.find(":radio").removeAttr("checked").end()

I just committed it and it's in SVN rev 451. I'll wrap up 1.0.3
quickly then and get it out in the next couple days, that way you have
working code for your release.

--John

On 10/17/06, Steven Wittens <[EMAIL PROTECTED]> wrote:
> I've found a rather tricky bug in jQuery 1.0.2. When you use an
> animated slideDown() or show() on an element containing one or more
> radio buttons, the radio buttons lose their selection status in
> Firefox (1.5 and 2.0 for sure, maybe others), and Opera 9 (maybe
> others). It works fine in IE6 and Safari 2. This also only seems to
> happen when you apply an animation for the first time.
>
> I have attached a minimal test case to reproduce. There are four
> pairs of radiobuttons, each having one radio button selected. Their
> source markup is functionally identical. Clicking the provided link
> runs a different animation on each radio button pair: the first two
> pairs of radio buttons lose their selection, the last two work fine.
>
> This is caused by the code in jQuery.css() used to measure the
> dimensions of elements that are hidden. jQuery temporarily replicates
> the element inside its parent. This causes two selected radio buttons
> with the same 'name' to appear in the form, which is not allowed. It
> seems that Firefox and Opera defensively remove both selections in
> this case.
>
> One fix is to simply remove the checked attributes of all radio
> buttons inside the clone, before inserting it into the parent. See
> attached patch.
>
> This is a major blocker for jQuery in Drupal by the way, as it can
> break any animated portion of a form. I'm going to patch our included
> copy after you guys review this patch (we have a release candidate
> coming up next monday), but it would be nice to see this fixed in a
> 1.0.3 release soon ;).
>
> Steven Wittens
>
>
>
>
>
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>
>
>
>


-- 
John Resig
http://ejohn.org/
[EMAIL PROTECTED]

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


[jQuery] Older Interface Code?

2006-10-17 Thread Nathan Smith
I'm wondering if anyone has an archived copy of the older version of
Interface elements. It seemed to be less buggy than the present one. I
need the uncompressed variety, which unfortunately I didn't have the
forethought to hang on to.

So, does anyone have an uncompressed, older (pre jQuery 1.0.1) version
of Interface? If so, please let me know. Thanks to everyone who
contributes to this list, by the way - definitely one of the better
ones I'm subscribed to. :)

-- 
Nathan Smith
208 348 2213 - work
859 229 9587 - cell
http://sonspring.com

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


Re: [jQuery] Radio button bug

2006-10-17 Thread John Resig
Brandon -

> This patch will for sure increase the length of time it takes for
> jQuery.css to run for height and width ... if what is mentioned about
> jQuery.css being slow in a previous thread holds true.

This is an unrelated issue. This one strictly relates to getting the
height/width of an element - not setting it (which was the discussion
of the other email.

--John

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


Re: [jQuery] Select append(html) issue fixed (need testers)

2006-10-17 Thread Brandon Aaron
I take that back ... I totally missed the point. Checking into that as
a possible solution right now. That should reduce the code by a lot!

Thanks!

--
Brandon Aaron

On 10/17/06, Brandon Aaron <[EMAIL PROTECTED]> wrote:
> On 10/17/06, Dave Methvin <[EMAIL PROTECTED]> wrote:
> > I took a quick look last night but was wondering if it would be much easier
> > to wrap the incoming options/optgroup string in a temporary  the way
> > .clean() does for table chunks. I was going to try it myself but ran out of
> > night.
>
> But that would only complicate the issue. The problem is that you
> can't just innerHTML several option tags or optgroup tags to a select.
> This is realized by the non-patched demo. It just appends the whole
> string in one option. You would still have to parse the html, find the
> options and optgroups, create the elements, append them to the select,
> then get the childNodes of the select and return those. This is just
> simply parsing the string of html and sending back the dom nodes to
> append to the original select.
>
> --
> Brandon Aaron
>

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


Re: [jQuery] åäö doesn't wo rk with load/loadIfModified

2006-10-17 Thread Ⓙⓐⓚⓔ
On 10/17/06, Steven Wittens <[EMAIL PROTECTED]> wrote:

> The meta tags for html documents are only a fallback for the real
> HTTP headers. HTTP headers always take precendence over meta tags.

in other words, it's the server config or the application on the server.

How it's done in your environment on iis, I don't know. does anyone?

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


Re: [jQuery] åäö doesn't work with load/loa dIfModified

2006-10-17 Thread Steven Wittens
>
> OR you can see if IIS has a place to set the encoding, (as Apache does
> system wide, site wide, or directory wide).

What this comes down to is changing this HTTP header:
>>> Content-Type: text/html
into Content-Type: text/html; charset=ISO-8859-1

I have no clue how to do that in ASP.net though.

The meta tags for html documents are only a fallback for the real  
HTTP headers. HTTP headers always take precendence over meta tags.

Steven Wittens


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


Re: [jQuery] Radio button bug

2006-10-17 Thread Geoff Knutzen



This must be a recent bug. When I try this example 
with my slightly modified version of 1.0, the first two example hold their 
selected values. (the third test doesn't work at all. I assume that this is 
because of a bug that has been fixed.) When I use 1.02, the first two break as 
you have noted. 
Is there a place that 1.0 and 1.01 can be 
downloaded? (I don't have the ability to get it from SVN) These older 
versions could provide clues as to an easy fix. 

  - Original Message - 
  From: 
  Steven Wittens 
  
  To: jQuery Discussion. 
  Sent: Tuesday, October 17, 2006 6:41 
  PM
  Subject: [jQuery] Radio button bug
  I've found a rather tricky bug in jQuery 1.0.2. When you use 
  an  animated slideDown() or show() on an element containing one or 
  more  radio buttons, the radio buttons lose their selection status 
  in  Firefox (1.5 and 2.0 for sure, maybe others), and Opera 9 
  (maybe  others). It works fine in IE6 and Safari 2. This also only 
  seems to  happen when you apply an animation for the first 
  time.I have attached a minimal test case to reproduce. There are 
  four  pairs of radiobuttons, each having one radio button selected. 
  Their  source markup is functionally identical. Clicking the provided 
  link  runs a different animation on each radio button pair: the first 
  two  pairs of radio buttons lose their selection, the last two work 
  fine.This is caused by the code in jQuery.css() used to measure 
  the  dimensions of elements that are hidden. jQuery temporarily 
  replicates  the element inside its parent. This causes two selected 
  radio buttons  with the same 'name' to appear in the form, which is 
  not allowed. It  seems that Firefox and Opera defensively remove both 
  selections in  this case.One fix is to simply remove the 
  checked attributes of all radio  buttons inside the clone, before 
  inserting it into the parent. See  attached patch.This is a 
  major blocker for jQuery in Drupal by the way, as it can  break any 
  animated portion of a form. I'm going to patch our included  copy 
  after you guys review this patch (we have a release candidate  coming 
  up next monday), but it would be nice to see this fixed in a  1.0.3 
  release soon ;).Steven Wittens
  
  

  
  
  

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


Re: [jQuery] Selectors [EMAIL PROTECTED]|=val] and [EMAIL PROTECTED] Have they been removed?

2006-10-17 Thread Ⓙⓐⓚⓔ
John,

when I saw hreflang, I assumed you supported any attr...  what
atttibutes do you support?

is this another place where you should throw an exception?

On 10/17/06, John Resig <[EMAIL PROTECTED]> wrote:
> Hi Choan -
>
> > * Attribute selector [EMAIL PROTECTED] doesn't work (returns any
> > element with a class name)
> > * Attribute selector [EMAIL PROTECTED]|=en] doesn't work (returns any 
> > element
> > with a hreflang attribute)
> >
> > Has the support for these selectors been removed?
>
> Yes, I removed support for those selectors, since they're virtually
> useless, in most respects. Finding an element by class is as simple
> as:
> foo.className
>
> and the lang-related stuff seemed just silly - I've never seen an
> actual, practical use for it. Were you attempting to use them for
> something, or just curious?
>
> --John
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>


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


Re: [jQuery] Replying to threads

2006-10-17 Thread Ⓙⓐⓚⓔ
I use gmail, it threads like a champ macintosh mail.app is also good,

What other threaded mail readers do you guys use that we can recommend
for the aol crowd?


On 10/17/06, Steven Wittens <[EMAIL PROTECTED]> wrote:
> Note.. please don't reply to existing threads when you're starting a
> new one. You make it harder to read mail for those of us with
> threaded mail-clients, as well as in the mailinglist archives.
>
> Steven Wittens
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>


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


Re: [jQuery] best show/hide div code?

2006-10-17 Thread Mike Chabot
Some examples:
selectField.options[selectField.selectedIndex].value
or
selectField.options[selectField.selectedIndex].text
or
selectField.options[3].selected

Enjoy,
Mike Chabot

On 10/17/06, Andy Matthews <[EMAIL PROTECTED]> wrote:
> Anyone have an idea on this one? I've tried a few things, but I'm not sure
> how to reference a specific value in a select control.
>
>  andy matthews
> web developer
> certified advanced coldfusion programmer
> ICGLink, Inc.
> [EMAIL PROTECTED]
> 615.370.1530 x737
> --//->
>
> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> Behalf Of Andy Matthews
> Sent: Tuesday, October 17, 2006 10:39 AM
> To: [jQuery]
> Subject: [jQuery] best show/hide div code?
>
>
> I'm working on a mailing list manager and one of the options is to provide a
> zip code for emailing anyone in that area. I'd like to hide this field
> unless the user has selected the "Tour Date" option from a select field.
>
> The relevant code is below. The second TR (and it's contents) will be hidden
> by default using CSS, but I want to toggle it's display property when the
> user selects or deselects the "event" option in the "type" dropdown field.
>
> 
> 
>Mailing Type
>
>
>General Announcement
>BCC Store Announcement
>Clowndergarten 
> Announcement
>Event Announcement
>
>
> 
> 
>Zip Code of event class="smaller">for event announcement only
>
> 
> 
>
> How would I do this with jQuery?
>
>  andy matthews
> web developer
> certified advanced coldfusion programmer
> ICGLink, Inc.
> [EMAIL PROTECTED]
> 615.370.1530 x737
> --//->
>
>
> ___
> 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] problem iwith leadiing space in IE

2006-10-17 Thread Angelo Sozzi

Thanks, that did the trick!



Brandon Aaron wrote:
> 
> You can just call $.trim on the string. Just to change this line:
> text = "html/"+$(this).text()+".html"; /*read out text from
> to this:
> text = "html/"+$.trim($(this).text())+".html"; /*read out text from
> 
> Perhaps $().text() should call this for you. Does anyone see a reason
> why $().text() shouldn't call $.trim() on the result?
> 
> --
> Brandon Aaron
> 
> On 10/17/06, Angelo Sozzi <[EMAIL PROTECTED]> wrote:
>>
>> Hi,
>> I just started  using JQuery and I'm amazed how simple things can be
>> done...
>> Unfortunately I've run into an IE issue (I think). Im using an UL list
>> for
>> A-Z links (large site). I try to read out the LI elements and use them to
>> generate the path to the html file  (E.g. A.html from A.
>>
>> This seems to work fine in FF, but in IE I end up with a filename of 'A
>> .html' (note the space):
>>
>> Demo: (only A and B load data) using V.249
>> http://www.sozzi.cn/jquery/fish_ajax_3.html
>>
>> The alert poping up just outputs the generated filename:
>> the "offending" line of code is:
>>
>> text = "html/"+$(this).text()+".html"; /*read out text from
>> text and make filename from it*/
>>
>>
>> any way to solve this easily? I just found some regex solutions I don't
>> quite understand.
>>
>> Thanks a lot
>>
>> Angelo
>> --
>> View this message in context:
>> http://www.nabble.com/problem-iwith-leadiing-space-in-IE-tf2461879.html#a6863015
>> 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/problem-iwith-leadiing-space-in-IE-tf2461879.html#a6868326
Sent from the JQuery mailing list archive at Nabble.com.


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


Re: [jQuery] Radio button bug

2006-10-17 Thread Brandon Aaron
jQuery.css() method has come up several times recently.

This patch will for sure increase the length of time it takes for
jQuery.css to run for height and width ... if what is mentioned about
jQuery.css being slow in a previous thread holds true.

--
Brandon Aaron

On 10/17/06, Steven Wittens <[EMAIL PROTECTED]> wrote:
> I've found a rather tricky bug in jQuery 1.0.2. When you use an
> animated slideDown() or show() on an element containing one or more
> radio buttons, the radio buttons lose their selection status in
> Firefox (1.5 and 2.0 for sure, maybe others), and Opera 9 (maybe
> others). It works fine in IE6 and Safari 2. This also only seems to
> happen when you apply an animation for the first time.
>
> I have attached a minimal test case to reproduce. There are four
> pairs of radiobuttons, each having one radio button selected. Their
> source markup is functionally identical. Clicking the provided link
> runs a different animation on each radio button pair: the first two
> pairs of radio buttons lose their selection, the last two work fine.
>
> This is caused by the code in jQuery.css() used to measure the
> dimensions of elements that are hidden. jQuery temporarily replicates
> the element inside its parent. This causes two selected radio buttons
> with the same 'name' to appear in the form, which is not allowed. It
> seems that Firefox and Opera defensively remove both selections in
> this case.
>
> One fix is to simply remove the checked attributes of all radio
> buttons inside the clone, before inserting it into the parent. See
> attached patch.
>
> This is a major blocker for jQuery in Drupal by the way, as it can
> break any animated portion of a form. I'm going to patch our included
> copy after you guys review this patch (we have a release candidate
> coming up next monday), but it would be nice to see this fixed in a
> 1.0.3 release soon ;).
>
> Steven Wittens
>
>
>
>
>
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>
>
>
>

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


Re: [jQuery] List - getting children

2006-10-17 Thread Dave Methvin
This worked for me:

  var data = ["new-one", "new-two "]
  $("#links").empty().append(data.join("")).children();

You are better off using .empty() because .children().remove() will
pushStack and move you off #links. You can get back with .end() but that's a
lot more time, memory, and typing to do what .empty() does.


-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On
Behalf Of Will Jessup
Sent: Tuesday, October 17, 2006 9:11 PM
To: jQuery Discussion.
Subject: [jQuery] List - getting children

Hello list,

Have a question about how to grab elements that were put into the DOM w/
.append().

For example,


  one
   two 


Then i do this in javascript

$("#links").children().remove(); //removes the divs with "one" and "two"
  var data = [one, two ]
for (var i=0; i < data.length; i++) {
   $("#links").append(data[i][0]);
 }

Then try to select them again,

$("#links").children();

Returns nothing
So how do i get it to return the appended items?



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


Re: [jQuery] Mouseover/out + CSS background image behavior change in IE between r

2006-10-17 Thread EJ12N

Hello, I believe this is IE background-image flickering problem you are
experiencing...
http://evil.che.lu/2006/9/25/no-more-ie6-background-flicker

In jQuery code...
//Stop IE flicker
if ($.browser.msie == true) {
document.execCommand('BackgroundImageCache', false, true);
}

-EJ


Prague Expat wrote:
> 
> Does JQuery try to refresh/reload any CSS on mouse events?  In my version
> of 
> IE (with JQuery rev 413) every mouseover/out is causing all my CSS 
> background images to quickly reload (but not quickly enough, as it is
> quite 
> noticeable).  I did not have this problem with rev 249 (I just updated to 
> 413 yesterday and noticed the strange behavior).
> 
> One more thing: the dev PC at work does not show a problem with IE with 
> either JQuery version. My home PC shows the problem with version 413 only. 
> At home, 249 works perfectly but fails as soon as I try the 413 version.
> 
> Is it possible that the memory leak fixes (that I understand are in the 
> updated JQuery) are causing quick refreshes on the CSS?
> 
> Thanks for any insight. Feel free to email be w/questions. pragueexpat
> (at) 
> hotmail.com
> 
> code:
> 
> $(document).ready(function(){
> //remove anchors in menu table tds - replace w/bkimg
>  $(".menuanchor").remove();
> 
> $("#menutab1").css({backgroundImage:"url(i/about.jpg)",cursor:"pointer"}).rb_menu();
> $("#menutab2").css({backgroundImage:"url(i/practice.jpg)",cursor:"pointer"}).rb_menu();
> $("#menutab3").css({backgroundImage:"url(i/offices.jpg)",cursor:"pointer"}).rb_menu();
> $("#menutab4").css({backgroundImage:"url(i/tech.jpg)",cursor:"pointer"}).rb_menu();
> $("#menutab5").css({backgroundImage:"url(i/patients.jpg)",cursor:"pointer"}).rb_menu();
> $(".links").click(function(){window.location=this.id+".php"});
> $("#logo").click(function(){window.location="/bho/index.php"});
> $("#newsbody").height($("#contentcol2").height()-111+"px");});$.fn.rb_menu
> = function(options) {var self = this;this.options = {//
> transitions: easein, easeout, easeboth, bouncein, bounceout,//
>  
> bounceboth, elasticin, elasticout, elasticbothtransition:   
> 'easein',// trigger events: mouseover, mousedown, mouseup, click,
> dblclicktriggerEvent:  'mouseover',// number of ms to
> delay before hiding menu (on page load)loadHideDelay : 500,   
> // number of ms to delay before hiding menu (on mouseout)   
> blurHideDelay:  500,// number of ms for transition effect   
> effectDuration: 500}// make sure to check if options are given!   
> if(options) {$.extend(this.options, options);}return
> this.each(function() {var menu = $("#drop"+this.id);   
> menu.closed = true;menu.hide();menu.hide = function() {   
> 
> if(menu.css('display') == 'block' && !menu.closed) {   
> menu.BlindUp(self.options.effectDuration, 
>   
> function() {menu.closed = true;   
> menu.unbind();},   
> self.options.transition);}  $(".dropmenu
> li").css("fontWeight","normal");}menu.show = function() { 
>   
> if(menu.css('display') == 'none' && menu.closed) {   
> menu.BlindDown(self.options.effectDuration,   
> 
> function() {menu.closed = false;  
>  
> menu.hover(function() {   
> clearTimeout(menu.timeout);}, function() {
>
> menu.timeout = setTimeout( function() {   
> menu.hide();}, self.options.blurHideDelay);   
> 
> });},self.options.transition  
>  
> );}   //highlight each li option on mouseover  
> $(".dropmenuli").mouseover(function(){$(this).css({fontWeight:"bold",color:"white",background:"#e6ccb3"});}).mouseout(function(){$(this).css({fontWeight:"normal",color:"#a0a0a0",background:"#f2e6da"});});
>
> }//show drop down when mouseover table tds   
> self.bind("mouseover", function() {  menu.show();});   
> //hide drop downs if mouseout of table tdsself.bind("mouseout",
> function() {  menu.timeout = setTimeout( function()
> {menu.hide();},self.options.blurHideDelay);});});};
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Mouseover-out-%2B-CSS-background-image-behavior-change-in-IE-between-rev-249-and-413-tf2460726.html#a6867990
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list

Re: [jQuery] jQuery API discussion

2006-10-17 Thread Steven Wittens
>
> The feasibility of 'namespacing' hasn't been brought up yet - but
> leave it to be said that it would be really really difficult and add a
> ton of overhead to the jQuery base as a whole (in order to continue
> chainability support).

Err... I made a rather concrete proposal for how namespacing could be  
implemented in my mail of 15 october. But no-one replied to that  
part :/.

Essentially, I think namespacing is preferable to prefixing because  
you don't need to repeat namespaces:

i.e.
$(...).onLoad().onMousemove().onClick().domAppend().domWhatever();
vs
$(...).on.load().mousemove().click().dom.append().whatever();

This sort of chainability is quite intuitive, and I think it is  
possible to achieve.


Steven Wittens


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


[jQuery] Replying to threads

2006-10-17 Thread Steven Wittens
Note.. please don't reply to existing threads when you're starting a  
new one. You make it harder to read mail for those of us with  
threaded mail-clients, as well as in the mailinglist archives.

Steven Wittens

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


[jQuery] jQuery API discussion

2006-10-17 Thread Andrea Ercolino
I think that there is space for improvement on both sides of API architecture and its documentation.
 
We all like jQuery for how it looks like. We like its chainability, we like its alchemy. So we must preserve what we like most as much as possible, and doing so we'll also get to an evolution as opposed to a revolution. 
 
Sorry for my pomposity.
 
 
API architecture
-
I'll leave this entirely in your hands, because my undestanding still needs to deepen more. 
 
Just one advice and one idea. Here goes the advice. People like to do things their way. So two ways of doing something, are always better than one. On this principle is based the most widespread software nowadays.
 
And here goes the idea. I noticed many posts in this thread about the events issue. I think that bind, undind and trigger, when specialized over a click event, for example, could all three be synthesized in only one function called click. I like overloading even if I know it adds mystery. Correctly used also helps keeping tidy. 
 
bind: click(function...)
trigger: click()
unbind: click(null)
 
This should be pretty clear to any programmer: unbind is like binding to nothing. If null cannot be used, any similar replacement will work: nothing, "", 0, undefined, {}; just choose (or make) one that fits.
Then there is the difference between one shot and burst mode. This could be coped with by adding an optional boolean (or enum) argument. 
 
This way a 6 functions will be compressed into only one name. wow
 
 
API documentation
--
There is an official documentation that comes right from the source with an XML to HTML clockwork. I'll speak about this one. 
 

Functionalities must be differentiated from functions.
Functionalities need a unique id number.
Functionalities need their own filecard.
Functionalities need not be spread among many filecards.
Pseudo-Signatures can be augmented to represent optional arguments and their default values.
Filecards must cross reference each other on an "as needed" basis, but also on a more regular basis, like a section for referencing similar functionalities, or a reference to the group of their common function name.
Keywords must be added to functionalities and "deprecated" should be a keyword.
Documentation must be made available through browsing, references, keywords, categories and searches.
Examples must be improved on many levels. (see my third post in my blog)
 
Here is something that goes towards what I mean: http://www.mondotondo.com/aercolino/jquery/docs/API/jquery-api2.xml
I only wrote again the documentation of the items with a number, whereas items with a # are original content.
 
And there are three posts in my blog with all the ideas and details: 
1: http://www.mondotondo.com/aercolino/noteslog/?p=42
2: http://www.mondotondo.com/aercolino/noteslog/?p=62
3: http://www.mondotondo.com/aercolino/noteslog/?p=65
 
 ___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] Radio button bug

2006-10-17 Thread Steven Wittens
I've found a rather tricky bug in jQuery 1.0.2. When you use an  
animated slideDown() or show() on an element containing one or more  
radio buttons, the radio buttons lose their selection status in  
Firefox (1.5 and 2.0 for sure, maybe others), and Opera 9 (maybe  
others). It works fine in IE6 and Safari 2. This also only seems to  
happen when you apply an animation for the first time.


I have attached a minimal test case to reproduce. There are four  
pairs of radiobuttons, each having one radio button selected. Their  
source markup is functionally identical. Clicking the provided link  
runs a different animation on each radio button pair: the first two  
pairs of radio buttons lose their selection, the last two work fine.


This is caused by the code in jQuery.css() used to measure the  
dimensions of elements that are hidden. jQuery temporarily replicates  
the element inside its parent. This causes two selected radio buttons  
with the same 'name' to appear in the form, which is not allowed. It  
seems that Firefox and Opera defensively remove both selections in  
this case.


One fix is to simply remove the checked attributes of all radio  
buttons inside the clone, before inserting it into the parent. See  
attached patch.


This is a major blocker for jQuery in Drupal by the way, as it can  
break any animated portion of a form. I'm going to patch our included  
copy after you guys review this patch (we have a release candidate  
coming up next monday), but it would be nice to see this fixed in a  
1.0.3 release soon ;).


Steven Wittens



jquery-radio-bug.patch
Description: Binary data


Title: jQuery Radio bug


  
  
Problem: when using some animations on an element containing one or more radio buttons, the radiobuttons will lose their selection in Firefox and Opera, the first time the animation is applied.
Click to trigger bug


  slideDown: Buggy
  


  

  animated show: Buggy
  


  

  fadeIn: Not Buggy
  


  

  instant show: Not Buggy
  


  


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


Re: [jQuery] Selectors [EMAIL PROTECTED]|=val] and [EMAIL PROTECTED] Have they been removed?

2006-10-17 Thread John Resig
Hi Choan -

> * Attribute selector [EMAIL PROTECTED] doesn't work (returns any
> element with a class name)
> * Attribute selector [EMAIL PROTECTED]|=en] doesn't work (returns any element
> with a hreflang attribute)
>
> Has the support for these selectors been removed?

Yes, I removed support for those selectors, since they're virtually
useless, in most respects. Finding an element by class is as simple
as:
foo.className

and the lang-related stuff seemed just silly - I've never seen an
actual, practical use for it. Were you attempting to use them for
something, or just curious?

--John

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


Re: [jQuery] List - getting children

2006-10-17 Thread Blair McKenzie
Don't those div blocks need quotes?On 10/18/06, Will Jessup <[EMAIL PROTECTED]> wrote:
Hello list,Have a question about how to grab elements that were put into the DOM w/.append().For example,  one   two 
Then i do this in _javascript_$("#links").children().remove(); //removes the divs with "one" and "two"  var data = "" >one, two ]
for (var i=0; i < data.length; i++) {   $("#links").append(data[i][0]); }Then try to select them again,$("#links").children();Returns nothing
So how do i get it to return the appended items?___jQuery mailing listdiscuss@jquery.com
http://jquery.com/discuss/
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] List - getting children

2006-10-17 Thread Will Jessup
Hello list,

Have a question about how to grab elements that were put into the DOM w/ 
.append().

For example,


  one
   two 


Then i do this in javascript

$("#links").children().remove(); //removes the divs with "one" and "two"
  var data = [one, two ]
for (var i=0; i < data.length; i++) {
   $("#links").append(data[i][0]);
 }

Then try to select them again,

$("#links").children();

Returns nothing
So how do i get it to return the appended items?





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


Re: [jQuery] Form plugin revisited ;-)

2006-10-17 Thread Mike Alsup
> Thanks for catching that!  I totally missed that the 'get's weren't
> working and that the 'get' was not augmenting the url.  I'll have to
> improve my unit tests!
>
> I'll be committing the form plugin to svn within the next day or two.

All,

The form plugin has been updated in svn.  It now includes the changes
discussed earlier on this thread along with the 'GET' bug fix that
Klaus pointed out.

The big change to be aware of is that the "serialize" method now
returns a '&' delimited string suitable for posting/getting.  The
"formToArray" method returns an array of objects which represent the
form data (full documentation inline).

Also worth noting is that the "target" argument to "ajaxSubmit" and
"ajaxForm" can now be a jQuery selector string, a jQuery object, or a
DOM element.

As always, sample usage can be found at:

http://malsup.com/jquery/form/

Thanks to everyone for all the good discussion and good ideas.

Mike

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


Re: [jQuery] Is there a way to reply to someone's post...

2006-10-17 Thread Blair McKenzie
You could use the Nabble archive of the list. I believe it allows you to set up an account and post emails to threads from your own email address.Blair
On 10/18/06, Andrea Ercolino <[EMAIL PROTECTED]> wrote:
Adrian,
 
I don't have access to the headers because I don't have the email message at all. I'm subscribed to the list so I can post, if I want to. But I unchecked the service of the mailer program at jQuery, so I'm actually not receiving any message to my inbox. I found that browsing the archives is much more effective to me. IMO this is an option that should be promoted because it saves bytes to everyone involved.

 
As I suggested, all posts to discuss@jquery.com get an id, which is then represented as the last item in the link to the message. For example my first message about this issue got 014492 and your reply got 014497. This is a very simple Id to retrieve. 

 
If I had had the option to reply to your reply by specifying a Subject like "014497; Is there a way - Adrian", and have my message properly threaded below yours, then discussions would be much easier to read through. And my sent messages would get a Subject which would also be easy to categorize here, inside my mail program.

 
Spam should not be an issue, because the mailer at jQuery will filter out all messages not coming from subscribers anyway.
 
___jQuery mailing listdiscuss@jquery.com
http://jquery.com/discuss/
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] problem iwith leadiing space in IE

2006-10-17 Thread Brandon Aaron
You can just call $.trim on the string. Just to change this line:
text = "html/"+$(this).text()+".html"; /*read out text from
to this:
text = "html/"+$.trim($(this).text())+".html"; /*read out text from

Perhaps $().text() should call this for you. Does anyone see a reason
why $().text() shouldn't call $.trim() on the result?

--
Brandon Aaron

On 10/17/06, Angelo Sozzi <[EMAIL PROTECTED]> wrote:
>
> Hi,
> I just started  using JQuery and I'm amazed how simple things can be done...
> Unfortunately I've run into an IE issue (I think). Im using an UL list for
> A-Z links (large site). I try to read out the LI elements and use them to
> generate the path to the html file  (E.g. A.html from A.
>
> This seems to work fine in FF, but in IE I end up with a filename of 'A
> .html' (note the space):
>
> Demo: (only A and B load data) using V.249
> http://www.sozzi.cn/jquery/fish_ajax_3.html
>
> The alert poping up just outputs the generated filename:
> the "offending" line of code is:
>
> text = "html/"+$(this).text()+".html"; /*read out text from
> text and make filename from it*/
>
>
> any way to solve this easily? I just found some regex solutions I don't
> quite understand.
>
> Thanks a lot
>
> Angelo
> --
> View this message in context: 
> http://www.nabble.com/problem-iwith-leadiing-space-in-IE-tf2461879.html#a6863015
> 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.css function poor performance

2006-10-17 Thread Brandon Aaron
Would it be possible for you to post a link so that we can see it or
at least maybe just a test case?

--
Brandon Aaron

On 10/17/06, Raziel Alvarez <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I'm performing css manipulation in my application, but the performance
> degrades considerably fast as more markup is added. I tracked the problem to
> the jQuery.css function, specifically for those cases where I'm setting the
> width and height. Even small additions to the markup inside of the container
> to which I want to set the width and height produce a big increase in the
> delay of such function.
>
> I took a quick look at the implementation and they seem to be special cases,
> and since I don't quite get the logic inside I don't feel comfortable
> changing it.
>
> My application is getting to the point of being useless because of the
> delay. Is there a plan to fix this in the next release? Is there any way
> this can be improved meanwhile?
>
> Regards,
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>
>
>

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


[jQuery] problem iwith leadiing space in IE

2006-10-17 Thread Angelo Sozzi

Hi,
I just started  using JQuery and I'm amazed how simple things can be done...
Unfortunately I've run into an IE issue (I think). Im using an UL list for
A-Z links (large site). I try to read out the LI elements and use them to
generate the path to the html file  (E.g. A.html from A.

This seems to work fine in FF, but in IE I end up with a filename of 'A
.html' (note the space):

Demo: (only A and B load data) using V.249
http://www.sozzi.cn/jquery/fish_ajax_3.html

The alert poping up just outputs the generated filename:
the "offending" line of code is:

text = "html/"+$(this).text()+".html"; /*read out text from
text and make filename from it*/


any way to solve this easily? I just found some regex solutions I don't
quite understand.

Thanks a lot

Angelo
-- 
View this message in context: 
http://www.nabble.com/problem-iwith-leadiing-space-in-IE-tf2461879.html#a6863015
Sent from the JQuery mailing list archive at Nabble.com.


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


Re: [jQuery] Selectors [EMAIL PROTECTED]|=val] and [EMAIL PROTECTED] Have they been removed?

2006-10-17 Thread Blair McKenzie
Have you tried putting quotes around the values (ie en, es, fill-0)?BlairOn 10/18/06, Choan C. Gálvez <
[EMAIL PROTECTED]> wrote:Hi all.While playing with CSS selectors, I've found some strange things (I'm
using the SVN version, rev 445):* Attribute selector [EMAIL PROTECTED] doesn't work (returns anyelement with a class name)* Attribute selector [EMAIL PROTECTED]|=en] doesn't work (returns any elementwith a hreflang attribute)
Has the support for these selectors been removed?This is what I'm using for testing:HTML:pare-0, fill-0 pare-1 href="">No class, 
jQuery:$("[EMAIL PROTECTED]|=en]").length; // 2, should be 1$("[EMAIL PROTECTED]|=es]").length; // 2, should be 1$("[EMAIL PROTECTED]").length; // 2, shoul be 1--Choan
___jQuery mailing listdiscuss@jquery.com
http://jquery.com/discuss/
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] Is there a way to reply to someone's post...

2006-10-17 Thread Andrea Ercolino
Adrian,
 
I don't have access to the headers because I don't have the email message at all. I'm subscribed to the list so I can post, if I want to. But I unchecked the service of the mailer program at jQuery, so I'm actually not receiving any message to my inbox. I found that browsing the archives is much more effective to me. IMO this is an option that should be promoted because it saves bytes to everyone involved.
 
As I suggested, all posts to discuss@jquery.com get an id, which is then represented as the last item in the link to the message. For example my first message about this issue got 014492 and your reply got 014497. This is a very simple Id to retrieve. 
 
If I had had the option to reply to your reply by specifying a Subject like "014497; Is there a way - Adrian", and have my message properly threaded below yours, then discussions would be much easier to read through. And my sent messages would get a Subject which would also be easy to categorize here, inside my mail program.
 
Spam should not be an issue, because the mailer at jQuery will filter out all messages not coming from subscribers anyway.
 ___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Thickbox "Extensions" - Dialog & Monolog [REPOST]

2006-10-17 Thread bbuchs

Good catch. I'll add a "blur()" to the links in my demo.

I'm re-thinking the Confirm Dialog. Should the function return true/false
instead of accepting the callback? Now that I think about it, I don't know
why I did it that way...




Very nice extension of the excellent thickbox.

I noticed that the activation link still has focus after the thickbox is
displayed. If you then hit return with this focus, it appears the thickbox
contents are duplicated.

For an example, see  http://www.nabble.com/file/3729/DoubleContents.JPG This
Image 

jk


bbuchs wrote:
> 
> Demos and source files are available at:
> 
> http://bryanbuchs.com/tb_dialog/
> 
> Feedback & Suggestions welcomed.
> 
>   - Bryan
> 



-- 
View this message in context: 
http://www.nabble.com/Thickbox-%22Extensions%22---Dialog---Monolog--REPOST--tf2455591.html#a6866503
Sent from the JQuery mailing list archive at Nabble.com.


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


[jQuery] Request for assistance: Wrapping div's aroiund structural markup

2006-10-17 Thread Greg Bird

Hi everyone.

I am attempting to develop some dynamic "in page" navigation.  I am a big
fan of structural markup. Each H2 represents a new section of the current
document.

I wish to:
1.  Find each H2
2.  Wrap this in a unique div, up to (but not including) the next H2.  This
will then be used to further manipulate the page






First section
 ...[arbitary HTML]



second section
 ...[arbitary HTML]

third section
.


Here is the JQuery that I have developed to date:

$(document).ready(function(){
  BuildNav();
});
/*BUILD SIDE NAVIGATION*/
function BuildNav() {
//add back to top links before each H2
$('#content h2').each(function(i){  
if(i==0){//FIRST H2 
$(this).before('')//START A NEW DIV WITH
UNIQUE ID
}
else {  
$(this).before('');//TERMINATE
PREVIOUS DIV, BEGIN NEW ONE
}
})
$('#content').append('');//TERMINATE FINAL DIV
}

This looks sensible to me but fails.  It appears you cannot inject
unterminated tags and that JQUERY automatically closes tags on insertion,
resulting in:


First section
...[arbitary HTML]

second section
...[arbitary HTML]

third section
  .


Can anyone give me any clues?   Thanks in advance, Greg Bird



-- 
View this message in context: 
http://www.nabble.com/Request-for-assistance%3A--Wrapping-div%27s-aroiund-structural-markup-tf2449875.html#a6828385
Sent from the JQuery mailing list archive at Nabble.com.


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


Re: [jQuery] ThickBox in Filemanager

2006-10-17 Thread Olaf Bosch
Klaus Hartl schrieb:

> putting an xml declaration on top doesn't make it xml automagically. 
> mime type matters.

mime type is on Apache corect:

application/xml xml xsl

copy from mime.types

the Header are:
--
Antwort-Header - http://sitemap.xml

Date: Tue, 17 Oct 2006 22:56:11 GMT
Server: Apache/2.0.54 (Debian GNU/Linux) PHP/4.4.4-0.dotdeb.1
Last-Modified: Sun, 15 Oct 2006 18:03:17 GMT
Etag: "f4dc002-e1b5-55f20340"
Accept-Ranges: bytes
Content-Length: 57781
Content-Type: application/xml

200 OK

-- 
Viele Grüße, Olaf

---
[EMAIL PROTECTED]
http://olaf-bosch.de
www.akitafreund.de
---

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


[jQuery] Jquery.css function poor performance

2006-10-17 Thread Raziel Alvarez
Hi,
 
I'm performing css manipulation in my application, but the performance degrades considerably fast as more markup is added. I tracked the problem to the jQuery.css function, specifically for those cases where I'm setting the width and height. Even small additions to the markup inside of the container to which I want to set the width and height produce a big increase in the delay of such function. 

 
I took a quick look at the implementation and they seem to be special cases, and since I don't quite get the logic inside I don't feel comfortable changing it.
 
My application is getting to the point of being useless because of the delay. Is there a plan to fix this in the next release? Is there any way this can be improved meanwhile?
 
Regards,
 
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Mouseover/out + CSS background image behavior change in IE between rev 249 and 413

2006-10-17 Thread Brandon Aaron
On 10/17/06, Prague Expat <[EMAIL PROTECTED]> wrote:
> Is it possible that the memory leak fixes (that I understand are in the
> updated JQuery) are causing quick refreshes on the CSS?

This is doubtful as the code that fixes the memory leak only runs at unload.

--
Brandon Aaron

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


Re: [jQuery] ThickBox in Filemanager

2006-10-17 Thread Michael Geary
> Well, as I've already said, you won't be able to show the PDF 
> in a thickbox, because the OS/browser will catch the link and 
> try to open it using the default action set in the browser or 
> OS, and there's nothing that you can do to override it. If no 
> default action is set, then you -might- be able to open it in 
> the browser. But let's be honest, the percentage of users 
> without a PDF reader is pretty small (probably the same 
> percentage as those browsing the web on an Amiga 1200. :-)
> 
> As far as I know, there is no ability to read PDF's inline 
> like you're trying to do, and trying to force PDFs to open in 
> a small window just isn't practical, and users won't like it 
> if you force it upon them.

If you can load HTML into the thickbox, you can easily load a PDF file.
Simply use an iframe or object tag. For some examples:

http://www.google.com/search?num=100&q=pdf+iframe

http://www.google.com/search?num=100&q=pdf+%22object+tag%22

-Mike


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


Re: [jQuery] Is there a way to reply to someone's post...

2006-10-17 Thread Adrian Sweeney
if you look at the headers of the email you can probably find the
headers that are required for your email to appear in the thread I think
that each email will have a UID for it and you would also need to supply
that.
On Tue, 2006-10-17 at 14:49 -0700, Andrea Ercolino wrote:
> without using the Reply button in a mail program?
>  
> I've disabled that checkbox in my jQuery profile for
> receiving messages from the list. I really prefer to browse the
> archives. But for replying specifically to someone's post, what can I
> do? Opening a new thread with the old subject is my unique option? 
>  
> If there is no other option, could someone apply a little patch for
> making it possible to use a special Subject for this purpose? I'm sure
> it could be done in jQuery! A simple script for reorganizing the
> archive page by thread, based on a Subject like "014226; jQuery API
> discussion - Jörn Zaefferer". Where the first number is the message I
> want to reply to, and the remaining text is just for me, and should be
> discarded.
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/





___ 
All new Yahoo! Mail "The new Interface is stunning in its simplicity and ease 
of use." - PC Magazine 
http://uk.docs.yahoo.com/nowyoucan.html


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


Re: [jQuery] ThickBox in Filemanager

2006-10-17 Thread Klaus Hartl


Olaf Bosch schrieb:
> Dragan Krstic schrieb:
>> Try to put xml definition in your xml file on begining. Without it, browser
>> parse it like ordinary text file
> 
> What is to do? That is a google-sitemap, is valid
> 
> you mean this
> 
> 
> is exact so in first line


putting an xml declaration on top doesn't make it xml automagically. 
mime type matters.


-- klaus

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


Re: [jQuery] Thickbox "Extensions" - Dialog & Monolog [REPOST]

2006-10-17 Thread Rexbard

Very nice extension of the excellent thickbox.

I noticed that the activation link still has focus after the thickbox is
displayed. If you then hit return with this focus, it appears the thickbox
contents are duplicated.

For an example, see  http://www.nabble.com/file/3729/DoubleContents.JPG This
Image 

jk


bbuchs wrote:
> 
> Demos and source files are available at:
> 
> http://bryanbuchs.com/tb_dialog/
> 
> Feedback & Suggestions welcomed.
> 
>   - Bryan
> 

-- 
View this message in context: 
http://www.nabble.com/Thickbox-%22Extensions%22---Dialog---Monolog--REPOST--tf2455591.html#a6865404
Sent from the JQuery mailing list archive at Nabble.com.


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


Re: [jQuery] ThickBox in Filemanager

2006-10-17 Thread Olaf Bosch
Dan Atkinson schrieb:
> Well, as I've already said, you won't be able to show the PDF in a
> thickbox, because the OS/browser will catch the link and try to open
> it using the default action set in the browser or OS, and there's
> nothing that you can do to override it. If no default action is set,
> then you -might- be able to open it in the browser. But let's be
> honest, the percentage of users without a PDF reader is pretty small

Yes, i understand. In my Firefox works PDF in normal Links to. In
ThickBox works that not for me :(

> As far as I know, there is no ability to read PDF's inline like
> you're trying to do, and trying to force PDFs to open in a small
> window just isn't practical, and users won't like it if you force it
> upon them.

Yes, is not good, here is not so important, this come in a Backend of a
CMS. For the Redaction is o.k., never will see the PDF in Filemanager to
often :)

I have the Window set to resizable, is better



-- 
Viele Grüße, Olaf

---
[EMAIL PROTECTED]
http://olaf-bosch.de
www.akitafreund.de
---

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


Re: [jQuery] ThickBox in Filemanager

2006-10-17 Thread Olaf Bosch
Dragan Krstic schrieb:
> Try to put xml definition in your xml file on begining. Without it, browser
> parse it like ordinary text file

What is to do? That is a google-sitemap, is valid

you mean this


is exact so in first line

-- 
Viele Grüße, Olaf

---
[EMAIL PROTECTED]
http://olaf-bosch.de
www.akitafreund.de
---

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


[jQuery] Is there a way to reply to someone's post...

2006-10-17 Thread Andrea Ercolino
without using the Reply button in a mail program?
 
I've disabled that checkbox in my jQuery profile for receiving messages from the list. I really prefer to browse the archives. But for replying specifically to someone's post, what can I do? Opening a new thread with the old subject is my unique option? 
 
If there is no other option, could someone apply a little patch for making it possible to use a special Subject for this purpose? I'm sure it could be done in jQuery! A simple script for reorganizing the archive page by thread, based on a Subject like "014226; jQuery API discussion - Jörn Zaefferer". Where the first number is the message I want to reply to, and the remaining text is just for me, and should be discarded.___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] ThickBox in Filemanager

2006-10-17 Thread Dan Atkinson

Well, as I've already said, you won't be able to show the PDF in a thickbox,
because the OS/browser will catch the link and try to open it using the
default action set in the browser or OS, and there's nothing that you can do
to override it. If no default action is set, then you -might- be able to
open it in the browser. But let's be honest, the percentage of users without
a PDF reader is pretty small (probably the same percentage as those browsing
the web on an Amiga 1200. :-)

As far as I know, there is no ability to read PDF's inline like you're
trying to do, and trying to force PDFs to open in a small window just isn't
practical, and users won't like it if you force it upon them.

At the end of the day, I'm really not sure that you can override the
browsers default file actions because it borders on security (for example,
if this wasn't true, what's to stop a malicious programmer from malforming
JS to open executables without your permission?).


Olaf wrote:
> 
> Dan Atkinson schrieb:
>> I'm not sure how it all works fine if it doesn't work at all...
> 
> Oh, sorry.
> 
> I work on the Script. I have mutch change.
> 
> 1 Demo says more than 1000 (english) Words  ;)
> Look this:
> http://olaf-bosch.de/bugs/jquery/fileman/
> 
> Works fine with this Types what i have say what to do in the jquer_box.js
> 
> Now i search for a method to call all other types.
> For this is enough a Alert.
> 
> Can help?
> 
> 
> -- 
> Viele Grüße, Olaf
> 
> ---
> [EMAIL PROTECTED]
> http://olaf-bosch.de
> www.akitafreund.de
> ---
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/ThickBox-in-Filemanager-tf2455670.html#a6864654
Sent from the JQuery mailing list archive at Nabble.com.


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


Re: [jQuery] ThickBox in Filemanager

2006-10-17 Thread Dragan Krstic
Try to put xml definition in your xml file on begining. Without it, browser parse it like ordinary text file2006/10/17, Olaf Bosch <[EMAIL PROTECTED]
>:Dan Atkinson schrieb:> I'm not sure how it all works fine if it doesn't work at all...
Oh, sorry.I work on the Script. I have mutch change.1 Demo says more than 1000 (english) Words  ;)Look this:http://olaf-bosch.de/bugs/jquery/fileman/
Works fine with this Types what i have say what to do in the jquer_box.jsNow i search for a method to call all other types.For this is enough a Alert.Can help?--Viele Grüße, Olaf
---[EMAIL PROTECTED]http://olaf-bosch.dewww.akitafreund.de
---___jQuery mailing listdiscuss@jquery.comhttp://jquery.com/discuss/
-- Dragan Krstić krdrhttp://krdr.ebloggy.com/
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] numeric plugin and the minus sign

2006-10-17 Thread Adrian Sweeney
Ok the problem with this plugin is that you can only specify a minus
sign when the string length is zero,  but since the code only allows
numbers, decimal places and the minus sign to be entered we can assume
that the if the length of the string is greater than zero that it is a
valid number so if we multiply it by -1 we will negate it thus if you
cursor in at any position in the number the minus key will make the
number a minus number.

Now if you remove the "if (this.value*1 >0){" condition then you can
toggle the number to be a positive/negative value using the minus sign

Ok so from a usability point of view this would probably never be used
ie if someone wanted to make the number a negative number they would
probably move te cursor to the start of the number and hit the minus
key. but since we don't really care if the cursor is at the start or not
we can do the work for them

--- the code ---

find the following 2 lines in the numeric plugin 
- code 
/* '-' only allowed at start */
if(key == 45 && this.value.length == 0) return true;
- /code ---
and add the follwoing block of code

- code 
/* '-' make number negative */
if(key == 45){
if(this.value.length != 0) {
// remove this next line to toggle between negative and
positive numbers
if (this.value*1 >0){
this.value = this.value * -1;
return false;
}
}
}

- /code ---





___ 
All new Yahoo! Mail "The new Interface is stunning in its simplicity and ease 
of use." - PC Magazine 
http://uk.docs.yahoo.com/nowyoucan.html


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


Re: [jQuery] ThickBox in Filemanager

2006-10-17 Thread Olaf Bosch
Dan Atkinson schrieb:
> I'm not sure how it all works fine if it doesn't work at all...

Oh, sorry.

I work on the Script. I have mutch change.

1 Demo says more than 1000 (english) Words  ;)
Look this:
http://olaf-bosch.de/bugs/jquery/fileman/

Works fine with this Types what i have say what to do in the jquer_box.js

Now i search for a method to call all other types.
For this is enough a Alert.

Can help?


-- 
Viele Grüße, Olaf

---
[EMAIL PROTECTED]
http://olaf-bosch.de
www.akitafreund.de
---

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


[jQuery] Highlighting jQuery

2006-10-17 Thread Andrea Ercolino
Hola.
 
I was quite sure that Chili did not work in Safari, very sorry for that, but I have no means for testing Safari on a PC, or am I wrong?
 
Using my PC, I tested Chili on IE, Firefox, Mozilla and Opera, all latest versions, and it works fine. The first three browsers show the highlighting identically, but Opera adds one empty line after each line. I'll try to fix this in the near future.
 
As for Safari, I don't know anything about it. If someone wants to help me with this issue, I'll be very glad to add a fix asap.
 
Ciao,
Andrea
 ___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] parent() modifies original object

2006-10-17 Thread Dave Methvin
I think we are talking about two different effects here. This can definitely
be subtle so it's good to have someone ask the question.

> var cell = $(e);
> var cellParent = cell.parent();
> var cellParent2 = cell.parent();
> ...
> Further digging seems to hint at the fact that every time 
> cell.parent() is called, it's the equivalent of cell = cell.parent()
> and as such the original value of cell is lost.

Most jQuery methods are designed to be chainable; they return the original
object as the return value so that a subsequent method can be called on it.
That is true of the .parent() method. So what's happening is that you have
created three different aliases for the same object! The two .parent()
method calls are modifying the internal state of the *same* jQuery object
and returning that object back to you. It's the internal state of the jQuery
object that remembers the selected nodes, not the return value.

To create a brand new jQuery object that contains the parent, without
changing the jQuery object with cell, you could use one of these:

var cell = $(e);
// Copy cell object and then get parent in the copied object
var cellParent = $(cell).parent();
 // XPath expr navigates to parent using cell as the context
var cellParent2 = $("..", cell); 

The $(cell) usage for creating a copy of a jQuery object is described in the
documentation for $(), but navigating the jQuery site I had a hard time
finding the XPath documentation to explain the second example. 

"Destructive" methods like .parent() that change the jQuery object's
selected nodes always push the previous list of selected nodes onto an
internal stack that can be popped with the .end() method. So in the case
above, the jQuery object stored in cellParent has a pushed copy of the DOM
node selected by cell (the same DOM node originally passed in by e) that you
can get to if you use .end(). The problem you originally mentioned above
would have occurred whether destructive methods worked this way or not. It's
just a difference of whether the object "stacked" the previous (two) sets of
nodes. 

> Maybe someone can shed some light on specific situations where
> the destructive method saves considerable amounts of code.
> I can definitely see how it'd be useful--do some work on the parent,
> then end(), then do some work on the element itself--but is this
> functionality used frequently?

It's useful when you get comfortable with chaining because it avoids having
to declare and use extra variables. I would actually prefer an explicit
push/pop approach myself because the creation of the stacked nodes is too
implicit and the stacked node references are cumbersome to eliminate if you
don't want them.

Sounds like this was (painfully!) reduced from some more complex code. Maybe
there is a jQuery-ish way to do it? You can avoid trouble with aliases if
you chain methods, since you aren't storing the object in a variable. 


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


Re: [jQuery] jQuery API discussion

2006-10-17 Thread Raffael Luthiger
Klaus Hartl wrote:
> Of course you still have know that you have to pass a function reference 
> of some kind to click() and the like, but if you want to use an API you 
> should get familiar with it by reading the documentation to a certain 
> extend, be it a designer or a programmer. Fortunately jQuery has a 
> pretty good documentation.

In my opinion (as a programmer) the documentation is pretty good. But I 
can understand very well that a designer could have some problems 
getting into the language. I've been reading now the first two tutorials 
again and tried to look at them as a designer. I can imagine very well 
that a designer has some problems to understand them if already in one 
of the first sentences the expression "... we start adding events 
etc..." appears. I guess a designer does not know what events are.

The question is, should the 'beginner tutorials' cover only jQuery or JS 
in general as well?

As I said the documentation is good enough for me and I say thank you to 
everyone who wrote something. But I can understand very well if people 
without good programming knowledge have problems getting into jQuery.

-- Raffael

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


Re: [jQuery] best show/hide div code?

2006-10-17 Thread Andy Matthews
Anyone have an idea on this one? I've tried a few things, but I'm not sure
how to reference a specific value in a select control.



-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Behalf Of Andy Matthews
Sent: Tuesday, October 17, 2006 10:39 AM
To: [jQuery]
Subject: [jQuery] best show/hide div code?


I'm working on a mailing list manager and one of the options is to provide a
zip code for emailing anyone in that area. I'd like to hide this field
unless the user has selected the "Tour Date" option from a select field.

The relevant code is below. The second TR (and it's contents) will be hidden
by default using CSS, but I want to toggle it's display property when the
user selects or deselects the "event" option in the "type" dropdown field.



Mailing Type


General Announcement
BCC Store Announcement
Clowndergarten Announcement
Event Announcement




Zip Code of eventfor event announcement only




How would I do this with jQuery?




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


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


Re: [jQuery] parent() modifies original object

2006-10-17 Thread Peter Woods
I thought I'd read somewhere on here about functions being
destructive, but I wasn't sure hence the question. While it makes
sense when you're doing crazy chained method calls, I think it's very
unintuitive during regular use of the parent() method, especially
because there's nothing which signifies in the method call that it is
indeed destructive (such as in Ruby or Scheme where you have set! or
what not). It's also not noted in the API... which is definitely an
oversight no matter how you look at it.

Maybe someone can shed some light on specific situations where the
destructive method saves considerable amounts of code. I can
definitely see how it'd be useful--do some work on the parent, then
end(), then do some work on the element itself--but is this
functionality used frequently? I think it makes perfect sense for
filter(), but even so, I think it should be made clear in some way or
another that a function you're calling is destructive, otherwise it
can create the incredibly confusing behavior I demonstrated above
unless you're made explicitly aware that it's not doing what you think
it's doing.

Thanks for the answer nonetheless, and I apologize in advance to John
and Jörn if this has been discussed to death before!

Cheers!
~Peter

On 10/17/06, Jörn Zaefferer <[EMAIL PROTECTED]> wrote:
> Peter Woods schrieb:
> > I'm not sure if this is the way it's supposed to work, but this makes
> > absolutely no sense to me as far as implementation goes. If I have
> > code like this: [...]
> >
> > Instead of printing the equivalent of: $(e).id(), $(e).parent().id(),
> > and $(e).parent().parent().id(), it prints $(e).parent.parent.id()
> > three times. Further digging seems to hint at the fact that every time
> > cell.parent() is called, it's the equivalent of cell = cell.parent()
> > and as such the original value of cell is lost.
> >
> > Is this behavior intentional, or is it a bug? It seems quite
> > counterintuitive to me, and while in the dumbed-down example above it
> > makes more sense to use $(e).parent() instead of cell.parent(), I find
> > it more intuitive to use cell.parent() in other instances and thus
> > discovered this behavior.
> It is intentional. parent() is a destructive operation on the jQuery
> object like filter(), find() etc. and can be reverted with end().
>
> There is the concept to pass an additional function to all desctructive
> operations: That function is executed for the modified stack and then
> returns an unmodified object. Maybe the discussion should be started
> again... There were several votes that said it would be unintuitive if a
> single method is once destructive and once it is not because an
> additional function is passed... What do you think?
>
> -- Jörn
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>

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


Re: [jQuery] parent() modifies original object

2006-10-17 Thread Jörn Zaefferer
Peter Woods schrieb:
> I'm not sure if this is the way it's supposed to work, but this makes 
> absolutely no sense to me as far as implementation goes. If I have 
> code like this: [...]
>
> Instead of printing the equivalent of: $(e).id(), $(e).parent().id(), 
> and $(e).parent().parent().id(), it prints $(e).parent.parent.id() 
> three times. Further digging seems to hint at the fact that every time 
> cell.parent() is called, it's the equivalent of cell = cell.parent() 
> and as such the original value of cell is lost.
>
> Is this behavior intentional, or is it a bug? It seems quite 
> counterintuitive to me, and while in the dumbed-down example above it 
> makes more sense to use $(e).parent() instead of cell.parent(), I find 
> it more intuitive to use cell.parent() in other instances and thus 
> discovered this behavior.
It is intentional. parent() is a destructive operation on the jQuery 
object like filter(), find() etc. and can be reverted with end().

There is the concept to pass an additional function to all desctructive 
operations: That function is executed for the modified stack and then 
returns an unmodified object. Maybe the discussion should be started 
again... There were several votes that said it would be unintuitive if a 
single method is once destructive and once it is not because an 
additional function is passed... What do you think?

-- Jörn

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


[jQuery] Select Box Sorter

2006-10-17 Thread Yehuda Katz
I've created a really simple plugin that lets you do $("select").sortSelectBy("html").It automatically sorts by a jQuery function, so you can create your own and have it sort by that. For instance, I created a getCompany jQuery method below that extracts the company out of "Name (Company)". You could then do $("select").sortSelectBy("getCompany").
jQuery.fn.sortSelectBy = function(sort) {  return this.each
(function(i, self) {    sorted = jQuery("option", this).get().sort(function(a,b) { return (jQuery(a)[sort]() > jQuery(b)[sort]()) ? 1 : -1 })
    jQuery(this).empty().append(sorted)
  })}
jQuery.fn.getCompany = function() {  company = this.html().match(/\(([^\)]*)\)/)
  if(company) return company[1];}-- 
Yehuda KatzWeb Developer | Wycats Designs(ph)  718.877.1325
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Using javascript variable for "HASH"

2006-10-17 Thread Michael Geary
> I imagine that it must be some way to use javascript variable 
> for "HASH"... Is it possible? 
> I show you the code that I'm using (and it show me an error 
> in FireBug (Firefox):reference to undefined property "imts"): 
> 
> function LoadAjax(t,d,id){
> var itms
> itms='{url: "GetValues'+t+'.asp", type: "POST", ';
> itms+='data: "'+d+'"';
> itms+='success: function(req) {AjaxOk(req,"'+id+'");},';
> imts+='error: AjaxError}';
>   $.ajax(itms);
> }

It looks like this is what you are trying to do:

function LoadAjax( t, d, id ) {
   var itms = {
  url: 'GetValues' + t + '.asp',
  type: 'POST',
  data: d,
  success: function( req ) { AjaxOk( req, id ); },
  error: AjaxError
   };
   $.ajax( itms );
}

-Mike


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


Re: [jQuery] Bug with AjaxStart

2006-10-17 Thread sdkester

I feel your pain, same here. According to this 
http://jquery.com/dev/bugs/bug/265/ bug , it has been fixed in SVN. I can
only assume this means that it will be fixed in the next release.


Mike Chabot wrote:
> 
> A bug was introduced somewhere between version 249 and 419 that broke
> the AjaxStart / AjaxStop functions. I was displaying a loading image
> using code straight out of the API doc that stopped working as soon as
> I put in a the current JQuery file.
> $("#loading").ajaxStart(function(){ $(this).show(); });
> $("#loading").ajaxStop(function(){ $(this).hide(); });
> If I change the function to be a simple alert, the alert does not fire
> either, which indicates that it is a problem with the ajaxStart call
> and not the show/hide calls.
> 
> -Mike Chabot
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Bug-with-AjaxStart-tf2461732.html#a6862750
Sent from the JQuery mailing list archive at Nabble.com.


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


[jQuery] Bug with AjaxStart

2006-10-17 Thread Mike Chabot
A bug was introduced somewhere between version 249 and 419 that broke
the AjaxStart / AjaxStop functions. I was displaying a loading image
using code straight out of the API doc that stopped working as soon as
I put in a the current JQuery file.
$("#loading").ajaxStart(function(){ $(this).show(); });
$("#loading").ajaxStop(function(){ $(this).hide(); });
If I change the function to be a simple alert, the alert does not fire
either, which indicates that it is a problem with the ajaxStart call
and not the show/hide calls.

-Mike Chabot

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


Re: [jQuery] jquery snapshots

2006-10-17 Thread Brian Miller
Which begs the question: Why NOT generate a nightly build?  It should take
all of 5 minutes to edit the crontab to make it happen.  :)

> Not nightly, but updated now and then: http://jquery.com/src/jquery-svn.js
>
> -- Jörn


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


Re: [jQuery] Highlighting jQuery

2006-10-17 Thread Abdur-Rahman Advany
Andrea,

Did you get permission from Dan to release this? I looked at this a few 
days ago and saw it was not released under open source licence.. but I 
might be wrong...

Adbul

Luke Lutman wrote:
> Looks interesting, but the example pages crash Safari (2.0.4, OSX 10.4) :-(
>
> Luke
>
> Andrea Ercolino wrote:
>   
>> Hola.
>>  
>> I just released Chili, a free syntax highlighter script, written in 
>> jQuery, and based on the Dan Webb's Code Highlighter, which I found a 
>> couple of weeks ago thanks to a link on the jQuery site.
>>  
>> Chili is compatible with Code Highlighter's language definition files, 
>> but it is othwerwise a new piece of software (re-engineered and fixed), 
>> fully documented, and really based on jQuery functionalities.
>>  
>> I posted a zip file with all inside and put the manual and two examples 
>> one click away. http://www.mondotondo.com/aercolino/noteslog/?cat=8
>>  
>> The example "Chili highlighting jQuery" shows how Chili can be used for 
>> highlighting jQuery scripts.
>>  
>>  
>> Hasta pronto,
>> Andrea
>>  
>>
>>
>> 
>>
>> ___
>> jQuery mailing list
>> discuss@jquery.com
>> http://jquery.com/discuss/
>> 
>
>
>   


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


Re: [jQuery] Highlighting jQuery

2006-10-17 Thread Luke Lutman
Looks interesting, but the example pages crash Safari (2.0.4, OSX 10.4) :-(

Luke

Andrea Ercolino wrote:
> Hola.
>  
> I just released Chili, a free syntax highlighter script, written in 
> jQuery, and based on the Dan Webb's Code Highlighter, which I found a 
> couple of weeks ago thanks to a link on the jQuery site.
>  
> Chili is compatible with Code Highlighter's language definition files, 
> but it is othwerwise a new piece of software (re-engineered and fixed), 
> fully documented, and really based on jQuery functionalities.
>  
> I posted a zip file with all inside and put the manual and two examples 
> one click away. http://www.mondotondo.com/aercolino/noteslog/?cat=8
>  
> The example "Chili highlighting jQuery" shows how Chili can be used for 
> highlighting jQuery scripts.
>  
>  
> Hasta pronto,
> Andrea
>  
> 
> 
> 
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/


-- 
zinc Roe Design
www.zincroe.com
(647) 477-6016

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


Re: [jQuery] åäö doesn't wo rk with load/loadIfModified

2006-10-17 Thread Ⓙⓐⓚⓔ
since it's not really a full html file, you don't have a head just
stick it inside... if it doesn't work there, move it up top. if that
doesn't work make it a valid html file with ...

OR you can see if IIS has a place to set the encoding, (as Apache does
system wide, site wide, or directory wide).

On 10/17/06, badtant <[EMAIL PROTECTED]> wrote:
>
> where should i put that meta-tag? inside sida1.html?
>
> /niklas
>
>
> Ⓙⓐⓚⓔ wrote:
> >
> > your server is sending sida.html as simple ascii.
> > looks like an issue with iis!
> >
> > I bet if you slip a  tag in there... it can alter the encoding.
> >
> > but my advise is still "bite the bullet, go utf-8"
> >
> > my Mac  see those question marks as hex 00 0D 00 0D 00 0D 00 0D
> > the file in the zip has .
> > get -e http://www2.hemsida.net/badtant/tabs/sida1.html
> > Connection: close
> > Date: Tue, 17 Oct 2006 05:20:37 GMT
> > Accept-Ranges: bytes
> > ETag: "b044d3693eec61:9af"
> > Server: Microsoft-IIS/5.0
> > Content-Length: 30
> > Content-Type: text/html
> > Last-Modified: Fri, 13 Oct 2006 06:44:26 GMT
> > Client-Date: Tue, 17 Oct 2006 05:10:34 GMT
> > Client-Peer: 212.37.5.72:80
> > Client-Response-Num: 1
> > X-Powered-By: ASP.NET
> >
> > Sida 1
> >
> > ??
> >
> >
> > On 10/12/06, badtant <[EMAIL PROTECTED]> wrote:
> >>
> >> here's my page:
> >> http://www2.hemsida.net/badtant/tabs/
> >>
> >> all files are ISO-8859-1
> >>
> >> and here's a zip with all the files:
> >> http://www2.hemsida.net/badtant/tabs/tabs.zip
> >>
> >>
> >> John Resig wrote:
> >> >
> >> > What's the encoding of the page that you're loading into? Do you have
> >> > a demo of the pages in action, so that we can verify the problem?
> >> >
> >> > --John
> >> >
> >> > On 10/12/06, badtant <[EMAIL PROTECTED]> wrote:
> >> >>
> >> >> come on? someone shouldknow something about this...
> >> >>
> >> >>
> >> >>
> >> >> badtant wrote:
> >> >> >
> >> >> > hi!
> >> >> >
> >> >> > i'm trying to use the ajax function loadIfModified to load an
> >> >> "extrernal"
> >> >> > html-file into a div.
> >> >> >
> >> >> > 
> >> >> >
> >> >> > $("#helptext").loadIfModified("help-sida1.html");
> >> >> >
> >> >> > in help-sida1.html i have the following code:
> >> >> > åäöÅÄÖ
> >> >> >
> >> >> > when i run the page i just get questionmarks. anyone who knows whats
> >> >> wrong
> >> >> > and what i can do about it?
> >> >> >
> >> >> >  http://www.nabble.com/file/226/error.jpg
> >> >> >
> >> >> >
> >> >> > my pages is ISO-8859-1. åäö loads correctly if i save help-sida1.htm
> >> as
> >> >> > UTF-8. but that's not an acceptable solution to me... i wan't my
> >> files
> >> >> to
> >> >> > be ISO-8859-1.
> >> >> >
> >> >>
> >> >> --
> >> >> View this message in context:
> >> >>
> >> http://www.nabble.com/-doesn%27t-work-with-load-loadIfModified-tf2355437.html#a6774742
> >> >> Sent from the JQuery mailing list archive at Nabble.com.
> >> >>
> >> >>
> >> >> ___
> >> >> jQuery mailing list
> >> >> discuss@jquery.com
> >> >> http://jquery.com/discuss/
> >> >>
> >> >
> >> >
> >> > --
> >> > John Resig
> >> > http://ejohn.org/
> >> > [EMAIL PROTECTED]
> >> >
> >> > ___
> >> > jQuery mailing list
> >> > discuss@jquery.com
> >> > http://jquery.com/discuss/
> >> >
> >> >
> >>
> >> --
> >> View this message in context:
> >> http://www.nabble.com/-doesn%27t-work-with-load-loadIfModified-tf2355437.html#a6790644
> >> 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/-doesn%27t-work-with-load-loadIfModified-tf2355437.html#a6849806
> 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] Highlighting jQuery

2006-10-17 Thread Erin Doak
Title: Re: [jQuery] Highlighting
jQuery


Your example
page(http://mondotondo.com/aercolino/chili/1.0_b/examples/1/chili-1.0-highlighting-chili-1.0.html) hangs Safari 2.04.

Erin


Hola.
 
I just released Chili, a free syntax
highlighter script, written in jQuery, and based on the Dan Webb's
Code Highlighter, which I found a couple of weeks ago thanks to a link
on the jQuery site.
 
Chili is compatible with Code
Highlighter's language definition files, but it is othwerwise a new
piece of software (re-engineered and fixed), fully documented, and
really based on jQuery functionalities.
 
I posted a zip file with all inside and
put the manual and two examples one click away. http://www.mondotondo.com/aercolino/noteslog/?cat=8
 
The example "Chili highlighting
jQuery" shows how Chili can be used for highlighting jQuery
scripts.
 
 
Hasta pronto,
Andrea
 


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


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


Re: [jQuery] jQuery API discussion

2006-10-17 Thread Klaus Hartl


Anders Schneiderman schrieb:
> Hi JornjQuer,
> 
> As a newbie, my impression is that overall it's a _lot_ simpler and sleeker 
> than say prototype.  And I love the compactness of the language.  However, 
> there are a few aspects that will throw off new folks -- particularly graphic 
> designers who don't have a programming background -- that they encounter 
> right from the beginning.  If more advanced features, which few people will 
> use until they've been working in jquery for a while, seem a bit arcane, 
> that's OK.  But to do almost anything, you run into code that looks like this:
> 
> 1 $(document).ready(function(){
> 2 $("a#shownote").click(function(){
> 3 $('#note').fadeIn("slow");
> 4 });
> 
> The first time I saw line 1, I had no clue what it was doing.  If all it's 
> doing is running some jquery before the page is loaded, there's _got_ to be a 
> more intuitive, succinct way to say it.
> 
> Ditto for line 2's click(function().  If I know CSS, I can guess what 
> a#shownote does.  I can guess what click does.  But function() { is just too 
> frikin' weird for a newbie designer who's not been a programmer.  
> 
> Readability for people who are relatively new is particularly poured in for 
> the world of JavaScript. 

Hi Anders,

although it seems to be a coding style most jQuerians have adopted, no 
one hinders you to do the following:

function showNote() {
 $('#note').fadeIn("slow");
}

function init() {
 $("a#shownote").click(showNote);
}

$(document).ready(init);

Of course you still have know that you have to pass a function reference 
of some kind to click() and the like, but if you want to use an API you 
should get familiar with it by reading the documentation to a certain 
extend, be it a designer or a programmer. Fortunately jQuery has a 
pretty good documentation.


-- Klaus

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


Re: [jQuery] jQuery API discussion

2006-10-17 Thread Anders Schneiderman
Hi JornjQuer,

As a newbie, my impression is that overall it's a _lot_ simpler and sleeker 
than say prototype.  And I love the compactness of the language.  However, 
there are a few aspects that will throw off new folks -- particularly graphic 
designers who don't have a programming background -- that they encounter right 
from the beginning.  If more advanced features, which few people will use until 
they've been working in jquery for a while, seem a bit arcane, that's OK.  But 
to do almost anything, you run into code that looks like this:

1   $(document).ready(function(){
2   $("a#shownote").click(function(){
3   $('#note').fadeIn("slow");
4   });

The first time I saw line 1, I had no clue what it was doing.  If all it's 
doing is running some jquery before the page is loaded, there's _got_ to be a 
more intuitive, succinct way to say it.

Ditto for line 2's click(function().  If I know CSS, I can guess what 
a#shownote does.  I can guess what click does.  But function() { is just too 
frikin' weird for a newbie designer who's not been a programmer.  

Readability for people who are relatively new is particularly poured in for the 
world of JavaScript.  Lots of people add a little JavaScript  to a page and 
then don't do much more coding for another couple of months.  

The easier it is for new folks to get started with jquery, the closer we are to 
JWD (Jquery World Domination).

Thanks,
Anders Schneiderman
Service Employees International Union

> -Original Message-
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On Behalf Of Jörn Zaefferer
> Sent: Sunday, October 15, 2006 1:32 PM
> To: jQuery Discussion.
> Subject: [jQuery] jQuery API discussion
> 
> Hi folks,
> 
> I'd like to discuss the jQuery API in general and the current 
> event API in detail:
> 
> For all newcomers: I'd like to hear about your first 
> impression of the jQuery API! This is invaluable for all 
> those geeks who spent way too much time with jQuery.
> 
> Regards
> JörnjQuer
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 

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


[jQuery] parent() modifies original object

2006-10-17 Thread Peter Woods
I'm not sure if this is the way it's supposed to work, but this makes absolutely no sense to me as far as implementation goes. If I have code like this:function someFunction( e ){var cell = $(e);var cellParent = 
cell.parent();var cellParent2 = cell.parent();alert("[" + cell.id() + "] [" + cellParent.id() + "] [" + cellParent2.id() + "]");}Instead of printing the equivalent of: $(e).id(), $(e).parent().id(), and $(e).parent().parent().id(), it prints $(e).parent.parent.id() three times. Further digging seems to hint at the fact that every time 
cell.parent() is called, it's the equivalent of cell = cell.parent() and as such the original value of cell is lost.Is this behavior intentional, or is it a bug? It seems quite counterintuitive to me, and while in the dumbed-down example above it makes more sense to use $(e).parent() instead of 
cell.parent(), I find it more intuitive to use cell.parent() in other instances and thus discovered this behavior.If it's unintentional, I'll start trying to find a fix and whip up some test cases too, I just wanted to check before I go fixing something that's not a bug in the first place.
Cheers,~Peter 
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] I'm find a bug in jQuery??s Cookie plugIn

2006-10-17 Thread Jörn Zaefferer
Klaus Hartl schrieb:
> Klaus Hartl schrieb:
>   
>> cookie deletion does not work with more than one cookie, will fix that...
>> 
>
> False alarm, forget that - I just screwed my test page. Should put up 
> automatic tests in there if possible.
>
> Jörn or John, where can I get some information about the test suite used 
> in jQuery?
>   
I started some stuff here: http://jquery.com/docs/DevelopersGuide/
Not yet very much, but perhaps enough to get you started.

-- Jörn

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


Re: [jQuery] jquery snapshots

2006-10-17 Thread Jörn Zaefferer
Mika Tuupola schrieb:
> Is it possible to download a nightly snapshot of jquery somewhere? I  
> would like to test recent bugfixes. Especially those affecting $ 
> (document).load(). Although using $(window).load() instead works fine  
> with FF and Safari, I still have problems with Windows IE.
>   
Not nightly, but updated now and then: http://jquery.com/src/jquery-svn.js

-- Jörn

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


Re: [jQuery] newbie request / suggestion / neat thing

2006-10-17 Thread Dave Methvin
Mike Alsup has tweaked my original corner rounder so that it does any corner
adornment you'd like, and it's only 4KB. It doesn't support borders or
background images in the parent though, which Curvy and a few others do. But
it's a high price to pay, IMO.

http://www.malsup.com/jquery/corner/

Be aware that using a large radius on a lot of elements can insert hundreds
of new elements into your document to implement the rounding effect. That
will cause the page to start slowly and can also make later use of jQuery
selectors slower. jQuery .corner() is pretty thrifty, as you can tell from
the loading time of Mike's page which has a lot of examples. Compare that to
the Ruzee Borders page, which has a lot more features but is also very slow
to load when used liberally:

http://www.ruzee.com/blog/ruzeeborders/

If you are seeing performance problems while using any of these rounding
scripts, turn them off to see if they are the cause.


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


[jQuery] Simple select box utility functions

2006-10-17 Thread Yehuda Katz
jQuery.fn.selectOption = function() {  return this.jsAttr("selected", true)
}
jQuery.fn.unselectOption = function() {  return this.jsAttr("selected", false)
}jQuery.fn.toggleOption
 = function() {  return this.each(function() { this.selected = !this.selected; })
}jQuery.fn.moveToSelect
 = function(el) {  jQuery(el).append(this);
}jQuery.fn.jsAttr = function(attr, value) {
  return this.each(function() { this[attr] = value })}
The above are a few utility functions I wrote so I could write a dual-pane select box implementation that moved from one box to another.So you could do $("#first option:selected").moveToSelect("#second")
-- Yehuda KatzWeb Developer | Wycats Designs(ph)  718.877.1325
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] Highlighting jQuery

2006-10-17 Thread Andrea Ercolino
Hola.
 
I just released Chili, a free syntax highlighter script, written in jQuery, and based on the Dan Webb's Code Highlighter, which I found a couple of weeks ago thanks to a link on the jQuery site.
 
Chili is compatible with Code Highlighter's language definition files, but it is othwerwise a new piece of software (re-engineered and fixed), fully documented, and really based on jQuery functionalities.
 
I posted a zip file with all inside and put the manual and two examples one click away. http://www.mondotondo.com/aercolino/noteslog/?cat=8
 
The example "Chili highlighting jQuery" shows how Chili can be used for highlighting jQuery scripts.
 
 
Hasta pronto,
Andrea
 ___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] How to get values from form automatically?

2006-10-17 Thread Balkanski

Hi to all, I heard that jquery has a params() function that gets all the
values from a form but I couldn't find documentation for it. I need to get
the data from a form automatically, construct a GET query and send it via
AJAX, for now I'm building the query manually and then send it. Please, post
me some example, if any.

Thanks in advance
balkanski
-- 
View this message in context: 
http://www.nabble.com/How-to-get-values-from-form-automatically--tf2459166.html#a6854045
Sent from the JQuery mailing list archive at Nabble.com.


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


Re: [jQuery] åäö doesn't wo rk with load/loadIfModified

2006-10-17 Thread badtant

where should i put that meta-tag? inside sida1.html?

/niklas


Ⓙⓐⓚⓔ wrote:
> 
> your server is sending sida.html as simple ascii.
> looks like an issue with iis!
> 
> I bet if you slip a  tag in there... it can alter the encoding.
> 
> but my advise is still "bite the bullet, go utf-8"
> 
> my Mac  see those question marks as hex 00 0D 00 0D 00 0D 00 0D
> the file in the zip has .
> get -e http://www2.hemsida.net/badtant/tabs/sida1.html
> Connection: close
> Date: Tue, 17 Oct 2006 05:20:37 GMT
> Accept-Ranges: bytes
> ETag: "b044d3693eec61:9af"
> Server: Microsoft-IIS/5.0
> Content-Length: 30
> Content-Type: text/html
> Last-Modified: Fri, 13 Oct 2006 06:44:26 GMT
> Client-Date: Tue, 17 Oct 2006 05:10:34 GMT
> Client-Peer: 212.37.5.72:80
> Client-Response-Num: 1
> X-Powered-By: ASP.NET
> 
> Sida 1
> 
> ??
> 
> 
> On 10/12/06, badtant <[EMAIL PROTECTED]> wrote:
>>
>> here's my page:
>> http://www2.hemsida.net/badtant/tabs/
>>
>> all files are ISO-8859-1
>>
>> and here's a zip with all the files:
>> http://www2.hemsida.net/badtant/tabs/tabs.zip
>>
>>
>> John Resig wrote:
>> >
>> > What's the encoding of the page that you're loading into? Do you have
>> > a demo of the pages in action, so that we can verify the problem?
>> >
>> > --John
>> >
>> > On 10/12/06, badtant <[EMAIL PROTECTED]> wrote:
>> >>
>> >> come on? someone shouldknow something about this...
>> >>
>> >>
>> >>
>> >> badtant wrote:
>> >> >
>> >> > hi!
>> >> >
>> >> > i'm trying to use the ajax function loadIfModified to load an
>> >> "extrernal"
>> >> > html-file into a div.
>> >> >
>> >> > 
>> >> >
>> >> > $("#helptext").loadIfModified("help-sida1.html");
>> >> >
>> >> > in help-sida1.html i have the following code:
>> >> > åäöÅÄÖ
>> >> >
>> >> > when i run the page i just get questionmarks. anyone who knows whats
>> >> wrong
>> >> > and what i can do about it?
>> >> >
>> >> >  http://www.nabble.com/file/226/error.jpg
>> >> >
>> >> >
>> >> > my pages is ISO-8859-1. åäö loads correctly if i save help-sida1.htm
>> as
>> >> > UTF-8. but that's not an acceptable solution to me... i wan't my
>> files
>> >> to
>> >> > be ISO-8859-1.
>> >> >
>> >>
>> >> --
>> >> View this message in context:
>> >>
>> http://www.nabble.com/-doesn%27t-work-with-load-loadIfModified-tf2355437.html#a6774742
>> >> Sent from the JQuery mailing list archive at Nabble.com.
>> >>
>> >>
>> >> ___
>> >> jQuery mailing list
>> >> discuss@jquery.com
>> >> http://jquery.com/discuss/
>> >>
>> >
>> >
>> > --
>> > John Resig
>> > http://ejohn.org/
>> > [EMAIL PROTECTED]
>> >
>> > ___
>> > jQuery mailing list
>> > discuss@jquery.com
>> > http://jquery.com/discuss/
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/-doesn%27t-work-with-load-loadIfModified-tf2355437.html#a6790644
>> 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/-doesn%27t-work-with-load-loadIfModified-tf2355437.html#a6849806
Sent from the JQuery mailing list archive at Nabble.com.


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


[jQuery] newbie request / suggestion / neat thing

2006-10-17 Thread adrienne

Has anyone thought about porting curvyCorners (www.curvycorners.net) to
jQuery? I'm fairly clueless at javascript, so it's WAY too big a job for me
-- but i thought i'd call it to people's attention, because it seems like a
great fit for the jQuery framework if someone wanted to do it. I'd certainly
offer to help test/document/whatever.

--Adrienne

-- 
View this message in context: 
http://www.nabble.com/newbie-request---suggestion---neat-thing-tf2460391.html#a6857886
Sent from the JQuery mailing list archive at Nabble.com.


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


[jQuery] Mouseover/out + CSS background image behavior change in IE between rev 249 and 413

2006-10-17 Thread Prague Expat
Does JQuery try to refresh/reload any CSS on mouse events?  In my version of 
IE (with JQuery rev 413) every mouseover/out is causing all my CSS 
background images to quickly reload (but not quickly enough, as it is quite 
noticeable).  I did not have this problem with rev 249 (I just updated to 
413 yesterday and noticed the strange behavior).

One more thing: the dev PC at work does not show a problem with IE with 
either JQuery version. My home PC shows the problem with version 413 only. 
At home, 249 works perfectly but fails as soon as I try the 413 version.

Is it possible that the memory leak fixes (that I understand are in the 
updated JQuery) are causing quick refreshes on the CSS?

Thanks for any insight. Feel free to email be w/questions. pragueexpat (at) 
hotmail.com

code:

$(document).ready(function(){
//remove anchors in menu table tds - replace w/bkimg
 $(".menuanchor").remove();
 
$("#menutab1").css({backgroundImage:"url(i/about.jpg)",cursor:"pointer"}).rb_menu();
 
$("#menutab2").css({backgroundImage:"url(i/practice.jpg)",cursor:"pointer"}).rb_menu();
 
$("#menutab3").css({backgroundImage:"url(i/offices.jpg)",cursor:"pointer"}).rb_menu();
 
$("#menutab4").css({backgroundImage:"url(i/tech.jpg)",cursor:"pointer"}).rb_menu();
 
$("#menutab5").css({backgroundImage:"url(i/patients.jpg)",cursor:"pointer"}).rb_menu();
 $(".links").click(function(){window.location=this.id+".php"}); 
$("#logo").click(function(){window.location="/bho/index.php"}); 
$("#newsbody").height($("#contentcol2").height()-111+"px");});$.fn.rb_menu = 
function(options) {var self = this;this.options = {// 
transitions: easein, easeout, easeboth, bouncein, bounceout,//  
bounceboth, elasticin, elasticout, elasticbothtransition:
'easein',// trigger events: mouseover, mousedown, mouseup, click, 
dblclicktriggerEvent:  'mouseover',// number of ms to delay 
before hiding menu (on page load)loadHideDelay : 500,// number 
of ms to delay before hiding menu (on mouseout)blurHideDelay:  500, 
   // number of ms for transition effecteffectDuration: 500}// 
make sure to check if options are given!if(options) {
$.extend(this.options, options);}return this.each(function() {
var menu = $("#drop"+this.id);menu.closed = true;menu.hide();   
 menu.hide = function() {if(menu.css('display') == 'block' && 
!menu.closed) {menu.BlindUp(
self.options.effectDuration,function() {
menu.closed = true;menu.unbind();   
 },self.options.transition);}   
   $(".dropmenu li").css("fontWeight","normal");}menu.show = 
function() {if(menu.css('display') == 'none' && menu.closed) {  
  menu.BlindDown(self.options.effectDuration,   
 function() {menu.closed = false;   
 menu.hover(function() {
clearTimeout(menu.timeout);}, function() {  
  menu.timeout = setTimeout( function() {   
 menu.hide();}, self.options.blurHideDelay);
});},
self.options.transition);}   //highlight 
each li option on mouseover   
$(".dropmenuli").mouseover(function(){$(this).css({fontWeight:"bold",color:"white",background:"#e6ccb3"});}).mouseout(function(){$(this).css({fontWeight:"normal",color:"#a0a0a0",background:"#f2e6da"});});
}//show drop down when mouseover table tds
self.bind("mouseover", function() {  menu.show();});
//hide drop downs if mouseout of table tdsself.bind("mouseout", 
function() {  menu.timeout = setTimeout( function() 
{menu.hide();},self.options.blurHideDelay);});});};

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


Re: [jQuery] jQuery API discussion

2006-10-17 Thread Stephen Howard
I'd like to throw in my support for coalescing all the httprequest stuff 
into a request(method,{args}) method.  This is much closer to how I 
currently do my xhr stuff outside of jquery

Mark Gibson wrote:
> Why not just .request(method, options) or .http()
>
> After all AJAX is just a bottle of toilet cleaner ;), and a bit
> of a misnomer as a lot of calls don't even involve the X(ML).
>
> - Mark.
>
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
>   

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


Re: [jQuery] get first and last

2006-10-17 Thread Klaus Hartl
Steve Ivy schrieb:
> I'd try $('#theul li').get(0) and $('#theul li').get($('#theul
> li').get().length) perhaps?

Use :first-child and :last-child selectors:

$('#theul li:first-child, #theul li:last-child')


-- Klaus



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


Re: [jQuery] SOT: PNG fix seems to cause page to load endlessly

2006-10-17 Thread Andy Matthews
I see...thank you Klaus. I'll read up on that link you sent.

Appreciated.



-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Behalf Of Klaus Hartl
Sent: Tuesday, October 17, 2006 10:51 AM
To: jQuery Discussion.
Subject: Re: [jQuery] SOT: PNG fix seems to cause page to load endlessly




Andy Matthews schrieb:
> I'll check into this, but I don't believe we're using transparent
> backgrounds. I'm pretty sure we're just using product images which are in
> plain IMG tags.

That is exactly what this solution relies on. Nonetheless the 
transparent png is set in CSS by usage of the alphaimageloader filter...


-- Klaus

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


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


Re: [jQuery] get first and last

2006-10-17 Thread Rafael Santos
hmm.. thx.. i didnt think it hehe..now i remember something, it's like ("li:1st") or ("li:last")... but i havent tried... 2006/10/17, Steve Ivy <
[EMAIL PROTECTED]>:
I'd try $('#theul li').get(0) and $('#theul li').get($('#theulli').get().length) perhaps?--Steve[EMAIL PROTECTED] | irc: monkinetic|redmonk>  Original Message 
> Subject: [jQuery]  get first and last> From: "Rafael Santos" <[EMAIL PROTECTED]>> Date: Tue, October 17, 2006 8:28 am> To: "jQuery Discussion." <
discuss@jquery.com>>> hey, I am afraid ive forgotten how to get the first and the last element of a  list inside a  how knows?? =)>
> -> ___> jQuery mailing list> discuss@jquery.com
> http://jquery.com/discuss/>___jQuery mailing listdiscuss@jquery.com
http://jquery.com/discuss/
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] slideToggle Not Completely Expanding in Firefox

2006-10-17 Thread Karl Swedberg
On Oct 13, 2006, at 9:38 AM, kyle wrote:

> I'm having height issues with slideToggle in Firefox.  An example  
> can be
> found here:
>
> http://hotelwebsitedesign.com/OTODevelopment/careers_openings.asp
>
> In IE when you click on the different positions they expand fully  
> but in
> firefox they only expand some of the way and then the text just  
> spills over
> on top of other listings.  Any idea why this is happening?  The hidden
> content is all in one div which I'm toggling.
>
> I'm using firefox 1.5 and the latest jQuery download.

Hi Kyle,

My guess is that slideToggle() isn't taking into account the line- 
height in your CSS. A bottom margin on those DIVs might compensate,  
but since the amount of text is variable, and therefore so is the  
extra amount of height caused by line-height, my hack isn't terribly  
useful

Does anyone else know a workaround for this? When I neutralized line- 
height, it got very close, but not all the way, towards preventing  
the overlap.

Karl
___
Karl Swedberg
www.englishrules.com
www.learningjquery.com



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


[jQuery] Selectors [EMAIL PROTECTED]|=val] and [EMAIL PROTECTED] Have they been removed?

2006-10-17 Thread Choan C. Gálvez
Hi all.

While playing with CSS selectors, I've found some strange things (I'm
using the SVN version, rev 445):

* Attribute selector [EMAIL PROTECTED] doesn't work (returns any
element with a class name)
* Attribute selector [EMAIL PROTECTED]|=en] doesn't work (returns any element
with a hreflang attribute)

Has the support for these selectors been removed?

This is what I'm using for testing:

HTML:
pare-0, hreflang=es
fill-0 pare-1 hreflang=en
No class, no hreflang

jQuery:
$("[EMAIL PROTECTED]|=en]").length; // 2, should be 1
$("[EMAIL PROTECTED]|=es]").length; // 2, should be 1

$("[EMAIL PROTECTED]").length; // 2, shoul be 1

-- 
Choan


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


Re: [jQuery] get first and last

2006-10-17 Thread Steve Ivy
I'd try $('#theul li').get(0) and $('#theul li').get($('#theul
li').get().length) perhaps?

--Steve

[EMAIL PROTECTED] | irc: monkinetic|redmonk



>  Original Message 
> Subject: [jQuery]  get first and last
> From: "Rafael Santos" <[EMAIL PROTECTED]>
> Date: Tue, October 17, 2006 8:28 am
> To: "jQuery Discussion." 
> 
> hey, I am afraid ive forgotten how to get the first and the last element of a 
>  list inside a  how knows?? =)
>  
> -
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 


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


Re: [jQuery] best show/hide div code?

2006-10-17 Thread Rey Bango
Hey Andy, you can do something like this:

$(document).ready(function() {

$( "#type" ).change( function() {
if ( $( this ).val() == "event" )
$("#zipCode").show();
else
$("#zipCode").hide();
})  
});


Zip Code of event





Andy Matthews wrote:
> I'm working on a mailing list manager and one of the options is to provide a
> zip code for emailing anyone in that area. I'd like to hide this field
> unless the user has selected the "Tour Date" option from a select field.
> 
> The relevant code is below. The second TR (and it's contents) will be hidden
> by default using CSS, but I want to toggle it's display property when the
> user selects or deselects the "event" option in the "type" dropdown field.
> 
> 
> 
>   Mailing Type
>   
>   
>   General Announcement
>   BCC Store Announcement
>   Clowndergarten Announcement
>   Event Announcement
>   
>   
> 
> 
>   Zip Code of event class="smaller">for event announcement only
>   
> 
> 
> 
> How would I do this with jQuery?
> 
>  andy matthews
> web developer
> certified advanced coldfusion programmer
> ICGLink, Inc.
> [EMAIL PROTECTED]
> 615.370.1530 x737
> --//->
> 
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 

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


Re: [jQuery] SOT: PNG fix seems to cause page to load endlessly

2006-10-17 Thread Klaus Hartl


Andy Matthews schrieb:
> I'll check into this, but I don't believe we're using transparent
> backgrounds. I'm pretty sure we're just using product images which are in
> plain IMG tags.

That is exactly what this solution relies on. Nonetheless the 
transparent png is set in CSS by usage of the alphaimageloader filter...


-- Klaus

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


Re: [jQuery] jquery snapshots

2006-10-17 Thread Michael Geary
> > Use the SVN version if you want to do that sort of thing.
> >
> > http://jquery.com/src/ - Shows you the SVN access address.

> AFAIK this has to be built first before it is usable. I am 
> looking for readily built snapshot.

No, it doesn't have to be built. The svn code is usable right out of the
box. The only difference is that it's bigger because it isn't packed and
still has all the comments, and it comes in separate files (jquery.js,
event.js, etc.) instead of one concatenated file.

For development and testing it works fine.

-Mike


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


Re: [jQuery] Passing multiple variables using .ajax()

2006-10-17 Thread Rey Bango
Hi Chris,

The "&" is fine. The variables sent from your Ajax call will be in the 
form scope.

Rey...

Christopher Jordan wrote:
> Hi folks,
> 
> I'm trying to make an ajax call using the .ajax() method, and I can't 
> figure out how to pass multiple variables. I've checked out the 
> interactive API (very cool by the way), and it shows an example like this:
> 
> $.ajax({
> type: "POST",
> url: "some.php",
> data: "name=John&location=Boston",
> success: function(msg){
> alert( "Data Saved: " + msg );
> }
> });
> 
> 
> Since the type is set to post this should be using the form scope, but 
> the '&' leads me to think that it's passing information in the query 
> string. I'm a bit confused. I've tried passing multiple variables after 
> this fassion, and can't seem to get it right.
> 
> My code:
> 
> 
> 
> $(document).ready(function(){
> var i,IDList;
> IDList = "#ClientNumberList#";
> IDList = IDList.split("|");
> for(i = 0; i < IDList.length; i++){
> $.ajax({
> type: "POST",
> url: "MyJQueryTest.cfm",
> data: "ClientID=" + IDList[i] + "&Test=ChrisRocks",
> dataType: "html",
> success: function(msg){
> $("##foo" ).append(msg);
> }
> });  
> }
> });
>   
> 
> 
> I thought I should have a variable called "Test" with a value of 
> "ChrisRocks" in it. hmm... can anyone explain what I'm missing here?
> 
> Thanks,
> Chris
> 
> 
> 
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/

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


Re: [jQuery] SOT: PNG fix seems to cause page to load endlessly

2006-10-17 Thread Klaus Hartl
I found a fairly easy solution a while ago, try this:

http://www.stilbuero.de/2006/03/15/png-alpha-transparency-fast-and-easy/

It boils down to put a little dynamic property into your style sheet:

img.png {
 background-image: expression(
 this.runtimeStyle.backgroundImage = "none",
 this.runtimeStyle.filter = 
"progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" + this.src + 
"', sizingMethod='image')",
 this.src = "/path/to/transparent.gif"
 );
}


-- Klaus


Andy Matthews schrieb:
> I'm using a PNG fix javascript to load in some product images on a site that
> my company did. It "works" great, in that the images load in properly and
> are transparent. The problem is that the page loads endlessly, even though
> nothing is missing.
> 
> My first question is "does anyone know why this is happening"?. A second
> question is, "does anyone have a PNG fix that works correctly?"
> 
> Here's the site:
> http://www.bigcomfycouchstore.com
> 
> All of the product images on the front page are PNGs
> 
> Thanks in advance.
> 
>  andy matthews
> web developer
> certified advanced coldfusion programmer
> ICGLink, Inc.
> [EMAIL PROTECTED]
> 615.370.1530 x737
> --//->
> 
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 

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


Re: [jQuery] SOT: PNG fix seems to cause page to load endlessly

2006-10-17 Thread Andy Matthews
I'll check into this, but I don't believe we're using transparent
backgrounds. I'm pretty sure we're just using product images which are in
plain IMG tags.



-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Behalf Of Klaus Hartl
Sent: Tuesday, October 17, 2006 10:38 AM
To: jQuery Discussion.
Subject: Re: [jQuery] SOT: PNG fix seems to cause page to load endlessly


I found a fairly easy solution a while ago, try this:

http://www.stilbuero.de/2006/03/15/png-alpha-transparency-fast-and-easy/

It boils down to put a little dynamic property into your style sheet:

img.png {
 background-image: expression(
 this.runtimeStyle.backgroundImage = "none",
 this.runtimeStyle.filter =
"progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" + this.src +
"', sizingMethod='image')",
 this.src = "/path/to/transparent.gif"
 );
}


-- Klaus


Andy Matthews schrieb:
> I'm using a PNG fix javascript to load in some product images on a site
that
> my company did. It "works" great, in that the images load in properly and
> are transparent. The problem is that the page loads endlessly, even though
> nothing is missing.
>
> My first question is "does anyone know why this is happening"?. A second
> question is, "does anyone have a PNG fix that works correctly?"
>
> Here's the site:
> http://www.bigcomfycouchstore.com
>
> All of the product images on the front page are PNGs
>
> Thanks in advance.
>
>  andy matthews
> web developer
> certified advanced coldfusion programmer
> ICGLink, Inc.
> [EMAIL PROTECTED]
> 615.370.1530 x737
> --//->
>
>
> ___
> 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] Passing multiple variables using .ajax()

2006-10-17 Thread Rey Bango
Also, if those values are coming from a form, use the serialize() method 
to create the string for you.

Rey...

Christopher Jordan wrote:
> Hi folks,
> 
> I'm trying to make an ajax call using the .ajax() method, and I can't 
> figure out how to pass multiple variables. I've checked out the 
> interactive API (very cool by the way), and it shows an example like this:
> 
> $.ajax({
> type: "POST",
> url: "some.php",
> data: "name=John&location=Boston",
> success: function(msg){
> alert( "Data Saved: " + msg );
> }
> });
> 
> 
> Since the type is set to post this should be using the form scope, but 
> the '&' leads me to think that it's passing information in the query 
> string. I'm a bit confused. I've tried passing multiple variables after 
> this fassion, and can't seem to get it right.
> 
> My code:
> 
> 
> 
> $(document).ready(function(){
> var i,IDList;
> IDList = "#ClientNumberList#";
> IDList = IDList.split("|");
> for(i = 0; i < IDList.length; i++){
> $.ajax({
> type: "POST",
> url: "MyJQueryTest.cfm",
> data: "ClientID=" + IDList[i] + "&Test=ChrisRocks",
> dataType: "html",
> success: function(msg){
> $("##foo" ).append(msg);
> }
> });  
> }
> });
>   
> 
> 
> I thought I should have a variable called "Test" with a value of 
> "ChrisRocks" in it. hmm... can anyone explain what I'm missing here?
> 
> Thanks,
> Chris
> 
> 
> 
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/

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


[jQuery] Select Box Plugin

2006-10-17 Thread Yehuda Katz
I heard word a while ago that there was a select-box plugin coming down the pike. What's the status on that?-- Yehuda KatzWeb Developer | Wycats Designs(ph)  718.877.1325
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] best show/hide div code?

2006-10-17 Thread Andy Matthews
I'm working on a mailing list manager and one of the options is to provide a
zip code for emailing anyone in that area. I'd like to hide this field
unless the user has selected the "Tour Date" option from a select field.

The relevant code is below. The second TR (and it's contents) will be hidden
by default using CSS, but I want to toggle it's display property when the
user selects or deselects the "event" option in the "type" dropdown field.



Mailing Type


General Announcement
BCC Store Announcement
Clowndergarten Announcement
Event Announcement




Zip Code of eventfor event announcement only




How would I do this with jQuery?




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


Re: [jQuery] jquery snapshots

2006-10-17 Thread Rey Bango
Actually, there have been some recent v1.0.2 bug fixes that aren't 
really associated to bleeding edge features so having a nightly build 
would be cool.

Rey...

Dan Atkinson wrote:
> No. Not that I know of. Mainly because, if people wanted the bleeding edge
> version of something, then they generally want it for dev work. In which
> case, it's usually best that it's distributed in its original form.
> 
> Of course, you could always build it at your end. But this clearly seems too
> much hassle for you if you want it now now now.
> 
> 
> Mika Tuupola wrote:
> 
>>
>>On Oct 17, 2006, at 15:45, Dan Atkinson wrote:
>>
>>
>>>What's wrong with building it?
>>
>>Argh... There is nothing wrong with building it. I just had one very  
>>simple question. Is there a snapshot (not svn checkout) available  
>>somewhere? So it seems there is not.
>>
>>-- 
>>Mika Tuupola
>>http://www.appelsiini.net/~tuupola/
>>
>>
>>
>>___
>>jQuery mailing list
>>discuss@jquery.com
>>http://jquery.com/discuss/
>>
>>
> 
> 

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


[jQuery] [ANN] JReflection 0.3

2006-10-17 Thread Abdur-Rahman Advany
Hi,

Just released an other version:

http://jquery.com/docs/Plugins/JReflection/

Changed:
- Now you can pass both id of image and a container (of elements) containing 
images.

The plugin is done for what I would like to do with it...

Abdul


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


[jQuery] Passing multiple variables using .ajax()

2006-10-17 Thread Christopher Jordan




Hi folks,

I'm trying to make an ajax call using the .ajax() method, and I can't
figure out how to pass multiple variables. I've checked out the
interactive API (very cool by the way), and it shows an example like
this:

$.ajax({ 
    type: "POST", 
    url: "some.php", 
    data: "name=John&location=Boston", 
    success: function(msg){ 
        alert( "Data Saved: " + msg ); 
    } 
});


Since the type is set to post this should be using the form scope, but
the '&' leads me to think that it's passing information in the
query string. I'm a bit confused. I've tried passing multiple variables
after this fassion, and can't seem to get it right.

My code:

    
    
    $(document).ready(function(){
    var i,IDList;
    IDList = "#ClientNumberList#";
    IDList = IDList.split("|");
    for(i = 0; i < IDList.length; i++){
    $.ajax({
    type: "POST",
    url: "MyJQueryTest.cfm",
    data: "ClientID=" + IDList[i] + "&Test=ChrisRocks",
    dataType: "html",
    success: function(msg){
    $("##foo" ).append(msg);
    }
    });  
    }
    });
  I thought I should have a variable called "Test" with a value of "ChrisRocks" in it. hmm... can anyone explain what I'm missing here? Thanks, Chris ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/

[jQuery] get first and last

2006-10-17 Thread Rafael Santos
hey, I am afraid ive forgotten how to get the first and the last element of a  list inside a  how knows?? =)
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] SOT: PNG fix seems to cause page to load endlessly

2006-10-17 Thread Andy Matthews
I'm using a PNG fix javascript to load in some product images on a site that
my company did. It "works" great, in that the images load in properly and
are transparent. The problem is that the page loads endlessly, even though
nothing is missing.

My first question is "does anyone know why this is happening"?. A second
question is, "does anyone have a PNG fix that works correctly?"

Here's the site:
http://www.bigcomfycouchstore.com

All of the product images on the front page are PNGs

Thanks in advance.




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


Re: [jQuery] Select append(html) issue fixed (need testers)

2006-10-17 Thread Brandon Aaron
Thanks to dbzz from the 'Possible changes to show/hide' thread and
Dave and John ... here is an updated demo that is a mere 4 lines of
added code.

http://brandonaaron.net/jquery/select2/test.html
http://brandonaaron.net/jquery/select2/select.js

The only issue I see thus far is that Firefox does not respect the
selected attribute.

--
Brandon Aaron


On 10/17/06, Brandon Aaron <[EMAIL PROTECTED]> wrote:
> I take that back ... I totally missed the point. Checking into that as
> a possible solution right now. That should reduce the code by a lot!
>
> Thanks!
>
> --
> Brandon Aaron
>
> On 10/17/06, Brandon Aaron <[EMAIL PROTECTED]> wrote:
> > On 10/17/06, Dave Methvin <[EMAIL PROTECTED]> wrote:
> > > I took a quick look last night but was wondering if it would be much 
> > > easier
> > > to wrap the incoming options/optgroup string in a temporary  the 
> > > way
> > > .clean() does for table chunks. I was going to try it myself but ran out 
> > > of
> > > night.
> >
> > But that would only complicate the issue. The problem is that you
> > can't just innerHTML several option tags or optgroup tags to a select.
> > This is realized by the non-patched demo. It just appends the whole
> > string in one option. You would still have to parse the html, find the
> > options and optgroups, create the elements, append them to the select,
> > then get the childNodes of the select and return those. This is just
> > simply parsing the string of html and sending back the dom nodes to
> > append to the original select.
> >
> > --
> > Brandon Aaron
> >
>

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


  1   2   >