79092601

Date: 2024-10-16 05:41:54
Score: 2
Natty:
Report link

Modify the opentab function to accept the event parameter:

function opentab(event, tabname) {
    for (let tablink of tablinks) {
        tablink.classList.remove("active-link");
    }
    for (let tabcontent of tabcontents) {
        tabcontent.classList.remove("active-tab");
    }
    event.currentTarget.classList.add("active-link");
    document.getElementById(tabname).classList.add("active-tab");
}

This seems to make it workable. Please let me know.

Reasons:
  • RegEx Blacklisted phrase (2.5): Please let me know
  • Has code block (-0.5):
Posted by: Mahesh Thorat