4 ms·
You do it all the time in web apps. For example, changing the text of a toggle link between "show" and "hide." For example, with jQuery: $('#toggleLink').cli
by jarrett 13y ago
You do it all the time in web apps. For example, changing the text of a toggle link between "show" and "hide." For example, with jQuery:
$('#toggleLink').click(function() {
if ($('#toggleLink').html() == 'Show') {
showRollout();
$('#toggleLink').html('Hide');
} else {
hideRollout();
$('#toggleLink').html('Show');
]
});
- copergi 13y agoI think you misread something. He asked how to do it without manipulating the DOM.