This code doesn't work as intended, what am I doing wrong?
$(document).ready(function(){
$("a.hide-para").click(function(){
$('p').hide();
$(this).html('Show Paragraphs').removeClass('hide-para').addClass('show-para');
});
$("a.show-para").click(function(){
$('p').show();
$(this).html('Hide Paragraphs').removeClass('show-para').addClass('hide-para');
});
});