Multiple-Dates-Picker-for-jQuery-UI icon indicating copy to clipboard operation
Multiple-Dates-Picker-for-jQuery-UI copied to clipboard

Bind multiDatesPicker to dynamically added elements

Open saurindashadia opened this issue 2 years ago • 0 comments

I tried different ways to initiate the multiDatesPicker to the dynamically added (cloned) with no success. I tried to search on internet for some solutions but none worked.

The selector is the class name '.multidates' for existing and new added elements.

I tried calling the multiDatesPicker() function again after the element is added to dom.

$('.multidates').multiDatesPicker();

Also tried other solution found

$('body').on('focus', '.multidate', function(){
	$(this).removeClass('hasDatepicker').multiDatesPicker({
		dateFormat: "dd/mm/yy",
	});
});

None worked. Please help.

saurindashadia avatar Apr 24 '23 11:04 saurindashadia