[jQuery] jCarousel infinite loop problem w/ multiple carousels on display: none

2008-01-30 Thread Todd

I am attempting to build a page with multiple carousels, that by
default, only one displays.  When you click on an element on the page
(a staff members name), you see their own personal carousel, which
replaces the default.

When I attempt to do this, I receive the following error message:

"jCarousel: No width/height set for items. This will cause an infinite
loop. Aborting"

Code:

var $j = jQuery.noConflict();

$j(document).ready(function() {

onLoad();

$j('ul.usecarousel').jcarousel({
visible: 5
});

$j('.gpic_wrapper').hide();
$j('.gpic_wrapper#jamie').show();

$j('a.teamnav').click(function()
{
$j('.gpic_wrapper').hide();
$j('.gpic_wrapper#' + this.id).show();

var currentPerson = this.id;

$j("a.teamnav").each(function()
{
if (this.id == currentPerson)
$j(this).addClass("selectedPerson");
else
$j(this).removeClass("selectedPerson");
});
return false;
});
});

I am linking to the appropriate jcarousel and skin.css, but if I take
a div class that surrounds one of the carousels and display: none; it,
and then resize my browser window, the alert error appears.

I have also adjusted my jcarousel pack and swapped

|loop|ol|infinite|an|ul|cause|will|This|items|set|No|jCarousel|alert|

with

|loop|ol|infinite|an|ul|cause|will|This|items|set|No|jCarousel|isNaN|

but still am having no luck.

I don't have a way to publish the page currently as it also involves a
google map, and the api key is set to my dev area only.

Thoughts?


[jQuery] Re: [validate] Validation Plugin - how to remove a control form validation

2008-01-30 Thread Dave Stewart

Hi Jorn,
Yup - here's a test page:

http://www.janepatrick.co.uk/admin/test/login.php

Submitting the form manually (as you said) just bypasses any
validation, which is NOT what I want, as I still need the email
address validated before it's sent to the back end to email the
password...

Using:

$('#login').submit()

fires off the validation just fine (but I still need to kill the
validation on the password field)

I hope you have enough information now to help me out!

Cheers,
Dave


[jQuery] Re: change on select not working

2008-01-30 Thread Hamish Campbell

Whenever you create new selects you will need to bind the click event
to the new selects.

On Jan 31, 11:51 am, RyanMC <[EMAIL PROTECTED]> wrote:
> $("select").change(function(){
>     alert("Selected: " + this.value);
>
> });
>
> Is there any reason why this wouldn't be working on all the selects on
> my page.
>
> I create the selects dynamically, but this is up in the $
> (document).ready(function() { block of my code.


[jQuery] Re: simplemodal and datepicker

2008-01-30 Thread Eric Martin

Thanks for the example Marc. To answer the OP's question, I added an
example using SimpleModal:

http://ericmmartin.com/code/datepicker/

-Eric


On Jan 30, 12:43 pm, 1Marc <[EMAIL PROTECTED]> wrote:
> I've had a lot of questions about modal windows and UI Datepicker, so
> I created a demo example using thickbox:
>
> http://marcgrabanski.com/code/ui-datepicker/extras/thickbox-datepicker
>
> I hope that helps.
>
> On Jan 30, 10:55 am, Eric Martin <[EMAIL PROTECTED]> wrote:
>
> > On Jan 30, 6:13 am, rayfidelity <[EMAIL PROTECTED]> wrote:
>
> > > Hi,
>
> > > I want to enable datepicker in the modal window that
> > > opens...datepicker works fine for itself but i cannot get it to work
> > > in modal. Any ideas?
>
> > Can you clarify what you mean by "cannot get it to work in modal"?
>
> > > Modal window is loaded through ajax...
>
> > Do you have a page or code that we/I can view?
>
> > -Eric


[jQuery] Re: Is this the best way?

2008-01-30 Thread Danny

jQuery does not have a built-in selector to compare the values of
attributes, but it allows you to write custom filters (analogous to
plugins). I once found documentation on this but can't anymore. You
sort of have to read the source to learn to do this.
You just extend the $.expr[':'] object with your new filter set to a
string that is evaluated, where 'a' is the element being tested and
'm[3]' is the argument to the filter:

$.expr[':'].levelGreaterThan = '$.attr(a,"level")>m[3]' ;

Now you can use this anywhere:

$('qualif:levelGreaterThan(3)').remove();

Far more bizarre but potentially useful would be a custom filter that
tests any attribute:

  $.expr[':'].attr = 'eval(m[3].replace(/^(\\w+)/,"$.attr(a,\\"$1\
\")"))';

and now write:

$('.qualif:attr(level>3)').remove();

Unfortunately the parser for [attr] is not extensible, so you
can't create a [level>3] selector directly

Danny
On Jan 30, 12:22 pm, Feijó <[EMAIL PROTECTED]> wrote:
> Hi Cabbite
>
> Thanks for your 0.02
>
> Its possible to simple use like this?
> $('.qualif[level>3]').remove();
>
> if level bigger then 3, remove it :)
>
> My code is dynamic, I cant just wrote all numbers I dont need to remove,
> like your example.  Has to use a condition.
>
> Feijó
>
> cabbiepete escreveu:
>
> >  Hi Felix,
>
> >  I would have thought doing an attribute selector like you suggest was
> >  better.
>
> >  something like
>
> >  ... $('.qualif[level]).each  ...
>
> >  to at least get rid of anything that doesn't have the level
> >  attribute. Also if you use the same tag name for all of these
> >  attributes its worth adding that as it also helps with efficiency,
> >  i.e. jquery only has to check those tags for level attribute.
>
> >  Depending on the exact use of the level attribute you might be able
> >  to get just the ones you want by using [attribute!=value] selectors.
> >  i.e. if you want greater than 4 and start at 0
>
> >  $('.qualif[level!=0], .qualif[level!=1], .qualif[level! =2],
> >  .qualif[level!=3], qualif[level!=4]').remove();
>
> >  Hope that helps. Also if any more expert on jquery knows more am keen
> >  to know better also.
>
> >  Cheers, Pete
>
> >  On Jan 30, 12:56 pm, Feijó <[EMAIL PROTECTED]> wrote:
> > > Hi, I was just wondering if there is any better way to accomplish
> > > that. Some divs has 'level' attribute, with a number.  If that
> > > number is bigger than X, will remove the div. var x=4; //
> > > simulating level=parseFloat($this.attr('level'));
> > > $('.qualif').each(function() { if ($(this).attr('level')>x)
> > > $(this).remove(); }); I don't know if we can set a filter in $('')
> > > to look at a custom attribute, should be simpler than Feijó


[jQuery] Re: Fighting a closure

2008-01-30 Thread Karl Swedberg



On Jan 30, 2008, at 9:13 PM, Karl Swedberg wrote:

If you can assign class="port" to each of those elements, you could  
do this:


$('.port').each(function(index) {
$(this).click(function() {bigchart(index)});
}

if you can't assign a class, then change $('.port') to $ 
('[id^=port]') , as Josh suggested.



Oops. I missed a closing paren. should be ...

$('.port').each(function(index) {
$(this).click(function() {bigchart(index)});
});


[jQuery] Re: How to logically AND selectors?

2008-01-30 Thread Karl Rudd

Yes, of course. As you demonstrated, if you want to select by id as
well then you put the id first. So conceivably you could write
something like:

p#anId.aClass.anotherClass.stillAnotherClass

And it would only match elements like this:



Karl Rudd

On Jan 31, 2008 1:23 PM, Erik Beeson <[EMAIL PROTECTED]> wrote:
>
> > You're looking for:.selector1.selector2.selector3
> >
>
> But, that's only if selector1, selector2, and selector3 are all classes,
> yes?
>
> --Erik
>


[jQuery] Re: How to logically AND selectors?

2008-01-30 Thread Erik Beeson
>
> You're looking for:.selector1.selector2.selector3
>

But, that's only if selector1, selector2, and selector3 are all classes,
yes?

--Erik


[jQuery] Re: How to logically AND selectors?

2008-01-30 Thread Erik Beeson
Generally, just run them together with no space.

A div tag with ID foo and class bar: div#foo.bar

Any tag with classes class1 and class2: .class1.class2

etc

Hope it helps.

--Erik


On 1/30/08, Kynn Jones <[EMAIL PROTECTED]> wrote:
>
>
> Hi.  The docs describe selectors of the form
>
>   selector1, selector2, selector3
>
> as "matching the combined results of all the specified selectors", by
> which they mean the set union of all the individual selections.  In
> other words, the ',' here behaves like a logical OR.
>
> Is there a succinct way to perform the correspond logical AND?  I.e.
> what's the best way to obtain the set intersection of multiple
> selections?
>
> TIA!
>
> kynn
>


[jQuery] Re: How to logically AND selectors?

2008-01-30 Thread Karl Rudd

You're looking for:

.selector1.selector2.selector3

Notice there are no spaces between the selectors.

Karl Rudd

On Jan 31, 2008 1:12 PM, Kynn Jones <[EMAIL PROTECTED]> wrote:
>
> Hi.  The docs describe selectors of the form
>
>   selector1, selector2, selector3
>
> as "matching the combined results of all the specified selectors", by
> which they mean the set union of all the individual selections.  In
> other words, the ',' here behaves like a logical OR.
>
> Is there a succinct way to perform the correspond logical AND?  I.e.
> what's the best way to obtain the set intersection of multiple
> selections?
>
> TIA!
>
> kynn
>


[jQuery] Re: Fighting a closure

2008-01-30 Thread Ariel Flesler

The only thing you need to do is to capture the number on a scope.
Like this:

function bind( num ){
   $('#port'+num).click(function(){ bigchart(num); });
};
for( var i=0; i<5; i++ )
bind( i );

And voila, you can also do:

function getHandler( num ){
   return function(){ bigchart(num); });
};
for( var i=0; i<5; i++ )
$('#port'+i).click( getHandler(i) );

Hope that helps
Cheers

Ariel Flesler


On 30 ene, 23:28, Feijó <[EMAIL PROTECTED]> wrote:
> I'm yet to be an expert in jQuery :)  But I would solve that like this:
>
>   $(".port").click(function() {bigchart($(this).attr('port-id') )});
>
> now in your html code, I guess its like:
>
>     
>
> change to
>
>     
>
> Feijó
>
> timothytoe escreveu:
>
>
>
> > I think I submitted a half-done version of this message by accident a
> > few minutes ago. Sorry.
>
> > This works:
> >   $("#port0").click(function() {bigchart(0)});
> >   $("#port1").click(function() {bigchart(1)});
> >   $("#port2").click(function() {bigchart(2)});
> >   $("#port3").click(function() {bigchart(3)});
> >   $("#port4").click(function() {bigchart(4)});
>
> > I try to roll it up like this:
> >   for (i=0;i<5;i++) {
> >     $("#port"+i).click(function() {bigchart(i)});
> >   }
>
> > But the closure gets me. When the function is called, i is 5 for any
> > of the buttons.
> > What is the elegant solution here?- Ocultar texto de la cita -
>
> - Mostrar texto de la cita -


[jQuery] Re: Fighting a closure

2008-01-30 Thread Karl Swedberg


On Jan 30, 2008, at 3:10 PM, timothytoe wrote:



I think I submitted a half-done version of this message by accident a
few minutes ago. Sorry.

This works:
 $("#port0").click(function() {bigchart(0)});
 $("#port1").click(function() {bigchart(1)});
 $("#port2").click(function() {bigchart(2)});
 $("#port3").click(function() {bigchart(3)});
 $("#port4").click(function() {bigchart(4)});

I try to roll it up like this:
 for (i=0;i<5;i++) {
   $("#port"+i).click(function() {bigchart(i)});
 }

But the closure gets me. When the function is called, i is 5 for any
of the buttons.
What is the elegant solution here?


If you can assign class="port" to each of those elements, you could do  
this:


$('.port').each(function(index) {
$(this).click(function() {bigchart(index)});
}

if you can't assign a class, then change $('.port') to $ 
('[id^=port]') , as Josh suggested.



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



[jQuery] How to logically AND selectors?

2008-01-30 Thread Kynn Jones

Hi.  The docs describe selectors of the form

  selector1, selector2, selector3

as "matching the combined results of all the specified selectors", by
which they mean the set union of all the individual selections.  In
other words, the ',' here behaves like a logical OR.

Is there a succinct way to perform the correspond logical AND?  I.e.
what's the best way to obtain the set intersection of multiple
selections?

TIA!

kynn


[jQuery] Re: Fighting a closure

2008-01-30 Thread Feijó


I'm yet to be an expert in jQuery :)  But I would solve that like this:

 $(".port").click(function() {bigchart($(this).attr('port-id') )});


now in your html code, I guess its like:

   

change to

   


Feijó

timothytoe escreveu:

I think I submitted a half-done version of this message by accident a
few minutes ago. Sorry.

This works:
  $("#port0").click(function() {bigchart(0)});
  $("#port1").click(function() {bigchart(1)});
  $("#port2").click(function() {bigchart(2)});
  $("#port3").click(function() {bigchart(3)});
  $("#port4").click(function() {bigchart(4)});

I try to roll it up like this:
  for (i=0;i<5;i++) {
$("#port"+i).click(function() {bigchart(i)});
  }

But the closure gets me. When the function is called, i is 5 for any
of the buttons.
What is the elegant solution here?
  


[jQuery] Re: Superfish 1.4.1 update released

2008-01-30 Thread Joel Birch

On 31/01/2008, Olivier Percebois-Garve <[EMAIL PROTECTED]> wrote:
>
>  Hi Joel,
>  I'll try to give you some feedback.

Hi Olivier,
Thanks very much for the feedback, it really is very useful.

>  First some remarks and questions and then a bug report :
>  You may change some filenames. For instance helperPlugin.js to
> hoverIntent.js or vertical.css to superfish-vertical.css

Agreed. I'll separate out the bgIframe and hoverIntent plugins into
clearly named separate JS files.


>  I think it would be nice to put an exemple menu at the top of the superfish
> homepage so that a new user can immediatelly see what it about.

I'll have a think about this one.


>  About the callbacks. Would they enable us to write for instance this code
> outside of superfish ?
>  http://www.klaasse.net/superfish-ext/superfish.html

Yes. This is precisely the reason for the new callbacks. In fact I
rewrote Jesse Klaasse's code to use the callbacks and the demo page
can be found here:
http://users.tpg.com.au/j_birch/plugins/superfish/supposition-test/menuAtTop.html

I gave it the plugin of the plugin the name "Supposition" which is the
crapiest name ever. Anyway, there are still issues with that code
because when the document is longer than the window depth the
scrolling is not taken into account when positioning the submenus
which is disappointing. I don't know if this is a jQuery bug or a
problem with the Supposition (hate that name so much) code as I am a
n00b when it comes to dimensions code. I flicked my work back to Jesse
to look at and also posted it to this group. Here's the thread:
http://groups.google.com/group/jquery-en/browse_thread/thread/c4a290fc6a2f6bfd


>
>  I have a link that you may have a look to. The HTML is not very neat and it
> lacks accessibility but the transparency handling is really impressive:
> http://www.myluckystar.lu/pwc/My-job/Find-your-Lucky-Star/Find-your-Lucky-Star
>  Do you think it could be done using superfish and its callbacks ?

Not sure what you mean by the transparency handling, but that menu
looks do-able with Superfish, even without callbacks. I guess it's
just a regular drop-down menu with a custom animation (probably using
negative top or negative margin-top) and png background images stuck
to the bottom of the list item for the angled edges. You are right
about the accessibility being non-existent on that menu - sounds like
a job for Superfish! ;)


>
>  #Bug report
>  using
> http://users.tpg.com.au/j_birch/plugins/superfish/vertical-example/
>  on my 1024x768 laptop
>
>  1.Small css issue in FF, Opera,IE6
>  when the submenu deploys the right border moves 1px to the right.
>  In FF it can be fixed with the following change:
>  .nav li ul {
>  top:-999em;
>  position:absolute;
>  width:10.55em;
>  }

Yep thanks, I've fixed that now.


>  2."Persistant area" bug in Opera
>  If you hover and then move away, the is a blue rectangle that persists
> where the bottom
>  of the submenu was. I have no fix for this.

This is pretty special. Obviously an exotic Opera rendering bug of
some sort. I'll see if there is anything I can do to avoid it next
time I get chance to have an experiment.


>
>  3.Opera, very minor, but hovering the first pixel row of an item triggers
> the change of background
>  color but not the display of the submenu.

I couldn't reproduce this on Mac Opera but will have a look on others
when I get chance.


>
>  4.another subtle unwanted behavior:
>   At the end of the display animation of the submenus of the second and
> forth item, the text and the bottom border of the first of the submenu has a
> 1px movement to the bottom.
>  It seems weird, I dont know anybody else can reproduce it. Personally it
> tend to believe that it is linked to some "em" calculations, and maybe that
> my computer is rather slow, so I have the time to see it.

I think this is indeed linked to some "em" calculations. I discussed
this with Jesse Klaasse in the thread listed above. I also found a
slight fix (see that thread for explanation).


>
>  5. similar to #4 on
> http://users.tpg.com.au/j_birch/plugins/superfish/all-horizontal-example/
> the "d" submenu item behaves oddly.

See previous comment.


>  Thank for this release, its getting better and better !
>  Olivier

Thank you Olivier for your valuable feedback!

Joel Birch.


[jQuery] Re: Fighting a closure

2008-01-30 Thread Josh Nathanson


There is a clever way -- in John Resig's book he talks about it -- it 
involves executing the anonymous function right after declaring it, when in 
a for loop:


function() { do whatever; }();

But, I tried some experiments and I couldn't get it to work right.

-- Josh




I ended up doing something similar to what you suggest, but I really
was hoping to elicit some clever way to get the value of the variable
at the time of the assignment, rather than the "5" that I get because
the closure is maintaining the context.

Is there a way to set these event handlers up in jQuery without using
a closure?

 --T

On Jan 30, 4:36 pm, "Josh Nathanson" <[EMAIL PROTECTED]> wrote:

Instead of binding five times, you can do it dynamically:

$("[id^=port]").click(function() {
bigchart( this.id.charAt(this.id.length-1) );

});

Something close to that should do it.  Although if you end up with 10 or
more clickables you'll have to change your naming scheme a bit.

-- Josh

- Original Message -
From: "timothytoe" <[EMAIL PROTECTED]>
To: "jQuery (English)" 
Sent: Wednesday, January 30, 2008 12:10 PM
Subject: [jQuery] Fighting a closure

> I think I submitted a half-done version of this message by accident a
> few minutes ago. Sorry.

> This works:
>  $("#port0").click(function() {bigchart(0)});
>  $("#port1").click(function() {bigchart(1)});
>  $("#port2").click(function() {bigchart(2)});
>  $("#port3").click(function() {bigchart(3)});
>  $("#port4").click(function() {bigchart(4)});

> I try to roll it up like this:
>  for (i=0;i<5;i++) {
>$("#port"+i).click(function() {bigchart(i)});
>  }

> But the closure gets me. When the function is called, i is 5 for any
> of the buttons.
> What is the elegant solution here? 




[jQuery] Re: Fighting a closure

2008-01-30 Thread timothytoe

I ended up doing something similar to what you suggest, but I really
was hoping to elicit some clever way to get the value of the variable
at the time of the assignment, rather than the "5" that I get because
the closure is maintaining the context.

Is there a way to set these event handlers up in jQuery without using
a closure?

  --T

On Jan 30, 4:36 pm, "Josh Nathanson" <[EMAIL PROTECTED]> wrote:
> Instead of binding five times, you can do it dynamically:
>
> $("[id^=port]").click(function() {
> bigchart( this.id.charAt(this.id.length-1) );
>
> });
>
> Something close to that should do it.  Although if you end up with 10 or
> more clickables you'll have to change your naming scheme a bit.
>
> -- Josh
>
> - Original Message -
> From: "timothytoe" <[EMAIL PROTECTED]>
> To: "jQuery (English)" 
> Sent: Wednesday, January 30, 2008 12:10 PM
> Subject: [jQuery] Fighting a closure
>
> > I think I submitted a half-done version of this message by accident a
> > few minutes ago. Sorry.
>
> > This works:
> >  $("#port0").click(function() {bigchart(0)});
> >  $("#port1").click(function() {bigchart(1)});
> >  $("#port2").click(function() {bigchart(2)});
> >  $("#port3").click(function() {bigchart(3)});
> >  $("#port4").click(function() {bigchart(4)});
>
> > I try to roll it up like this:
> >  for (i=0;i<5;i++) {
> >$("#port"+i).click(function() {bigchart(i)});
> >  }
>
> > But the closure gets me. When the function is called, i is 5 for any
> > of the buttons.
> > What is the elegant solution here?


[jQuery] Re: Email validation broken in plugin v1.2?!

2008-01-30 Thread Rus Miller

I agree, [EMAIL PROTECTED] isn't likely to be used anytime soon in a real-
world situation.

I've hacked the plugin on line 865 from:

return this.optional(element) || /^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?
\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\
$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])
+)*)|((\x22)\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b
\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-
\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF
\uF900-\uFDCF\uFDF0-\uFFEF]*(((\x20|\x09)*(\x0d\x0a))?(\x20|
\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-
\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|
\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|
[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)*(([a-z]|[\u00A0-\uD7FF
\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-
\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-
\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?$/
i.test(value);

to:

return this.optional(element) || /^[_a-z0-9-]+(\.[_a-z0-9-]+)[EMAIL PROTECTED]
z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,3})$/i.test(value);

This seems to work for me.  Please test and let me know.

On Jan 30, 4:55 pm, Seth - TA <[EMAIL PROTECTED]> wrote:
> Is there a way to change that? Or, what part of the email regex could
> I modify? I would think that most people would agree with me that
> @localhost wouldn't really be a valid email for production use. If I
> am wrong, then tell me, however, could you point me in the right
> direction to not allow a valid email without a .com, .net, etc, etc.
> Thanks.
>
> Regards,
>
> Seth
>
> On Jan 28, 3:10 pm, Jörn Zaefferer <[EMAIL PROTECTED]> wrote:
>
> > Yuval schrieb:> Thisemail
> > > [EMAIL PROTECTED]
> > > validates perfectly on v1.2. No .com nothing...
> > > Is it broken or is it done on purpose?
> > > I tried it on my site AND on the remember-the-milk demo...
>
> > Nope. Its perfectly valid, just as something like [EMAIL PROTECTED] is 
> > valid.
>
> > Jörn


[jQuery] Parsing external XML files - Events Format

2008-01-30 Thread Josoroma

Hi!

Im working in a project that needs to parse like 10 external XML or
RSS resources of events. Some of this XML resources uses this format:
http://web.resource.org/rss/1.0/modules/event/






Other resources are not using this standard tags, they use tags in
different languages like:





another example:





Some of this events have description others dont. Some events
are Google Calendar XML format.

My question to you is not about to do my homework, is about standards
and the best way to design or parse something that can have a lot of
differents
formats.

There exist a way to parse an xml file with different formats and
indentation of tags using Jquery?

Now im going to investigate:
http://blog.reindel.com/2007/09/24/jquery-and-xml-revisited/
http://ajaxian.com/archives/ajaxian-featured-tutorial-parsing-xml-with-jquery
http://cgaskell.wordpress.com/2006/11/02/jquery-ajax-call-and-result-xml-parsing/
http://ajaxian.com/archives/ajaxian-featured-tutorial-parsing-xml-with-jquery

Thanks in advance.


[jQuery] Re: Loading GIF Slideshow w/o Modal

2008-01-30 Thread Ange

Thanks. Can any of these be customized to be a non-modal, no thumbs
gallery? I need the first image of the galleries to be visible on page
load, and prev/next buttons to load images as needed.
-Ange

On Jan 30, 6:52 pm, "Benjamin Sterling"
<[EMAIL PROTECTED]> wrote:
> Ange,
> Have a look at one of these 
> plugins:http://benjaminsterling.com/category/jquery-plugin/


[jQuery] Re: Selector Containing Variable

2008-01-30 Thread [EMAIL PROTECTED]

You have to escape the first set of double quotes -- leave the single
quotes there.

var tabTest = "billy";
$(".orderInfo[id='" + tabTest + "'"];

On Jan 30, 7:24 am, studiobl <[EMAIL PROTECTED]> wrote:
> I'm having trouble with a jQuery selector that contains a variable.
> I'm trying to target an element that has a class of "orderInfo" and an
> id of "billy"
>
> So, I set a variable:
>
> var tabText = "billy";
>
> ...and it works if I use the string:
>
> $(".orderInfo[id='billy'"];
>
> ...but not the variable:
>
> $(".orderInfo[id=tabTest"];
>
> ...but of course I need it to work with a variable {insert appropriate
> emoticon here}


[jQuery] Re: Another IE Sliding bug, the weirdest (some elements disappear and others not on SlideDown)

2008-01-30 Thread Arkilus

Any suggestions?

On 27 jan, 18:45, Arkilus <[EMAIL PROTECTED]> wrote:
> While building my application with jQuery I found out this really
> weird internet explorer bug:
> Applying SlideDown to elements that are relative positioned or that
> have relative positioned parents, some elements just disappears.
> This behaviour may be checked athttp://www.arkilus.blogspot.comand a
> clean html athttp://paste.lymas.com.br//?q=22246
>
> Performing some tests i found out some actions that bring that
> elements back:
> - Edit ANY css property live with IE Devoloper Toolbar
> - Fade effects in any part of the page
> - While the slider is sliding up
>
> This is so far the weirdest IE bug I could notice.


[jQuery] Re: Fighting a closure

2008-01-30 Thread Josh Nathanson


Instead of binding five times, you can do it dynamically:

$("[id^=port]").click(function() {
   bigchart( this.id.charAt(this.id.length-1) );
});

Something close to that should do it.  Although if you end up with 10 or 
more clickables you'll have to change your naming scheme a bit.


-- Josh



- Original Message - 
From: "timothytoe" <[EMAIL PROTECTED]>

To: "jQuery (English)" 
Sent: Wednesday, January 30, 2008 12:10 PM
Subject: [jQuery] Fighting a closure




I think I submitted a half-done version of this message by accident a
few minutes ago. Sorry.

This works:
 $("#port0").click(function() {bigchart(0)});
 $("#port1").click(function() {bigchart(1)});
 $("#port2").click(function() {bigchart(2)});
 $("#port3").click(function() {bigchart(3)});
 $("#port4").click(function() {bigchart(4)});

I try to roll it up like this:
 for (i=0;i<5;i++) {
   $("#port"+i).click(function() {bigchart(i)});
 }

But the closure gets me. When the function is called, i is 5 for any
of the buttons.
What is the elegant solution here? 




[jQuery] Re: Is this the best way?

2008-01-30 Thread Feijó


Yeah, its all div and within a particular parent!! I'm alreading having 
that kind of care, adding specificity for all my selectors.


It should improve performance, I bet :)

Thanks Joel


Joel Birch escreveu:

On 31/01/2008, Feijó <[EMAIL PROTECTED]> wrote:

  

Its possible to simple use like this?
$('.qualif[level>3]').remove();



I don't think there is a way to do that unfortunately.

Pete had a good point about optimising your selector for speed though.
For example, if you know all the .qualif elements are divs and are all
within a particular parent that has an id, say 'content', then you
should write the selector with greater specificity like so:

$('#content div.qualif').filter( ...

Joel Birch.
  


[jQuery] jScrollPane: hide an arrow at end of content?

2008-01-30 Thread DingoNV

i was wondering if anyone has a quick and easy way to hide an arrow if
you are at the beginning or end of the scrollable content.

for instance
i would want the top arrow to not be visible at first, because there
is no content above it.

and when i reach the end of the content, i would like the down arrow
to disappear.

I know enough to just set the position of the arrow object to some
place so that it's not visible, but i don't know enough jQuery or how
jScrollPane works to figure out how too do this.

Is there an event that is triggered by jScrollPane when scrolling
stops that reports the position?

thanks for any help.


[jQuery] Re: Superfish 1.4.1 update released

2008-01-30 Thread Olivier Percebois-Garve

Hi Joel,

I'll try to give you some feedback.

First some remarks and questions and then a bug report :

You may change some filenames. For instance helperPlugin.js to 
hoverIntent.js or vertical.css to superfish-vertical.css


I think it would be nice to put an exemple menu at the top of the 
superfish homepage so that a new user can immediatelly see what it about.


About the callbacks. Would they enable us to write for instance this 
code outside of superfish ?

http://www.klaasse.net/superfish-ext/superfish.html

I have a link that you may have a look to. The HTML is not very neat and 
it lacks accessibility but the transparency handling is really impressive:

http://www.myluckystar.lu/pwc/My-job/Find-your-Lucky-Star/Find-your-Lucky-Star
Do you think it could be done using superfish and its callbacks ?


#Bug report
using http://users.tpg.com.au/j_birch/plugins/superfish/vertical-example/
on my 1024x768 laptop

1.Small css issue in FF, Opera,IE6
when the submenu deploys the right border moves 1px to the right.
In FF it can be fixed with the following change:
.nav li ul {
   top:-999em;
   position:absolute;
   width:10.*5*5em;
}

2."Persistant area" bug in Opera
If you hover and then move away, the is a blue rectangle that persists 
where the bottom

of the submenu was. I have no fix for this.

3.Opera, very minor, but hovering the first pixel row of an item 
triggers the change of background

color but not the display of the submenu.

4.another subtle unwanted behavior:
At the end of the display animation of the submenus of the second and 
forth item, the text and the bottom border of the first of the submenu 
has a 1px movement to the bottom.
It seems weird, I dont know anybody else can reproduce it. Personally it 
tend to believe that it is linked to some "em" calculations, and maybe 
that my computer is rather slow, so I have the time to see it.


5. similar to #4 on 
http://users.tpg.com.au/j_birch/plugins/superfish/all-horizontal-example/

  the "d" submenu item behaves oddly.




Thank for this release, its getting better and better !

Olivier


Joel Birch wrote:

Hi everyone,

Just a quick announcement to help keep interested parties up-to-date
on the progress of the Superfish menu plugin. I just released version
1.4.1. In addition to some code optimisations, some notable changes
are:

- more optional callback functions to hang your enhancements off. I'm
hoping this will mean that if you have ideas for new functionality
that do not justify being in the core itself, you can now add it via
the callbacks leaving the core lean and easily update-able.

- version 1.4.1 is now fully compatible with jQuery versions going
right back to 1.1.2 so you can use the latest Superfish release even
if you are stuck using an old version of jQuery. Just set the new
'oldJquery' setting to 'true' for jQuery versions prior to 1.2

- you can set the new 'disableHI' setting to 'true' to make Superfish
ignore the presence of the hoverIntent plugin for the rare cases when
you want a long hoverIntent delay, for Cluetip for example, at the
price of no delay for your Superfish menu.

- finally resolved a long-standing bug whereby, when using the
pathClass option (see the two-tiered-horizontal navbar example page),
the path to the current page was not being restored after using the
keyboard to navigate through the links.

I'm very happy with this release - it seems really bulletproof. I've
thoroughly tested it on all the usual browsers and platforms, but if
you notice any odd behaviour I would really appreciate the feedback!

Thanks for your time.
http://users.tpg.com.au/j_birch/plugins/superfish/

Joel Birch.

  




[jQuery] Re: Loading GIF Slideshow w/o Modal

2008-01-30 Thread Benjamin Sterling
Ange,
Have a look at one of these plugins:
http://benjaminsterling.com/category/jquery-plugin/



On 1/30/08, Ange <[EMAIL PROTECTED]> wrote:
>
>
> I'm looking for a jQuery slideshow plugin, and I can't seem to fond
> one that does all I need. Cycle and jCarousel come close. But my
> problem is I have multiple galleries on one page, and they all have
> large images. So, since they load all the images in every gallery and
> then hide them, the page totals over 4000KB.
>
> I need something like Litebox or Thickbox that calls the next/prev
> image and loads it as needed, with a loading gif. But I don't want a
> pop-up modal. It would be nice if I could just put one image from each
> gallery in the HTML and have the prev/next buttons load and fade to
> the prev/next image.
>
> Any suggestions?
>



-- 
Benjamin Sterling
http://www.KenzoMedia.com
http://www.KenzoHosting.com
http://www.benjaminsterling.com


[jQuery] Re: random option for Cycle not working?

2008-01-30 Thread Mike Alsup
What version of the plugin?


On Jan 30, 2008 1:26 PM, ZAP <[EMAIL PROTECTED]> wrote:

>
> For some reason, Cycle is not randomizing the order of my blurbs.
>
> 
> $(document).ready(function(){$('#blurbs').cycle({fx:'turnDown',random:
> 1,timeout:1});});
> 
>
> Anyone know why this might be?
>


[jQuery] Re: Multiple Superfish on the same page problems

2008-01-30 Thread Joel Birch

Hi there,

It looks like you just need to add a width to your .nav rule. try
width:183px; to begin with as this worked for me via Firebug.

Joel Birch.


[jQuery] Re: [validate] Require with more then one selector

2008-01-30 Thread Jörn Zaefferer


Sudrien schrieb:

Pardon the mixing of comment formats.



// must be non-blank - values are digits
...

// "Port not found" in previous list - values are strings
...

// "Port not found" in previous list - value is a string


// "Port not found" AND "Country not found" - how do I require both?



Can I do this as a class definition?
  

In that I highly recommend just using a custom method.

See http://docs.jquery.com/Plugins/Validation/Validator/addMethod and 
the billingRequired method here: 
http://jquery.bassistance.de/validate/demo/marketo/mktSignup.js


Jörn


[jQuery] Re: Multiple jCarousel 's on one page

2008-01-30 Thread Josh V

help.

On Jan 25, 10:37 am, Josh V <[EMAIL PROTECTED]> wrote:
> hi.
>
> On Dec 19 2007, 3:02 pm, Josh V <[EMAIL PROTECTED]> wrote:
>
> > help.
>
> > On Nov 30, 4:55 pm, Josh V <[EMAIL PROTECTED]> wrote:
>
> > > anybody?
>
> > > On Nov 29, 5:03 pm, Josh V <[EMAIL PROTECTED]> wrote:
>
> > > > hi. i have a site where i need two different carousels on the same
> > > > page. each carousel has a different purpose with different items and
> > > > different controls. how can i go about getting this done? it seems to
> > > > me there would be a css conflict issue with the jquery.jcarousel.css
> > > > file. how do i specify 2 different css files for each carousel?


[jQuery] Problem with sortables plugin (interface.js)

2008-01-30 Thread noff

Please, help! I can't understand.

I'm using plugin "interface.js" - sortables.

I have 2 dropables fields and some sortables elements.

It's works in FireFox and Opera, but in IE, once I grag one element,
next time it's can not be dragged:

http://test.mkechinov.ru/rc/rc.htm - dont worry about symbols - it's
Russian.

Try to drag one element, drop it and then drag again. What is wrong in
code?


[jQuery] hi, im looking for some jcarousel help. more than one on same page?

2008-01-30 Thread Josh V

http://groups.google.com/group/jquery-en/browse_thread/thread/7e44db31deae3703/8909400f98de18c8#8909400f98de18c8


[jQuery] idle.slashdot.org uses jQuery

2008-01-30 Thread PragueExpat

Not much activity on the site yet (its new), but its nice to see that
they appreciate and use a great javascript library


[jQuery] Re: Selector Containing Variable

2008-01-30 Thread FrenchiINLA

you can try $('#' + tabtext) since the id is unic you don't need the
class.

On Jan 30, 7:24 am, studiobl <[EMAIL PROTECTED]> wrote:
> I'm having trouble with a jQuery selector that contains a variable.
> I'm trying to target an element that has a class of "orderInfo" and an
> id of "billy"
>
> So, I set a variable:
>
> var tabText = "billy";
>
> ...and it works if I use the string:
>
> $(".orderInfo[id='billy'"];
>
> ...but not the variable:
>
> $(".orderInfo[id=tabTest"];
>
> ...but of course I need it to work with a variable {insert appropriate
> emoticon here}


[jQuery] Multiple Superfish on the same page problems

2008-01-30 Thread alivemedia

I am trying to have 3 different vertical lists that have flyouts for
navigation.

Here is the site (I know it is a mess right now):
http://visitpalmbeach-com.alivedns.com/default.aspx

Problem is the second and third menus get displayed horizontally.  The
flyouts works but the display is borked.

If you mouse over the Kayak Tours & Rentals you will see the fly out
in the first menu.

If you mouse over Attractions & Arts you will see another menu working
just displayed crazy.

Thanks for any help!



[jQuery] change on select not working

2008-01-30 Thread RyanMC

$("select").change(function(){
alert("Selected: " + this.value);
});


Is there any reason why this wouldn't be working on all the selects on
my page.

I create the selects dynamically, but this is up in the $
(document).ready(function() { block of my code.


[jQuery] Re: Selector Containing Variable

2008-01-30 Thread Bohdan Ganicky


Hi,

as Karl said...and you could also make things a little bit shorter by using
multiple selector:

var tabText = 'billy';
$('.orderInfo#'+tabText];

--
Bohdan
-- 
View this message in context: 
http://www.nabble.com/Selector-Containing-Variable-tp15188162s27240p15194100.html
Sent from the jQuery General Discussion mailing list archive at Nabble.com.



[jQuery] Re: Validation plugin - spinner while validating field?

2008-01-30 Thread Rus Miller

My issue is that remote requests, especially those involving an
external server, can take a second or two.   It's nice to give the
user an indication that something is happening, which is why a spinner
isn't 'useless'.  It would be great if someone could give me a push in
the right direction.

Also, I noticed that even though the 'Check URL' field on my form
(http://monovisiondesign.com/client/jquery/validate-url/form.php) is
not required, it still performs a remote call and a label.checked is
applied to the field when it's left empty.  Am I doing something wrong
or is there a way to prevent that?

On Jan 30, 1:17 pm, Jörn Zaefferer <[EMAIL PROTECTED]> wrote:
> Rus Miller schrieb:> There is a label.error and a label.checked but does 
> anyone know how I
> > would display a label.pending (perhaps with a spinner) while the
> > validation (especially a remote request) is happening?
>
> > Thanks.
>
> You can still use jQuery's ajax events to display a 
> busy-indicator:http://docs.jquery.com/Ajax_Events
>
> I acutally considered a pending state for remote-validated-fields, but
> dropped the idea in favor of a lack of those useless spinner icons. I
> found the goal to make the remote validation as unobtrusive as possible
> to the user a more worthwhile goal.
>
> Jörn


[jQuery] Re: [validate] Email validation broken in plugin v1.2?!

2008-01-30 Thread Seth - TA

Is there a way to change that? Or, what part of the email regex could
I modify? I would think that most people would agree with me that
@localhost wouldn't really be a valid email for production use. If I
am wrong, then tell me, however, could you point me in the right
direction to not allow a valid email without a .com, .net, etc, etc.
Thanks.

Regards,

Seth

On Jan 28, 3:10 pm, Jörn Zaefferer <[EMAIL PROTECTED]> wrote:
> Yuval schrieb:> Thisemail
> > [EMAIL PROTECTED]
> > validates perfectly on v1.2. No .com nothing...
> > Is it broken or is it done on purpose?
> > I tried it on my site AND on the remember-the-milk demo...
>
> Nope. Its perfectly valid, just as something like [EMAIL PROTECTED] is valid.
>
> Jörn


[jQuery] Re: [SITE SUBMISSION] Sapitot Creative

2008-01-30 Thread motob

I had some trouble getting that history plugin to corporate with
ui.tabs. I'll take another stab at it, maybe there are some updated
documentation in that area.

I had not run into that "Loading..." issue when I was running thru it,
but I always waited until the transition finish. Ah the beauty of
having other developers test. The loading... feature is automatic in
the ui.tabs plugin. I'll see if I can use one of the callback
functions to double check if the "tab" stuck on loading... and change
it back to normal.

Thanks Dan and Ben!

Brian

On Jan 30, 3:04 pm, "Benjamin Sterling"
<[EMAIL PROTECTED]> wrote:
> Looks really nice, but I would second Dan's comments and would probably
> suggest you implement the history plugin.  Being in the DC area, 508
> compliance is a big sell.
>
> On 1/30/08, Dan G. Switzer, II <[EMAIL PROTECTED]> wrote:
>
>
>
>
>
> > >Sapitot Creative is a Design firm that recently redesigned their
> > >website. jQuery is being used to enhance page transitions and to give
> > >a little flair to the print and web portfolio sections. What is real
> > >interesting is the unconventional use of jQuery-ui.tabs plugin for the
> > >main navigation.
>
> > >Check it out:www.sapitot.com
>
> > Overall it looks good. A couple of comments:
>
> > 1) I'd change the URL each time one of the tabs is clicked--that way users
> > can cut-n-paste the URLs and e-mail them. If possible, it'd also use
> > meaningful hashes (like #store, #web, #print, #about, etc.)
>
> > 2) Occasionally I was able to get the "Loading..." message that appears
> > when
> > you've clicked on a category to never go away. It seems to happen if you
> > click on another menu option before the last animation has finished. (I
> > suspect you're using a global variable to reset the value and this is
> > getting overwritten.)
>
> > -Dan
>
> --
> Benjamin 
> Sterlinghttp://www.KenzoMedia.comhttp://www.KenzoHosting.comhttp://www.benjaminsterling.com


[jQuery] Re: [SITE SUBMISSION] Sapitot Creative

2008-01-30 Thread Rus Miller

Also, you could dim the first view and thumbnail on the print and web
pages to show that they're currently displayed.

A beautiful site, though!  I was actually planning on doing the same
drop-down effect on my site redesign (which should be done sometime in
'09).  Stole my thunder!

On Jan 30, 3:04 pm, "Benjamin Sterling"
<[EMAIL PROTECTED]> wrote:
> Looks really nice, but I would second Dan's comments and would probably
> suggest you implement the history plugin.  Being in the DC area, 508
> compliance is a big sell.
>
> On 1/30/08, Dan G. Switzer, II <[EMAIL PROTECTED]> wrote:
>
>
>
>
>
> > >Sapitot Creative is a Design firm that recently redesigned their
> > >website. jQuery is being used to enhance page transitions and to give
> > >a little flair to the print and web portfolio sections. What is real
> > >interesting is the unconventional use of jQuery-ui.tabs plugin for the
> > >main navigation.
>
> > >Check it out:www.sapitot.com
>
> > Overall it looks good. A couple of comments:
>
> > 1) I'd change the URL each time one of the tabs is clicked--that way users
> > can cut-n-paste the URLs and e-mail them. If possible, it'd also use
> > meaningful hashes (like #store, #web, #print, #about, etc.)
>
> > 2) Occasionally I was able to get the "Loading..." message that appears
> > when
> > you've clicked on a category to never go away. It seems to happen if you
> > click on another menu option before the last animation has finished. (I
> > suspect you're using a global variable to reset the value and this is
> > getting overwritten.)
>
> > -Dan
>
> --
> Benjamin 
> Sterlinghttp://www.KenzoMedia.comhttp://www.KenzoHosting.comhttp://www.benjaminsterling.com


[jQuery] Re: Not Submit [validate]

2008-01-30 Thread Marcos Aurélio


Thanks for the answer!

I think you should put your validate / delegate / ajaxQueue in the
same file. In my case, and the majority, only use these two plugins to
run validate, and for this reason we have to include 3 files.

Make a package, all built.

Bye!

On 30 jan, 15:48, Jörn Zaefferer <[EMAIL PROTECTED]> wrote:
> Marcos Aurélio schrieb:> Ok, see:
>
> > Joinhttp://www.animeschool.com.br/example/.
>
> > First test:
> > Put in login "AAA" and name "bbb" click the button and submit it.
>
> > Second test:
> > First click the button. He acknowledge the mistakes, all ok. Now fill
> > in the fields with "AAA" and "bbb" and click the button. He did not
> > submit.
>
> Thanks for the testpage and description, that helped a lot. The easiest
> way to solve this issue is to include the ajaxQueue plugin (see
> lib/jquery.ajaxQueue.js in the download package).
>
> To prevent the issue to come up again I'll make the ajaxQueue plugin
> required for remote validation. Currently I've got no better idea then
> just display a completely annoying alert when the ajaxQueue plugin isn't
> included. Other ideas are welcome.
>
> Regards
> Jrn


[jQuery] Loading GIF Slideshow w/o Modal

2008-01-30 Thread Ange

I'm looking for a jQuery slideshow plugin, and I can't seem to fond
one that does all I need. Cycle and jCarousel come close. But my
problem is I have multiple galleries on one page, and they all have
large images. So, since they load all the images in every gallery and
then hide them, the page totals over 4000KB.

I need something like Litebox or Thickbox that calls the next/prev
image and loads it as needed, with a loading gif. But I don't want a
pop-up modal. It would be nice if I could just put one image from each
gallery in the HTML and have the prev/next buttons load and fade to
the prev/next image.

Any suggestions?


[jQuery] Re: JQuery UI and ExtJS

2008-01-30 Thread Cloudream

Ext has its own accordion panel

On Jan 31, 12:01 am, "Stéphane Walther" <[EMAIL PROTECTED]> wrote:
> Hi there,
>
> I tried to nest an ExtJS TreePanel into an Accordion menu (provided by
> jQueryUI) like this :
> -Header1
> -Header2
>     MyTree
> -Header3
>
> When I click on Header2, the TreePanel works fine (on FF only, IE doesn't
> seems to work). If I click on another header and come back to Header2, the
> the accordion doesn't seem to adapt his size to the tree : some of my child
> nodes are hidden. Any idea to fix that?
>
> Thanks for your help.


[jQuery] Fighting a closure

2008-01-30 Thread timothytoe

I think I submitted a half-done version of this message by accident a
few minutes ago. Sorry.

This works:
  $("#port0").click(function() {bigchart(0)});
  $("#port1").click(function() {bigchart(1)});
  $("#port2").click(function() {bigchart(2)});
  $("#port3").click(function() {bigchart(3)});
  $("#port4").click(function() {bigchart(4)});

I try to roll it up like this:
  for (i=0;i<5;i++) {
$("#port"+i).click(function() {bigchart(i)});
  }

But the closure gets me. When the function is called, i is 5 for any
of the buttons.
What is the elegant solution here?


[jQuery] onClick prepend

2008-01-30 Thread Mark T
I am trying to make the on-click event of any element optional depending on
what the user decides. The only functions I see out there append a function
to the on-click event. I have played with the browser bubbling / catching
stuff too. That worked in Firefox but not in IE 7. It seems I can't access
the on-click function if it was defined within the element's onclick=""
attribute.

Here are my two approaches. Tell me if you have a better idea.

1) eval() // I guess IE doesn't like us using this. Firefox doesn't
care.

$(document).ready(function() {
var onClickAttr = $('#clickTester').attr('onclick');
$('#clickTester').removeAttr('onclick').click(function(){
if (confirm('Perform Original Action?')) {
eval(onClickAttr);
}
}
});



2) Bubbling // Again, IE problems while Firefox works just fine.

$(document).ready(function() {
var $span = $('<span></span>').attr('onclick',
$('#clickTester').attr('onclick'));
$('#clickTester').removeAttr('onclick').wrap($span);
$('#clickTester').click(function(event){
if (!confirm('Perform Original Action?')) {
event.stopPropagation();
}
});
});




[jQuery] JQuery - Interface question

2008-01-30 Thread JPC

Hi all,

I just built out a search page using the Jquery Interface plug-in.
Specifically the slider function.

You can view it on this page:
http://www.totalbeauty.com/reviews/product_finder

Unfortunately, the prices do not update as you slide the sliders. They
update when you stop and unclick. I used one of the demos as a base,
and did some minor tweaking. So, I have no idea why the prices aren't
updating on the fly.

Here's the demo I used:
http://interface.eyecon.ro/demos/slider_minmax.html

Any help would be greatly appreciated.

Jason Cole


[jQuery] Fighting a closure

2008-01-30 Thread timothytoe

This code works...

  $("#port0").click(function() {bigchart(0)});
  $("#port1").click(function() {bigchart(1)});
  $("#port2").click(function() {bigchart(2)});
  $("#port3").click(function() {bigchart(3)});
  $("#port4").click(function() {bigchart(4)});

Naturally, I want to do this:

var portname="#port"+i;


[jQuery] random option for Cycle not working?

2008-01-30 Thread ZAP

For some reason, Cycle is not randomizing the order of my blurbs.


$(document).ready(function(){$('#blurbs').cycle({fx:'turnDown',random:
1,timeout:1});});


Anyone know why this might be?


[jQuery] Re: Shadowbox Media Viewer

2008-01-30 Thread blaf

Does it work with an imagemap?

Blaise


[jQuery] Re: UI.TABS - how to load content when tab is selected

2008-01-30 Thread MorningZ

Look at the "Ajax Tabs" section of the Tabs demo page (http://
stilbuero.de/jquery/tabs_3/)





On Jan 30, 9:14 am, carvingcode <[EMAIL PROTECTED]> wrote:
> I have a tab that I don't want the content (generated from a
> separate .php file) to load untilt he user selects the tab.
>
> How can I do this?
>
> TIA


[jQuery] [validate] Require with more then one selector

2008-01-30 Thread Sudrien

Pardon the mixing of comment formats.



// must be non-blank - values are digits
...

// "Port not found" in previous list - values are strings
...

// "Port not found" in previous list - value is a string


// "Port not found" AND "Country not found" - how do I require both?



Can I do this as a class definition?

Sud.


[jQuery] Re: inserting adsense

2008-01-30 Thread Cloudream

var ads = $(this).html();

On Jan 30, 9:06 pm, felipe <[EMAIL PROTECTED]> wrote:
> Hello,
>
> I am trying to insert adsense code as follows:
>
> var ads = $(this).text(); /// the adsense code goes here
>
> $(tr).append( '' + ads + '' ) ;
> $(tr).addClass('ads');
> $('table#' + tablename + ' tr.header').after(tr);
>
> Nothing happens. If I put some other  html code into scalar ads, it
> works.
>
> Any idea?
>
> Thank you,
>
> Felipe


[jQuery] Re: Is this the best way?

2008-01-30 Thread Joel Birch
On 31/01/2008, Feijó <[EMAIL PROTECTED]> wrote:

> Its possible to simple use like this?
> $('.qualif[level>3]').remove();

I don't think there is a way to do that unfortunately.

Pete had a good point about optimising your selector for speed though.
For example, if you know all the .qualif elements are divs and are all
within a particular parent that has an id, say 'content', then you
should write the selector with greater specificity like so:

$('#content div.qualif').filter( ...

Joel Birch.


[jQuery] Re: Inline "hover menu" needed

2008-01-30 Thread sozzi

You may want to have a look at:
cluetip: http://plugins.learningjquery.com/cluetip/demo/

On Jan 30, 12:15 pm, Sean O <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I'm looking for (likely) a plugin that will allow text/images to overlay a
> small menu when hovered on, disappearing onMouseOut after a second or two.
>
> Example:http://www.medhelp.org/posts/show/418157
>
> Something similar to the ContextMenu plugin would be great, if you could set
> the trigger to onMouseover versus right-click.
>
> Any ideas?
>
> Thanks,
> SEAN O
> www.sean-o.com
> --
> View this message in 
> context:http://www.nabble.com/Inline-%22hover-menu%22-needed-tp15191011s27240...
> Sent from the jQuery General Discussion mailing list archive at Nabble.com.


[jQuery] Re: there is a conflict ui.resizable.js and ajaxpro

2008-01-30 Thread Klaus Hartl

On Jan 30, 9:10 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote:
> resizable will not be able  when using ajaxpro,the javascript error:
> "c[0] has no properties"
>
> code:
> for(var i in this.options.modifyThese) {
> var c = this.options.modifyThese[i];
> c[0].css({
> width: modifier.width ? modifier.width+c[1] : nw+c[1],
> height: modifier.height ? modifier.height+c[2] : nh+c[2]
>
> });
> }

Just a guess, but these kind of errors occur if other libraries/
scripts modify the base Object, e.g. adding properties to its
prototype. A for-in loop then loops over these properties as well
giving you unexpected results. Doing this is considered bad practice
for obvious reasons.


--Klaus


[jQuery] Re: UI.TABS - how to load content when tab is selected

2008-01-30 Thread Klaus Hartl

On Jan 30, 3:14 pm, carvingcode <[EMAIL PROTECTED]> wrote:
> I have a tab that I don't want the content (generated from a
> separate .php file) to load untilt he user selects the tab.
>
> How can I do this?
>
> TIA

If the tab is not active it won't load anyway. Another option is to
set all tabs unselected:

$('#example').tabs({ unselected: true });

Or you can change the URL of a tab later and change it from being an
in-page tab to an Ajax tab using the tabsHref method:

var $tabs = $('#example').tabs();
$tabs.tabsHref(1, 'foo.php');

The panel the tab was associated with will be re-used for loading the
content into on the next click.


--Klaus


[jQuery] Re: simplemodal and datepicker

2008-01-30 Thread 1Marc

I've had a lot of questions about modal windows and UI Datepicker, so
I created a demo example using thickbox:

http://marcgrabanski.com/code/ui-datepicker/extras/thickbox-datepicker

I hope that helps.

On Jan 30, 10:55 am, Eric Martin <[EMAIL PROTECTED]> wrote:
> On Jan 30, 6:13 am, rayfidelity <[EMAIL PROTECTED]> wrote:
>
> > Hi,
>
> > I want to enable datepicker in the modal window that
> > opens...datepicker works fine for itself but i cannot get it to work
> > in modal. Any ideas?
>
> Can you clarify what you mean by "cannot get it to work in modal"?
>
>
>
> > Modal window is loaded through ajax...
>
> Do you have a page or code that we/I can view?
>
> -Eric


[jQuery] Inline "hover menu" needed

2008-01-30 Thread Sean O


Hi,


I'm looking for (likely) a plugin that will allow text/images to overlay a
small menu when hovered on, disappearing onMouseOut after a second or two.

Example:
http://www.medhelp.org/posts/show/418157

Something similar to the ContextMenu plugin would be great, if you could set
the trigger to onMouseover versus right-click.

Any ideas?


Thanks,
SEAN O

www.sean-o.com
-- 
View this message in context: 
http://www.nabble.com/Inline-%22hover-menu%22-needed-tp15191011s27240p15191011.html
Sent from the jQuery General Discussion mailing list archive at Nabble.com.



[jQuery] Re: Too many autocompleter plugins

2008-01-30 Thread eferraiuolo

This was a major reason for moving to YUI on a current project I'm
working on.


Eric

On Jan 27, 10:12 am, Christoph Haas <[EMAIL PROTECTED]> wrote:
> Fellow earthicans...
>
> A year ago I needed an autocompleter and tried Dylan Verheul's plugin
> (http://www.dyve.net/jquery/?autocomplete). I found that it lacked a few
> things and had some bugs I can't remember any more. Later I stumbled
> across a derived version 
> athttp://www.pengoworks.com/workshop/jquery/autocomplete.htm. It was a bit
> better but I couldn't switch off subset matching properly. Example...
>
> Pengoworks code:
>
>     options.matchSubset = options.matchSubset || 1;
>
> My patch:
>
>     options.matchSubset = options.matchSubset || 0;
>
> I'm not sure I'm right here but I couldn't pass on "matchSubset:0"
> because the "|| 1" would re-enable it. Or was I missing anything?
>
> Now I'm stuck with my hacked version of a hacked version of an
> autocomplete plugin that may have fixed a few things. Can anybody
> enlighten me which autocomplete plugin can decently be used? Thanks.
>
> Kindly
>  Christoph
> --
> [EMAIL PROTECTED]  www.workaround.org   JID: [EMAIL PROTECTED]
> gpg key: 79CC6586         fingerprint: 
> 9B26F48E6F2B0A3F7E33E6B7095E77C579CC6586


[jQuery] Re: [SITE SUBMISSION] Sapitot Creative

2008-01-30 Thread Benjamin Sterling
Looks really nice, but I would second Dan's comments and would probably
suggest you implement the history plugin.  Being in the DC area, 508
compliance is a big sell.

On 1/30/08, Dan G. Switzer, II <[EMAIL PROTECTED]> wrote:
>
>
> >Sapitot Creative is a Design firm that recently redesigned their
> >website. jQuery is being used to enhance page transitions and to give
> >a little flair to the print and web portfolio sections. What is real
> >interesting is the unconventional use of jQuery-ui.tabs plugin for the
> >main navigation.
> >
> >Check it out: www.sapitot.com
>
> Overall it looks good. A couple of comments:
>
> 1) I'd change the URL each time one of the tabs is clicked--that way users
> can cut-n-paste the URLs and e-mail them. If possible, it'd also use
> meaningful hashes (like #store, #web, #print, #about, etc.)
>
> 2) Occasionally I was able to get the "Loading..." message that appears
> when
> you've clicked on a category to never go away. It seems to happen if you
> click on another menu option before the last animation has finished. (I
> suspect you're using a global variable to reset the value and this is
> getting overwritten.)
>
> -Dan
>
>


-- 
Benjamin Sterling
http://www.KenzoMedia.com
http://www.KenzoHosting.com
http://www.benjaminsterling.com


[jQuery] Re: [SITE SUBMISSION] Sapitot Creative

2008-01-30 Thread Dan G. Switzer, II

>Sapitot Creative is a Design firm that recently redesigned their
>website. jQuery is being used to enhance page transitions and to give
>a little flair to the print and web portfolio sections. What is real
>interesting is the unconventional use of jQuery-ui.tabs plugin for the
>main navigation.
>
>Check it out: www.sapitot.com

Overall it looks good. A couple of comments:

1) I'd change the URL each time one of the tabs is clicked--that way users
can cut-n-paste the URLs and e-mail them. If possible, it'd also use
meaningful hashes (like #store, #web, #print, #about, etc.)

2) Occasionally I was able to get the "Loading..." message that appears when
you've clicked on a category to never go away. It seems to happen if you
click on another menu option before the last animation has finished. (I
suspect you're using a global variable to reset the value and this is
getting overwritten.)

-Dan



[jQuery] Re: Not Submit [validate]

2008-01-30 Thread Jörn Zaefferer


Marcos Aurélio schrieb:

Ok, see:

Join http://www.animeschool.com.br/example/.

First test:
Put in login "AAA" and name "bbb" click the button and submit it.

Second test:
First click the button. He acknowledge the mistakes, all ok. Now fill
in the fields with "AAA" and "bbb" and click the button. He did not
submit.
  
Thanks for the testpage and description, that helped a lot. The easiest 
way to solve this issue is to include the ajaxQueue plugin (see 
lib/jquery.ajaxQueue.js in the download package).


To prevent the issue to come up again I'll make the ajaxQueue plugin 
required for remote validation. Currently I've got no better idea then 
just display a completely annoying alert when the ajaxQueue plugin isn't 
included. Other ideas are welcome.


Regards
Jörn


[jQuery] Re: [SITE SUBMISSION] Sapitot Creative

2008-01-30 Thread Jonathan Sharp
Love it!

On 1/30/08, motob <[EMAIL PROTECTED]> wrote:
>
>
> Sapitot Creative is a Design firm that recently redesigned their
> website. jQuery is being used to enhance page transitions and to give
> a little flair to the print and web portfolio sections. What is real
> interesting is the unconventional use of jQuery-ui.tabs plugin for the
> main navigation.
>
> Check it out: www.sapitot.com
>


[jQuery] Re: Shadowbox Media Viewer

2008-01-30 Thread Michael J. I. Jackson


;) I thought you'd like that.

Michael

On Jan 29, 2008, at 12:17 PM, Aaron Heimlich wrote:

And you got my extensible file extension --> plugin mappings  
request in

there too! Woot!

On Jan 29, 2008 4:29 AM, Michael J. I. Jackson  
<[EMAIL PROTECTED]> wrote:



Hi all,
Just wanted to let you all know that the jQuery adapter has been  
updated
to include the kind of sweet jQuery functionality that Mike is  
talking about
in this email. Head on over and give it a shot if you haven't  
already.


http://mjijackson.com/2008/01/22/shadowbox-js-media-viewer-1-0-beta/

Thanks,

Michael

On Jan 25, 2008, at 4:20 PM, Mike Alsup wrote:

I'm putting the finishing touches on a media viewer application  
that I
coded up recently (think Thickbox). It can be used with jQuery or  
any

other library. I created an adapter for jQuery, and I thought that
somebody on this list might be interested.




Michael,

I really love what you've done with shadowbox.  But I dislike  
having to
add specific markup to drive the behavior.  And as a jQuery user I  
really

want to invoke it like this (for example):

$('a[href$=swf]').shadowbox();

So if you're open to suggestion, I'd love to see a minor  
modification.
Here's what I changed to make it more amendable to the jQuery  
calling style.


1.  Added this method to shadowbox.js (just below the current  
"setup" fn):


Shadowbox.setup2 = function(links){
for(var i = 0, len = links.length; i < len; ++i)
setupLink(links[i]);
};

2.  Added this to shadowbox-jquery.js:

jQuery.fn.shadowbox = function() {
Shadowbox.setup2(this);
};


Now I can call it like this without having to change any markup  
anywhere,

so it becomes a drop-in replacement:

$(function() {
var options = { /* whatever */ };
Shadowbox.init(options);

$('a[href$=swf]').shadowbox();
});


Of course there are more restrictions than one might expect from a
traditional jQuery plugin (like not being able to pass options on  
a per-call

basis), but it's a pretty minor change.  Food for thought.

Mike






--
Aaron Heimlich
Web Developer
[EMAIL PROTECTED]
http://aheimlich.freepgs.com




[jQuery] Re: Is this the best way?

2008-01-30 Thread Feijó


Hi Cabbite

Thanks for your 0.02

Its possible to simple use like this?
   $('.qualif[level>3]').remove();

if level bigger then 3, remove it :)

My code is dynamic, I cant just wrote all numbers I dont need to remove, 
like your example.  Has to use a condition.



Feijó



cabbiepete escreveu:

 Hi Felix,

 I would have thought doing an attribute selector like you suggest was
 better.

 something like

 ... $('.qualif[level]).each  ...

 to at least get rid of anything that doesn't have the level
 attribute. Also if you use the same tag name for all of these
 attributes its worth adding that as it also helps with efficiency,
 i.e. jquery only has to check those tags for level attribute.

 Depending on the exact use of the level attribute you might be able
 to get just the ones you want by using [attribute!=value] selectors.
 i.e. if you want greater than 4 and start at 0

 $('.qualif[level!=0], .qualif[level!=1], .qualif[level! =2],
 .qualif[level!=3], qualif[level!=4]').remove();

 Hope that helps. Also if any more expert on jquery knows more am keen
 to know better also.

 Cheers, Pete

 On Jan 30, 12:56 pm, Feijó <[EMAIL PROTECTED]> wrote:
> Hi, I was just wondering if there is any better way to accomplish
> that. Some divs has 'level' attribute, with a number.  If that
> number is bigger than X, will remove the div. var x=4; //
> simulating level=parseFloat($this.attr('level'));
> $('.qualif').each(function() { if ($(this).attr('level')>x)
> $(this).remove(); }); I don't know if we can set a filter in $('')
> to look at a custom attribute, should be simpler than Feijó


[jQuery] Re: Selector Containing Variable

2008-01-30 Thread Karl Swedberg




On Jan 30, 2008, at 10:24 AM, studiobl wrote:



I'm having trouble with a jQuery selector that contains a variable.
I'm trying to target an element that has a class of "orderInfo" and an
id of "billy"

So, I set a variable:

var tabText = "billy";

...and it works if I use the string:

$(".orderInfo[id='billy'"];

...but not the variable:

$(".orderInfo[id=tabTest"];


...but of course I need it to work with a variable {insert appropriate
emoticon here}


Hi there,

The trick here is to concatenate the variable with the selector  
string. Something like this should work:


$(".orderInfo[id=" + tabTest + "]");


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



[jQuery] Re: Validation plugin - spinner while validating field?

2008-01-30 Thread Jörn Zaefferer


Rus Miller schrieb:

There is a label.error and a label.checked but does anyone know how I
would display a label.pending (perhaps with a spinner) while the
validation (especially a remote request) is happening?

Thanks.
  
You can still use jQuery's ajax events to display a busy-indicator: 
http://docs.jquery.com/Ajax_Events


I acutally considered a pending state for remote-validated-fields, but 
dropped the idea in favor of a lack of those useless spinner icons. I 
found the goal to make the remote validation as unobtrusive as possible 
to the user a more worthwhile goal.


Jörn



[jQuery] Re: [validate] Validation Plugin - how to remove a control form validation

2008-01-30 Thread Jörn Zaefferer


Dave Stewart schrieb:

Hi there
I'm building a login form, with a "Forgot password" link. When
clicked, I need to unset some validation options to successfully
submit the form.

The code I'm running does this:

1 - remove the validation constraints from the password field
2 - hide any error messages that were displayed for the password
field
3 - submit the form using form.submit()

However, I can't seem to do either properly. Here's the code I'm
using:

$('#password').attr('validation', '')
$('label.error[for="password"]').hide()
$("#login").validate()


The problems are:

1 - form.submit() seems to bypass any of the validation
2 - if I click the submit button manually, the initial validation
kicks in and the password error is re-displayed

Can anyone shed any light on what I should be doing. I'm not sure if
there are already options for this, alrthough I've looked through the
docs several times over.
  

Could you post an example page of your setup?

For submitting the form it may help to not use jQuery, eg. 
$("#myform")[0].submit() instead of calling jQuery's submit method.


Jörn


[jQuery] Re: •.¸¸.•´´¯`••._.•> <((((º> How To Create Wealth????

2008-01-30 Thread Jonathan Sharp
User is banned.

-js


On 1/30/08, ++ Corn Square ++ <[EMAIL PROTECTED]> wrote:
>
>
> Most Forex traders loose money, don't be one of them
> Forex made easy is as simple as you would want it to be. ...
> Forex can be made easier for beginners to understand it and here's how:-
>
> http://tiniuri.com/c/u7
>


[jQuery] Re: Tab Effect

2008-01-30 Thread Kyle Browning
Hey no problem, and yea. I think they are moderated

On Jan 30, 2008 7:23 AM, studiobl <[EMAIL PROTECTED]> wrote:

>
> Thanks, ocyrus!
>
> That helped!  ...it does take dismayingly long for posts to show up
> here.
>
> On Jan 29, 1:49 pm, ocyrus <[EMAIL PROTECTED]> wrote:
> > I recently solved this solution this way,
> >
> > $(document).ready(function(){
> >   $('#profile-nav').children().each(function(){
> > $(this).click(function(){
> >   toggleTabs($(this));
> >   return false;
> > });
> >   });
> >
> > });
> >
> > function toggleTabs(tab) {
> >   tab.siblings().children().removeClass('on');
> >   tab.children().addClass('on');
> >   var div = tab.attr('class');
> >   div = div.split('-');
> >   div = div[1];
> >   $('#'+div).parent().children().each(function(){
> > $(this).hide();
> >   });
> >   $('#'+div).show();
> >
> > }
> >
> > and my html looks like this.
> >
> > 
> >  class="on">Biography
> > Background
> > Contact
> > 
> >
> > with three divs later
> >
> > Info
> > Info
> > Info
> >
> > On Jan 29, 9:46 am, studiobl <[EMAIL PROTECTED]> wrote:
> >
> > > I have a set of tabs that use the sliding doors technique.  The tabs
> > > are built on an unordered list, with each tab being a list item
> > > containing an anchor. Each tab is decorated by placing a graphic in
> > > the background of its list item for the left part of the tab, and the
> > > background of the anchor for the right side of the tab.  These
> > > graphics then need to be switched out to display the "active" view.
> > > The actual html page is not changed.  This tab navigation just
> > > triggers the visibility of various areas of the page.
> >
> > > I'm trying to use jQuery to switch out the graphics.  The problem I'm
> > > having is in selecting the list item that contains the clicked-on
> > > anchor.  There are a number of techniques for selecting children, but
> > > none for selecting parents.
> >
> > > One question I have is if there is any way to reference a previously
> > > selected element in a jQuery selector statement.  Like this:
> >
> > > $(".tabs a").click(function(){
> > >  //Now you can reference the clicked on anchor as "this"
> > > $(".tabs li:has(this)").doSomething();
> >
> > > });
> >
> > > I doubt that this is possible, I haven't tested it yet, but I can't
> > > think of too many other options.
> >
> > > Any suggestions?
>


[jQuery] Datepicker showon link click

2008-01-30 Thread rsmolkin

Hi,

Does anyone know how to make the Datepicker (calendar) be displayed by
clicking on a link next to a textfield.  I know it has a button option
and a focus option, but our old calendar used to be launched by a
link, so users are used  to that.  Does anyone know how to do that?

Thanks,
-Roman


[jQuery] Re: Manipulation of objects

2008-01-30 Thread RyanMC

Apparently the addOption() plugin doesn't like using $(this). I
thought I had tried that loop before, that was the reason. I am sure
there is a way to add and remove options without that plugin. Any
pointers on where to start there?

On Jan 29, 6:20 pm, "Josh Nathanson" <[EMAIL PROTECTED]> wrote:
> Basically you can do this:
>
> $('select').each(function() {
> $(this).doWhatever() // will run the method doWhatever on the currently
> iterating select
>
> });
>
> -- Josh
>
> - Original Message -
> From: "RyanMC" <[EMAIL PROTECTED]>
> To: "jQuery (English)" 
> Sent: Tuesday, January 29, 2008 3:38 PM
> Subject: [jQuery] Manipulation of  objects
>
> > I am working on a site where various dynamic content will be created
> > each session. There will end up being between 1 and a very large
> > number of select boxes on the page. Users are able to add items that
> > need to be inserted into each select box. I found a plugin that allows
> > me to addOption and adjust a select, but I can't seem to make it run
> > through all select boxes on the page. I am quite new to jquery and any
> > assistance would be very appreciated. Basically I need to know what
> > selector to use to run through all selects. And if anyone is familiar
> > with the addOption plugin and knows if it will work across multiple
> > selects that would be fantastic too. If it won't anyone that can point
> > me in the right direction to hand writing out the code for the select
> > manipulation would be great. I will end up removing items from the
> > select as well.


[jQuery] jQuery.Validation - Is there a way to display a spinner while validating field?

2008-01-30 Thread Rus Miller



On Jan 30, 5:40 am, Rus Miller <[EMAIL PROTECTED]> wrote:
> There is a label.error and a label.checked but does anyone know how I
> would display a label.pending (perhaps with a spinner) while the
> validation (especially a remote request) is happening?
>
> Thanks.


[jQuery] Re: simplemodal and datepicker

2008-01-30 Thread Eric Martin

On Jan 30, 6:13 am, rayfidelity <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I want to enable datepicker in the modal window that
> opens...datepicker works fine for itself but i cannot get it to work
> in modal. Any ideas?

Can you clarify what you mean by "cannot get it to work in modal"?

>
> Modal window is loaded through ajax...

Do you have a page or code that we/I can view?

-Eric


[jQuery] [SITE SUBMISSION] Sapitot Creative

2008-01-30 Thread motob

Sapitot Creative is a Design firm that recently redesigned their
website. jQuery is being used to enhance page transitions and to give
a little flair to the print and web portfolio sections. What is real
interesting is the unconventional use of jQuery-ui.tabs plugin for the
main navigation.

Check it out: www.sapitot.com


[jQuery] Re: Manipulation of objects

2008-01-30 Thread RyanMC

I will give that a try thanks.

On Jan 29, 6:20 pm, "Josh Nathanson" <[EMAIL PROTECTED]> wrote:
> Basically you can do this:
>
> $('select').each(function() {
> $(this).doWhatever() // will run the method doWhatever on the currently
> iterating select
>
> });
>
> -- Josh
>
> - Original Message -
> From: "RyanMC" <[EMAIL PROTECTED]>
> To: "jQuery (English)" 
> Sent: Tuesday, January 29, 2008 3:38 PM
> Subject: [jQuery] Manipulation of  objects
>
> > I am working on a site where various dynamic content will be created
> > each session. There will end up being between 1 and a very large
> > number of select boxes on the page. Users are able to add items that
> > need to be inserted into each select box. I found a plugin that allows
> > me to addOption and adjust a select, but I can't seem to make it run
> > through all select boxes on the page. I am quite new to jquery and any
> > assistance would be very appreciated. Basically I need to know what
> > selector to use to run through all selects. And if anyone is familiar
> > with the addOption plugin and knows if it will work across multiple
> > selects that would be fantastic too. If it won't anyone that can point
> > me in the right direction to hand writing out the code for the select
> > manipulation would be great. I will end up removing items from the
> > select as well.


[jQuery] JQuery UI and ExtJS

2008-01-30 Thread Stéphane Walther
Hi there,

I tried to nest an ExtJS TreePanel into an Accordion menu (provided by
jQueryUI) like this :
-Header1
-Header2
MyTree
-Header3

When I click on Header2, the TreePanel works fine (on FF only, IE doesn't
seems to work). If I click on another header and come back to Header2, the
the accordion doesn't seem to adapt his size to the tree : some of my child
nodes are hidden. Any idea to fix that?

Thanks for your help.


[jQuery] Re: changing content for span tag on the fly

2008-01-30 Thread Dave Stewart

$("#scrollStats").html('bold');
$("#scrollStats").text('text');


[jQuery] Selector Containing Variable

2008-01-30 Thread studiobl

I'm having trouble with a jQuery selector that contains a variable.
I'm trying to target an element that has a class of "orderInfo" and an
id of "billy"

So, I set a variable:

var tabText = "billy";

...and it works if I use the string:

$(".orderInfo[id='billy'"];

...but not the variable:

$(".orderInfo[id=tabTest"];


...but of course I need it to work with a variable {insert appropriate
emoticon here}


[jQuery] Re: Manipulation of objects

2008-01-30 Thread RyanMC

Nevermind. I got it to work. Thanks for the tips. They helped.

On Jan 29, 6:20 pm, "Josh Nathanson" <[EMAIL PROTECTED]> wrote:
> Basically you can do this:
>
> $('select').each(function() {
> $(this).doWhatever() // will run the method doWhatever on the currently
> iterating select
>
> });
>
> -- Josh
>
> - Original Message -
> From: "RyanMC" <[EMAIL PROTECTED]>
> To: "jQuery (English)" 
> Sent: Tuesday, January 29, 2008 3:38 PM
> Subject: [jQuery] Manipulation of  objects
>
> > I am working on a site where various dynamic content will be created
> > each session. There will end up being between 1 and a very large
> > number of select boxes on the page. Users are able to add items that
> > need to be inserted into each select box. I found a plugin that allows
> > me to addOption and adjust a select, but I can't seem to make it run
> > through all select boxes on the page. I am quite new to jquery and any
> > assistance would be very appreciated. Basically I need to know what
> > selector to use to run through all selects. And if anyone is familiar
> > with the addOption plugin and knows if it will work across multiple
> > selects that would be fantastic too. If it won't anyone that can point
> > me in the right direction to hand writing out the code for the select
> > manipulation would be great. I will end up removing items from the
> > select as well.


[jQuery] jQuery in the wild: www.engenderhealth.org

2008-01-30 Thread Dekortage

EngenderHealth, a nonprofit organization, just redesigned its web
site.  They use jQuery in several places: menus,  SIFR page titles,
subpage "related info" links (in places), and even on its donation
page.

http://www.engenderhealth.org

(Note: some Flash on the site, though I don't think it is required.)

Anyway, looks pretty cool.


[jQuery] •.¸¸.•´´¯`••._.•><((( (º> How To Create Wealth????

2008-01-30 Thread ++ Corn Square ++

Most Forex traders loose money, don't be one of them 
Forex made easy is as simple as you would want it to be. ... 
Forex can be made easier for beginners to understand it and here's how:-

http://tiniuri.com/c/u7


[jQuery] Re: Is this the best way?

2008-01-30 Thread cabbiepete

Hi Felix,

I would have thought doing an attribute selector like you suggest was
better.

something like

...
$('.qualif[level]).each 
...

to at least get rid of anything that doesn't have the level attribute.
Also if you use the same tag name for all of these attributes its
worth adding that as it also helps with efficiency, i.e. jquery only
has to check those tags for level attribute.

Depending on the exact use of the level attribute you might be able to
get just the ones you want by using [attribute!=value] selectors. i.e.
if you want greater than 4 and start at 0

$('.qualif[level!=0], .qualif[level!=1], .qualif[level!
=2], .qualif[level!=3], qualif[level!=4]').remove();

Hope that helps. Also if any more expert on jquery knows more am keen
to know better also.

Cheers,
Pete

On Jan 30, 12:56 pm, Feijó <[EMAIL PROTECTED]> wrote:
> Hi,
> I was just wondering if there is any better way to accomplish that.
> Some divs has 'level' attribute, with a number.  If that number is bigger 
> than X, will remove the div.
> var x=4; // simulating
> level=parseFloat($this.attr('level'));
> $('.qualif').each(function() {
> if ($(this).attr('level')>x)
> $(this).remove();
> });
> I don't know if we can set a filter in $('') to look at a custom attribute, 
> should be simpler than
> Feijó


[jQuery] UI.TABS - how to load content when tab is selected

2008-01-30 Thread carvingcode

I have a tab that I don't want the content (generated from a
separate .php file) to load untilt he user selects the tab.

How can I do this?

TIA


[jQuery] Re: [ANN] Lily, javascript visual programming tool

2008-01-30 Thread Bill Orcutt

Thanks Morgan- I'll make that change

On Jan 29, 10:58 pm, "Morgan Allen" <[EMAIL PROTECTED]> wrote:
> The minVersion in the install.rdf is 2.0.0 I changed to 2.0.0.* and it
> installed
>
> On Jan 29, 2008 9:33 PM, Bill Orcutt <[EMAIL PROTECTED]> wrote:
>
>
>
>
>
> > Thanks for the useful feedback on the site. I've added another
> > download link and will implement some of the other suggestions as I
> > find time. I hope once you've had a chance to have a look at the
> > program, you'll consider joining the user group-
> >http://groups.google.com/group/lily-users.
>
> > -Bill
>
> > On Jan 29, 4:19 pm, Jörn Zaefferer <[EMAIL PROTECTED]> wrote:
> > > Jörn Zaefferer schrieb:
>
> > > >BillOrcuttschrieb:
> > > >> [...]
> > > >> Have a look at the demo applications below to get a feel for some of
> > > >> what Lily can do:
> > > >> [...]
> > > >> More information about Lily is available on the website:
> > > >>http://www.lilyapp.org/
>
> > > > Wow. Thats amazing stuff, I love the svg/javascript sound demos. Using
> > > > interactive visuals to create music is so much fun.
>
> > > > Now I just need to take a closer look how Lily enbales stuff like
> > > > that, so most likey more feedback coming soon from here.
>
> > > Okay, some things:
> > > You need a Getting Started section and make that awfully obvious to find
> > > on the lilapp.org front page. Currently its difficult to find the
> > > download or even the wiki (which doesn't help in that respect).
> > > Along the link to the download should be the content of the readme file,
> > > avoid the need to download the package before being able to understand
> > > what and how to install.
> > > I found the download link only on the Public Beta 1 release post, which
> > > isn't even on the front page anymore.
> > > I also wonder if that couldn't be installed directly from the page - its
> > > just a firefox extension, isn't it? That way I wouldn't need to save
> > > anything on my disk and unpacking it. The included examples and demos
> > > could be provided via the page/wiki.
>
> > > Ah. After writing all that I discovered the top navigation bar,
> > > including the download link. You may want to make that a bit more
> > obvious...
>
> > > Jörn
>
> --http://morglog.alleycatracing.com
> Lets make up more accronyms!
>
> http://www.alleycatracing.com
> LTABOTIIOFR! ROFL! ROFL! ROFL!
> Upcoming alley cats, reviews, touring logs, and a general congregation of
> bike nerdity.


[jQuery] $.get and $.getJSON

2008-01-30 Thread mwk

Hi,

i encounter problems with the getJSON method

when i do that:

$.getJSON("http://localhost/jas/www/rmt.php5?action=airport_state";,
{country: $(this).val()}, function(json)
{
$.log(json);
});

nothing happends. there is even no connection trace in firebug
but

$.get("http://localhost/jas/www/rmt.php5?action=airport_state";,
{country: $(this).val()}, function(json)
{
eval("var a = "+json);
$.log(a);
});

works fine

php sends header("Content-type: application/json");
so thats fine to.
jquery version is 1.2.2

Any suggestions?

Martin




[jQuery] [validate] Validation Plugin - how to remove a control form validation

2008-01-30 Thread Dave Stewart

Hi there
I'm building a login form, with a "Forgot password" link. When
clicked, I need to unset some validation options to successfully
submit the form.

The code I'm running does this:

1 - remove the validation constraints from the password field
2 - hide any error messages that were displayed for the password
field
3 - submit the form using form.submit()

However, I can't seem to do either properly. Here's the code I'm
using:

$('#password').attr('validation', '')
$('label.error[for="password"]').hide()
$("#login").validate()


The problems are:

1 - form.submit() seems to bypass any of the validation
2 - if I click the submit button manually, the initial validation
kicks in and the password error is re-displayed

Can anyone shed any light on what I should be doing. I'm not sure if
there are already options for this, alrthough I've looked through the
docs several times over.

Thanks,
Dave


[jQuery] Re: Tab Effect

2008-01-30 Thread studiobl

Thanks, ocyrus!

That helped!  ...it does take dismayingly long for posts to show up
here.

On Jan 29, 1:49 pm, ocyrus <[EMAIL PROTECTED]> wrote:
> I recently solved this solution this way,
>
> $(document).ready(function(){
>   $('#profile-nav').children().each(function(){
> $(this).click(function(){
>   toggleTabs($(this));
>   return false;
> });
>   });
>
> });
>
> function toggleTabs(tab) {
>   tab.siblings().children().removeClass('on');
>   tab.children().addClass('on');
>   var div = tab.attr('class');
>   div = div.split('-');
>   div = div[1];
>   $('#'+div).parent().children().each(function(){
> $(this).hide();
>   });
>   $('#'+div).show();
>
> }
>
> and my html looks like this.
>
> 
> Biography
> Background
> Contact
> 
>
> with three divs later
>
> Info
> Info
> Info
>
> On Jan 29, 9:46 am, studiobl <[EMAIL PROTECTED]> wrote:
>
> > I have a set of tabs that use the sliding doors technique.  The tabs
> > are built on an unordered list, with each tab being a list item
> > containing an anchor. Each tab is decorated by placing a graphic in
> > the background of its list item for the left part of the tab, and the
> > background of the anchor for the right side of the tab.  These
> > graphics then need to be switched out to display the "active" view.
> > The actual html page is not changed.  This tab navigation just
> > triggers the visibility of various areas of the page.
>
> > I'm trying to use jQuery to switch out the graphics.  The problem I'm
> > having is in selecting the list item that contains the clicked-on
> > anchor.  There are a number of techniques for selecting children, but
> > none for selecting parents.
>
> > One question I have is if there is any way to reference a previously
> > selected element in a jQuery selector statement.  Like this:
>
> > $(".tabs a").click(function(){
> >  //Now you can reference the clicked on anchor as "this"
> > $(".tabs li:has(this)").doSomething();
>
> > });
>
> > I doubt that this is possible, I haven't tested it yet, but I can't
> > think of too many other options.
>
> > Any suggestions?


[jQuery] Re: How to insert google adsense with after()

2008-01-30 Thread felipe

hi,

did you find how to do it?

thank you

On 30 dez 2007, 20:10, Jirka <[EMAIL PROTECTED]> wrote:
> I try to add googleadsenseafter first paragraph of an article. Here
> is my code:
>
> $('.article p:eq(0)').after(' 
> ...GOGLEADSENSECODE... ');
>
> But it looks that tag script shouldnt be add into the DOM like this.
>
> Can anybody show me the right way?


[jQuery] inserting adsense

2008-01-30 Thread felipe

Hello,

I am trying to insert adsense code as follows:

var ads = $(this).text(); /// the adsense code goes here

$(tr).append( '' + ads + '' ) ;
$(tr).addClass('ads');
$('table#' + tablename + ' tr.header').after(tr);

Nothing happens. If I put some other  html code into scalar ads, it
works.

Any idea?

Thank you,

Felipe


[jQuery] Re: changing content for span tag on the fly

2008-01-30 Thread Karl Swedberg


Or, if you know that you'll be using just text (no html tags), you  
could do this:


$("#scrollStats").text("someting");


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



On Jan 30, 2008, at 11:11 AM, Bhaarat Sharma wrote:



*dope*

$("#scrollStats").html("someting");

that works.

...should visit the api's more often...

On Jan 30, 10:55 am, Bhaarat Sharma <[EMAIL PROTECTED]> wrote:

Hi

Can someone please tell me how i can change the text between span  
tags

on the fly using jQuery

I have tag like this

span>


i have tried these but none seem to work

$("#scrollStats").val("im here!!");

$("#scrollStats").setText("works?");

Thanks!




[jQuery] Re: [Announce] New Menu plugin

2008-01-30 Thread Roman Weich


Jörn Zaefferer schrieb:


You could improve the demo by adding cursor:default for the menu. The 
text-selection cursor is rather irritating inside the menu.

Yep, that demo page still needs a lot of work.

It would be nice to be able to open the menu on hover, maybe powered by 
the hoverintent menu. That way I'd click only to select an item, that 
alreay works for submenus.

There is an option for this, but it's disabled by default.

Examples three, four and five seem to be just the same as two on first 
glance, I'm still not sure I'd need any of those. Making it more clear 
why those are important would help, otherwise you could consider 
reducing the API to the really important essentials. Maybe taking 
graceful degradation into account, and at least mentioning what to use 
if that is important.
Yes, they are resulting to the same. It's just that i had requests to 
implement different ways to create a menu. I'll try to remove some of 
the stuff from the core, giving the possibility to extend the plugin 
with the desired behaviour. Right now, I just don't know how to do this 
exactly.


Clicking the seperator in example three alerts 'you clicked ""', seems 
like a bug.

Doh! :)

The first example should work without options at all, showing that the 
defaults work just fine out of the box.
All examples show the alert on click, but only the first contains the 
code for that.

Actually all of them are using the same options. I shouldn't be so lazy..

You may want to use http://plugins.jquery.com/ for your plugin page, at 
least in addition to your own.

As soon, as I've got a stable release. :)

Thanks for your Feedback Jörn!

Roman


[jQuery] Re: Not a plugin but code for anyone trying to have collapse-able menu with cookies

2008-01-30 Thread Karl Swedberg


On Jan 30, 2008, at 10:57 AM, Bhaarat Sharma wrote:

Hi ty,

If I understand your question correctly..I think you mean that if this
menu was used throughout the site and your pages would be doing an
include on this js file, will the menu stay the same from page to page
with user selections. The answer is yes (i think), because it is using
cookies.



That's right. The cookies work at the domain level, unless otherwise  
specified.


On my test page (http://test.learningjquery.com/cookie-menu.html), I  
put a link to another page with the same script and menu so you can  
see the persistence of the expand/collapse state.



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




[jQuery] Re: changing content for span tag on the fly

2008-01-30 Thread Bhaarat Sharma

oh haha thanks. we replied at the same time :)

On Jan 30, 11:11 am, Bhaarat Sharma <[EMAIL PROTECTED]> wrote:
> *dope*
>
> $("#scrollStats").html("someting");
>
> that works.
>
> ...should visit the api's more often...
>
> On Jan 30, 10:55 am, Bhaarat Sharma <[EMAIL PROTECTED]> wrote:
>
> > Hi
>
> > Can someone please tell me how i can change the text between span tags
> > on the fly using jQuery
>
> > I have tag like this
>
> > 
>
> > i have tried these but none seem to work
>
> > $("#scrollStats").val("im here!!");
>
> > $("#scrollStats").setText("works?");
>
> > Thanks!


[jQuery] Re: changing content for span tag on the fly

2008-01-30 Thread Bhaarat Sharma

*dope*

$("#scrollStats").html("someting");

that works.

...should visit the api's more often...

On Jan 30, 10:55 am, Bhaarat Sharma <[EMAIL PROTECTED]> wrote:
> Hi
>
> Can someone please tell me how i can change the text between span tags
> on the fly using jQuery
>
> I have tag like this
>
> 
>
> i have tried these but none seem to work
>
> $("#scrollStats").val("im here!!");
>
> $("#scrollStats").setText("works?");
>
> Thanks!


[jQuery] Re: changing content for span tag on the fly

2008-01-30 Thread Liam Byrne


Try

$("#scrollStats").html("im here!!");

Bhaarat Sharma wrote:

Hi

Can someone please tell me how i can change the text between span tags
on the fly using jQuery

I have tag like this



i have tried these but none seem to work

$("#scrollStats").val("im here!!");

$("#scrollStats").setText("works?");

Thanks!


  




[jQuery] Re: Not a plugin but code for anyone trying to have collapse-able menu with cookies

2008-01-30 Thread Bhaarat Sharma

Hi ty,

If I understand your question correctly..I think you mean that if this
menu was used throughout the site and your pages would be doing an
include on this js file, will the menu stay the same from page to page
with user selections. The answer is yes (i think), because it is using
cookies.

Thanks
-bhaarat

On Jan 30, 9:23 am, "Ty (tzmedia)" <[EMAIL PROTECTED]> wrote:
> IF the menu were used as an include and it was the sitewide navigation
> would the menu be "persistent" then?
> In other words, the menu will leave open the accordion button for the
> section the user is visiting?
> It seems like the solution that this is?
> thanks.
>
> On Jan 29, 4:53 pm, Karl Swedberg <[EMAIL PROTECTED]> wrote:
>
> > No problem, Bhaarat! Glad you like it.
>
> > Actually, the way I set it up, mine was limited to 10 or fewer links.
> > But we can increase that number by calling a function that returns,
> > for example, a base-32 string instead of index:
>
> > function bigIndex(inival) {
> >    return (inival).toString(32);
>
> > }
>
> > The updated demo can be found, still, 
> > athttp://test.learningjquery.com/cookie-menu.html
>
> > Good luck with your test page!
>
> > --Karl
> > _
> > Karl Swedbergwww.englishrules.comwww.learningjquery.com
>
> > On Jan 29, 2008, at 4:08 PM, Bhaarat Sharma wrote:
>
> > > Hi Karl,
>
> > > Thanks a lot! your solution is obviously much better and not dependent
> > > on how many links there are. since you are using 'each' function.
>
> > > I had the concept with me but not the power of ins and outs of
> > > jQuery :)
>
> > > Next i'll be trying to 
> > > makehttp://www.coldfusionjedi.com/demos/sharp/ajaxLoadOnScroll/test.cfm
> > > in jQuery+jsp (not PHP for a change)
>
> > > will keep you posted!
>
> > > Thanks
> > > -bhaarat
>
> > > On Jan 29, 3:56 pm, Karl Swedberg <[EMAIL PROTECTED]> wrote:
> > >> Hi Bhaarat,
>
> > >> You've done a nice job here! I was wondering, though, if we could
> > >> take
> > >> advantage of the index value of the links, so I re-factored your code
> > >> a bit (still using Klaus's cookie plugin). Here is what it looks
> > >> like:
>
> > >> $(document).ready(function() {
> > >>    $('#menu li ul').hide();
> > >>    var cookieValue = $.cookie('menuCookie') || '';
> > >>    $('#menu > li > a').each(function(index) {
> > >>      var $this = $(this), $checkElement = $this.next('ul');
> > >>      if (cookieValue.indexOf(index) > -1) {
> > >>        $checkElement.show();
> > >>      }
> > >>      $this.click(function() {
> > >>        if ($checkElement.is(':hidden')) {
> > >>          $checkElement.slideDown();
> > >>          cookieValue = cookieValue + index;
> > >>          $.cookie('menuCookie', cookieValue);
> > >>        } else {
> > >>          $checkElement.slideUp();
> > >>          cookieValue = cookieValue.replace(index,'');
> > >>          $.cookie('menuCookie', cookieValue);
> > >>        }
> > >>        return false;
> > >>      });
> > >>    });
>
> > >> });
>
> > >> I put up a little demo page here:
>
> > >>http://test.learningjquery.com/cookie-menu.html
>
> > >> On the demo page, I also added a little function to show the value of
> > >> the cookie and called the function onready and onclick:
>
> > >> function showCookie() {
> > >>    if (!$('#jar').length) {
> > >>      $('').appendTo('body');
> > >>    }
> > >>    $('#jar').text(document.cookie);
>
> > >> }
>
> > >> Cheers,
>
> > >> --Karl
> > >> _
> > >> Karl Swedbergwww.englishrules.comwww.learningjquery.com
>
> > >> On Jan 29, 2008, at 1:41 PM, Bhaarat Sharma wrote:
>
> > >>> Hi,
>
> > >>> I took the code from jQuery Accordion menu and am using the cookie
> > >>> plugin.
>
> > >>> while searching for a collapse-able menu I saw that a lot of people
> > >>> were looking for this but with cookies so when user refreshes..the
> > >>> collapse/expand state stay the same.
>
> > >>> I am new to jQuery and even javascript.
>
> > >>> But here I have jotted down something which is working for me.
>
> > >>> Experts out there: if you would like to add some suggestions on
> > >>> how to
> > >>> better do this..i'd appreciate it.
> > >>> I dont like the fact that i am different cookies for different menu
> > >>> items...
>
> > >>>    function initMenu() {
> > >>>  $('#menu ul').hide();
>
> > >>> if ($.cookie('the_cookie1')=='a'||$.cookie('the_cookie2')=='b'||
> > >>> $.cookie('the_cookie3')=='c'||
> > >>>        $.cookie('the_cookie4')=='d')
> > >>>  {
>
> > >>>      if ($.cookie('the_cookie1')=='a')
> > >>>        $("a").filter(".a").next().slideDown('fast');
> > >>>      if ($.cookie('the_cookie2')=='b')
> > >>>        $("a").filter(".b").next().slideDown('fast');
> > >>>      if ($.cookie('the_cookie3')=='c')
> > >>>        $("a").filter(".c").next().slideDown('fast');
> > >>>      if ($.cookie('the_cookie4')=='d')
> > >>>        $("a").filter(".d").next().slideDown('fast');
>
> > >>>  }
>
> > >>> $('#menu li a').click(
> > >>> function() {
> > >>> var checkElement = $(this).n

[jQuery] changing content for span tag on the fly

2008-01-30 Thread Bhaarat Sharma

Hi

Can someone please tell me how i can change the text between span tags
on the fly using jQuery

I have tag like this



i have tried these but none seem to work

$("#scrollStats").val("im here!!");

$("#scrollStats").setText("works?");

Thanks!


  1   2   >