facebook

how to display check mark programatically? CLOSED

  1. MobiOne Archive
  2.  > 
  3. Getting Help – General
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #337305 Reply

    PaulLeBlanc
    Participant

    Hello all,
    Can anyone help me with the correct syntax for displaying
    the check mark in a check box programatically?

    I have tried the following, but it does not work.

    $(‘#m1-settings-checkbox2’).prop(‘checked’,true);

    Paul

    #337306 Reply

    Brandon
    Member

    Try this:

    $('#m1-settings-checkbox2').attr('checked',true)
    #337307 Reply

    PaulLeBlanc
    Participant

    Thanks,you got me going in the right direction. I had to change it to the following and it works perfect!

    $(‘#m1-settings-checkbox2 > input’).attr(‘checked’,true);

    #337309 Reply

    Brandon
    Member

    Sorry, that was my fault when I copied your info I accidently deleted the input from my sample:

    $('#index-checkbox1 > input').attr('checked',true)
Viewing 4 posts - 1 through 4 (of 4 total)
Reply To: how to display check mark programatically? CLOSED

You must be logged in to post in the forum log in