Basically I got 2 calendar scripts from the same source. I saw a custom script before that merged these two but Everything I tried failed. Please help.
Here are the 2 scripts.
Script 1:

$('#date3').DatePicker({
    flat: true,
    date: ['2008-07-28','2008-07-31'],
    current: '2008-07-31',
    calendars: 3,
    mode: 'range',
    starts: 1
});

Script 2:

$('#inputDate').DatePicker({
    format:'m/d/Y',
    date: $('#inputDate').val(),
    current: $('#inputDate').val(),
    starts: 1,
    position: 'r',
    onBeforeShow: function(){
        $('#inputDate').DatePickerSetDate($('#inputDate').val(), true);
    },
    onChange: function(formated, dates){
        $('#inputDate').val(formated);
        if ($('#closeOnSelect input').attr('checked')) {
            $('#inputDate').DatePickerHide();
        }
    }
});

Please help, I have a deadline and my head is already hurting.

Member Avatar for LastMitch

Please help, I have a deadline and my head is already hurting.

I just came back from my short trip and my eyes are hurting now because I don't see any PHP code in your code which I'm not sure why post this in the PHP section in the first place?

You are merging 2 datepickers?

I notice that you didn't have a .each() function in your jQuery.

You can used .each() function to solve the issue you are having:

http://api.jquery.com/each/

In the future please double check where you post your code or noone will answer your thread.

I'm sorry.
I'll mark this solved since I found out what to do and what was missing.
Thanks though.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.