You are viewing limited content. For full access, please sign in.

Question

Question

How can I hide the calendar on a date field?

asked on May 25, 2016 Show version history

Hi there!

    I have LF Forms 9.2 and need to use Javascript to hide calendar on a date field and make it as Read-only.  I have tried doing this coding.

$('.ADate input').attr('readonly', 'readonly');

The field have changed to Read-only, but the calendar 's still there, behind the date field

Does anyone know how to do this?

Appreciate any help.

 

0 0

Answer

SELECTED ANSWER
replied on May 25, 2016

You can just add "$('.ADate img').hide();" after your code for making the input as read-only.

1 0
replied on May 25, 2016

How do you find out about the class name to use. I used chrome with developer tools and still couldn't find it. When i use pointer to select element to inspect it. this is what i get. 

0 0
replied on May 25, 2016

Yes,that 's interesting. I have tried some code like :

$('.ui-datepicker-calendar').hide();

But It didn't work.

I wonder the same thing that how you can find out about this class name.

0 0

Replies

replied on May 25, 2016

Hi Xiuhong,

It works like a charm, thanks a bunch!

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.