I have a navicon made of css content property.
The code looks like this
#nav:before {
content: '=';
}
function navigation() {
$('#navigation').click(function() {
$('#toggle').slideToggle(600);
$('#toggle').css({
'content': 'x'
});
});
}
window.onload = navigation;
<nav id="toggle">
<ul>
<li></li>
</ul>
</nav
This is not working. How can I call default property when the user clicks the x
mark?