[jQuery] Problem combining validation plugin and datepicker from ui (validate)

2009-11-19 Thread bobbykjack
OK, my requirement is wildly advanced, but I need to combine the ui
datepicker with the validation plugin. Ultimately, I need to ensure a
date is at least 1 month in the future.

The problem I'm encountering is the exact ordering of events. It
appears as if the validator check's the input's data before the
datepicker has written to it (after a date has been picked).

There's a demo here:
http://www.fiveminuteargument.com/jquery-validation-date-picker.html

and you should notice the problem (the date 'seen' lagging behind by
one) once you've picked the second date, and onwards.

Any advice much appreciated,

- Bobby


[jQuery] Problem with box positioning in IE7 when using jquerycyclelite

2009-10-07 Thread bobbykjack

I don't have time to put a real test-case together right now, but just
on the off chance that someone's experienced the same class of
problem:

I'm using jquerycyclelite (http://malsup.com/jquery/cycle/lite/) to
animate a set of linked images. An ancestor element has padding, but
the images seem to ignore that padding when cycled. The relevant code
is:

$slides.css({position: 'absolute', top:0, left:0}).hide().each(function
(i) {
$(this).css('z-index', els.length - i)
});


$(els[first]).css('opacity',1).show(); // opacity bit needed to handle
reinit case

although I can't reproduce the exact problem just by applying those
CSS properties, so I'm guessing it's a side-effect of jquery's hide
() / show(). Sound familiar to anyone?

Thanks,

- Bobby


[jQuery] Re: jQuery with HTML radio button forms

2009-07-09 Thread bobbykjack

I've identified the exact same problem today. Although this could, in
theory, be moved to a click event, this will reduce accessibility
support - e.g. keyboard users will no longer see the same behaviour.

- Bobby

On Jul 3, 12:42 am, James james.gp@gmail.com wrote:
 What if you change the whole thing to:

 $(#almond_cake).click(function() {
     if ($(this).is(':checked'))
         // do something
     else
         // do something else

 });

 On Jul 2, 10:00 am, Shiro nimro...@gmail.com wrote:

  Hi James,
  I changed the code from:

  $(#almond_cake:checked).val() == 'on')

  to:

  if ($(#almond_cake).is(':checked'))

  to check to see if the radio button is checked. This works in firefox
  but in IE it takes a second click for it to work for some reason.

  Thanks!

  On Jul 2, 12:49 pm, James james.gp@gmail.com wrote:

   Here:
   $(#almond_cake:checked).val() == 'on')

   You're checking for the value 'on', but you're setting value=x?

   If you're using that condition, your HTML should look like this:
   input type=radio id=almond_cake name=cakes value=on /

   See if that works.

   (And you don't need a closing /input tag. It's not valid HTML.)

   On Jul 2, 7:45 am, Shiro nimro...@gmail.com wrote:

Hi,
I changed it to the following:

$(#flavors input[name=cakes]).change(function(){

                if ($(#almond_cake).is(':checked')) {

                        $(#wrapper_almond).show();
                        $(#pic_almond).show();
                } else {
                        $(#wrapper_almond).hide();
                        $(#pic_almond).hide();
                };

There are more types of 'cakes' listed besides that the one there and
this works perfectly fine in Mozilla firefox. However, the ever nasty
Internet explorer gave me some problems. Clicking on almond cake radio
button is supposed to show the wrapper_almond div, chocolate cake
radio button shows wrapper_chocolate div, etc. But in IE, whenever I
click on almond cake, nothing happens, and I click on chocolate cake,
it shows almond cake instead! There seems to be a delay in clicks
somehow. I either have to double click the radio button, or right
click after selecting the radio button. Is there a way around this?
Any help greatly appreciated!

Sincerely,
Westley

On Jul 2, 6:00 am, Bharat bcrupa...@yahoo.com wrote:

 Can you try the change event instead of click?
 Bharat