//this will reset the nessecary data when they change the trip information
    var reset_data = function(level)
    {
        $('#buster_info tr:eq(' + level + ') td:eq(0)').empty();
        $('#buster_info tr:eq(' + level + ')
td:eq(0)').addClass('ajax_loading');
        $('#price_buster_totals tr:eq(0) td:eq(0)').empty();
        $('#price_buster_totals tr:eq(1) td:eq(0)').empty();
        $('#price_buster_totals tr:eq(2) td:eq(0)').empty();
        $('#price_buster_totals tr:eq(3) td:eq(0)').empty();
        
        our_price_var.attr('value', '0');
        price_buster_amount_var.attr('value', '0');
        
        $('#buster_info tr:gt(' + level + ')').hide();
        $('#buster_info tr:gt(' + level + ') td').empty();
        
        $('[EMAIL PROTECTED]').css('display', 'none');
        $('[EMAIL PROTECTED]').attr('value', '');
    };
    
    reset_data(0);
    
    destination.load('/lib/ajax/price_buster.php', {'get': 'destination'},
function()
    {
        $(this).removeClass('ajax_loading'); 
    });
    
    $('[EMAIL PROTECTED]').livequery('change', function()
    {
        $('#buster_info tr:eq(1)').show();
        reset_data(1);
        var destination_var = $('[EMAIL PROTECTED]');
        
        $('#week').load('/lib/ajax/price_buster.php', {'get': 'week', 
                                                       'destination':
destination_var.val()},
                                                       function()
    {
        $(this).removeClass('ajax_loading'); 
    });
    });
    
    $('[EMAIL PROTECTED]').livequery('change', function()
    {
        $('#buster_info tr:eq(3)').show();
        reset_data(3);
        var destination_var = $('[EMAIL PROTECTED]');
        var nights_var = $('[EMAIL PROTECTED]');
        var week_var = $('[EMAIL PROTECTED]');
        
        $('#options').load('/lib/ajax/price_buster.php', {'get': 'options', 
                                                 'destination':
destination_var.val(),
                                                 'nights': nights_var.val(),
                                                 'week': week_var.val()},
function()
    {
        $(this).removeClass('ajax_loading'); 
    });
    });
    
    $('[EMAIL PROTECTED]').livequery('change', function()
    {
        $('#buster_info tr:eq(2)').show();
        reset_data(2);
        var destination_var = $('[EMAIL PROTECTED]');
        var week_var = $('[EMAIL PROTECTED]');
        
        $('#nights').load('/lib/ajax/price_buster.php', {'get': 'nights', 
                                                    'destination':
destination_var.val(), 
                                                    'week': week_var.val()},
function()
    {
        $(this).removeClass('ajax_loading'); 
    });
    });

It when i try to select an option from #weeks that safari crashes.


Brandon Aaron wrote:
> 
> Well Safari has a nice list of issues but Safari 3 beta made that list
> quite
> a bit longer. Live Query has been pretty thoroughly tested in Safari,
> WebKit
> Nightlies and Safari 3. There shouldn't be any issues but ya never know
> with
> these crazy browsers. Could you possibly post the code?
> 
> --
> Brandon Aaron
> 
> On 8/22/07, Eridius <[EMAIL PROTECTED]> wrote:
>>
>>
>>
>> yes it is using ajax to load the select box.  is the issue with safari 3
>> beta
>> or safari in general?  is the issue with ajax related stuff buff all the
>> other jquery stuff is working fine.
>>
>>
>> Brandon Aaron wrote:
>> >
>> > Safari 3 beta has been causing all sorts of problems. We just have to
>> > remember that it is a beta (more of alpha quality from what I've seen
>> so
>> > far).
>> >
>> > I have a question about your two select boxes. Are they loaded via
>> AJAX?
>> > Also instead of reselecting the destination or nights select, just use
>> the
>> > 'this' keyword.
>> >
>> > In the first Live Query, this references the [EMAIL PROTECTED]
>> and
>> > in the second Live Query, this references the [EMAIL PROTECTED] So
>> the
>> > destination_var in the first would look like this:
>> >
>> > var destination_var = $(this);
>> >
>> > And the nights_var in the second would look like this:
>> >
>> > var nights_var = $(this);
>> >
>> >
>> > Also, try to be more specific with your Live Queries. Give it a context
>> or
>> > just a parent element if you can ... like this:
>> >
>> > $('#container [EMAIL PROTECTED]')
>> >
>> >
>> > --
>> > Brandon Aaron
>> >
>> > On 8/22/07, Eridius <[EMAIL PROTECTED]> wrote:
>> >>
>> >>
>> >>
>> >> here is a small portion on my code
>> >>
>> >> $('[EMAIL PROTECTED]').livequery('change', function()
>> >>     {
>> >>         reset_data(0);
>> >>         var destination_var = $('[EMAIL PROTECTED]');
>> >>
>> >>         $('#week').load('/lib/ajax/price_buster.php', {'get': 'week',
>> >>                                                    'destination':
>> >> destination_var.val()});
>> >>         $('#buster_info tr:eq(1)').show();
>> >>     });
>> >>
>> >>     $('[EMAIL PROTECTED]').livequery('change', function()
>> >>     {
>> >>         reset_data(2);
>> >>         var destination_var = $('[EMAIL PROTECTED]');
>> >>         var nights_var = $('[EMAIL PROTECTED]');
>> >>         var week_var = $('[EMAIL PROTECTED]');
>> >>
>> >>         $('#options').load('/lib/ajax/price_buster.php', {'get':
>> >> 'options',
>> >>                                                  'destination':
>> >> destination_var.val(),
>> >>                                                  'nights':
>> >> nights_var.val(),
>> >>                                                  'week':
>> >> week_var.val()});
>> >>         $('#buster_info tr:eq(3)').show();
>> >>     });
>> >>
>> >> I basically have this for about 6-7 select boxs.  Now the jquery works
>> >> fine
>> >> in IE &FF but when i do this is Safari 3 beta, safari crash.  Does
>> >> anything
>> >> look wring with the code that would cause it to crash?  could this
>> just
>> >> be
>> >> safari beta issue?
>> >> --
>> >> View this message in context:
>> >> http://www.nabble.com/livequery-issue-tf4311803s15494.html#a12275312
>> >> Sent from the JQuery mailing list archive at Nabble.com.
>> >>
>> >>
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/livequery-issue-tf4311803s15494.html#a12281829
>> Sent from the JQuery mailing list archive at Nabble.com.
>>
>>
> 
> 

-- 
View this message in context: 
http://www.nabble.com/livequery-issue-tf4311803s15494.html#a12282113
Sent from the JQuery mailing list archive at Nabble.com.

Reply via email to