I want to add css to a current page in the main menu div by javascript.
Since I am using a old CMS, I am not do it by adding a code to html.
How can I do it?
What I am thinking is that if I use the title in head section the same as the menu, there must be way to do it?
Is it?
Code will be like this and I want to add class="current" in the current page.
<head>
<title>about us</title>
</head>
<body>
<div id="menu">
<ul>
<li>home</li>
<li>about us</li>
......
</ul>
</div>
Thanks in advance.
Since I am using a old CMS, I am not do it by adding a code to html.
How can I do it?
What I am thinking is that if I use the title in head section the same as the menu, there must be way to do it?
Is it?
Code will be like this and I want to add class="current" in the current page.
<head>
<title>about us</title>
</head>
<body>
<div id="menu">
<ul>
<li>home</li>
<li>about us</li>
......
</ul>
</div>
Thanks in advance.