This topic contains 1 reply, has 2 voices, and was last updated by Sean Sean 1 year, 7 months ago.

Javascript unable to visually check and uncheck checkbox fields


  • erics121
    Participant

    Member Reply #7419

    I noticed that the following javascript code that I use all the time, does not work inside the CONQUER theme.  I want the user to click a button, and then the checkboxes on the form change on the click.  The code below is pretty standard and always works but not inside a Conquer form. I pulled this code out and into a standard web page on another site and it worked just fine. But still fails to work in Conquer.  Look at the code below.  When I click my button that fires off some javascript, all the rest of the code works fine. But when the code gets to the 3 javascript lines below, it doesn’t work.  When I debug the CHECKED value, the value is actually changed correctly, which is good. But the checkmark in the box does not updates as I would expect it to.  Can you help?

    CHECKBOXES

    <input type=”radio” name=”field1″  id=”somecheckbox1″ value=”1″>
    <input type=”radio” name=”field2″  id=”somecheckbox2″ value=”1″ checked>
    <input type=”radio” name=”field3″  id=”somecheckbox3″ value=”1″ checked>

    JAVASCRIPT NOT WORKING

    document.getElementById(“somecheckbox1”).checked = true;
    document.getElementById(“somecheckbox2”).checked = false;
    document.getElementById(“somecheckbox3”).checked = false;

    Sean
    Sean
    Keymaster

    Posts: 4380
    Support Staff Reply #7751

    Hi,

    Sorry for the late reply. Due to some issues seems we missed your reply here. If you need any further help please create a new topic or write to our support at support@keenthemes.com.

    ==================

    Just a friendly reminder: If you purchased Metronic 6 months ago then your included support subscription might be expired and to get any further support you will need to renew your support subscription. For further check please go to Metronic purchase page http://themeforest.net/item/metronic-responsive-admin-dashboard-template/4021469?ref=keenthemes.

    For more info please check:
    https://help.market.envato.com/hc/en-us/articles/208191263-What-is-Item-Support- or http://themeforest.net/page/item_support_policy

    Thanks.

You must be logged in to reply to this topic.