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

larger text & low vision CSS

Options
  • 14-06-2010 1:05pm
    #1
    Posts: 0 ✭✭✭


    Hi,

    Hopefully a quick one for the tech gurus, I've got my large text and low vision working for my site, but when you navigate away from the page that has been switched to low vision or Large text, it reverts back to the default stylesheet.
    So can you tell me how I get it to stay in Low vision or Large text while a user navigates around the site?

    Many thanks.


Comments

  • Registered Users Posts: 21,257 ✭✭✭✭Eoin


    I think you would need to save the choice of stylesheet to the user session or as a cookie, so it can be picked up on each page. Then on each page you'll need to check for that session variable or cookie and display the low vision css file if required.


  • Posts: 0 ✭✭✭ [Deleted User]


    I can honestly say I don't know how to do that, however, here is the code I'm using. The HTML page:

    /////////////////////////
    function setActiveStyleSheet(title) {
    var i, a, main;
    for(i=0; (a = document.getElementsByTagName("link")); i++)
    {
    if(a.getAttribute("rel").indexOf("style") != -1 && a.getAttribute("title"))
    {
    a.disabled = true;
    if(a.getAttribute("title") == title)
    a.disabled = false;
    }
    }
    }


    ///////////////////////


  • Closed Accounts Posts: 9,700 ✭✭✭tricky D


    Google style switcher for loads of options


Advertisement