jQuery datepicker, tabs, AJAX fixed
The problem I wrote about yesterday is finally fixed. The solution is pretty strange, but somehow works. I ended up having datepicker initialized through class name (not ID) as follows:
setTimeout(function() { $('.datepicker_element_class').removeAttr('id').removeClass('hasDatepicker').datepicker(); },300 );
jQuery datepicker, tabs, AJAX
The whole bloody day fighting with jQuery datepicker. Still no luck, so maybe you have something to tell. The setup is as follows:
– jQuery tabs with content being loaded via AJAX calls
– Inside tabs content there are forms with jQuery datepicker
The problem is that datepicker doesn’t work correctly. There are two possible results (except for those where everything is broken completely):
– Datepicker is displayed and popup is shown, but when selecting a date – it is not inserted in the input field (though it is send correctly when form is submitted)
– Datepicker is displayed and everything works (even when selecting a date it is correctly inserted into field), but after switching between tabs for 2-3 times, datepicker is disappearing from some fields and stays enabled on others.
I tried everything I could find. Working with jQuery live, jQuery livequery, setTimeouts (for proper delay on DOM updates). Tried accessing through classes and through IDs, tried generating random IDs just in case there is a collision or something else. Nothing works :(
Pissed off, experimenting further, but looks like I am running out of possibilities…
10/10/10 10:10
here we go: 10/10/10 10:10
Snooker
It’s been ages since I last played snooker. For the past week I had my friends from Russia as guests here in Cyprus and we had couple of games during their stay. What should I say – I love the game and I want to play it more often. Unfortunately I don’t know many people who play snooker (most prefer american pool instead). If you are playing snooker and you are in Limassol – we can meet sometime in Century Billiard club for game :)