Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

Navigating the DOM

  • 17-03-2006 9:02pm
    #1
    Closed Accounts Posts: 201 ✭✭


    I am trying to navigate the DOM in Mozilla Thunderbird with a DOM inspector extension and I have identified an element and the node I want to change now its id is priorityCol but when I try to access it like this

    document.getElementById("priorityCol").firstNode.nodeValue="false";

    says that document.getElementById("priorityCol") has no properties???

    Anyone any ideas where may be going wrong the id is definitely right!


Comments

  • Registered Users, Registered Users 2 Posts: 1,275 ✭✭✭bpmurray


    Actually, you need to be careful with getElementById. Try this instead ...
    if (window.document.getElementById != null)
       myDomObj = window.document.getElementById("priorityCol");
    else if (window.document.all != null) 
       myDomObj = window.document.all("priorityCol");
    


  • Closed Accounts Posts: 201 ✭✭bazcaz


    No neither of them worked does it matter what level of the DOM I am at like theres a nice hierarchy from document down to this element in DOM Inspector


  • Closed Accounts Posts: 201 ✭✭bazcaz


    Ive sorted it was

    window.document.getElementById("priorityCol").getAttributeNode("hidden").value=false;


Advertisement