I'm wondering what exactly the return false;
statement is doing in this Pig-Latin translator? By removing it I can see that the page seems to automatically refresh (immediately wipes the 'translation' rather than leaving it), but I don't understand the mechanics. What's going on? I don't think the HTML or JS is necessary to answer my question, but let me know if I'm mistaken and I'll paste it in.
The jQuery:
$(function() {
$("form#translator").submit(function() {
var englishWord = $("input#word").val();
var translatedWord = englishToPigLatin(englishWord);
$("#english").append(englishWord);
$("#pig-latin").append(translatedWord);
$("#translation").show();
return false;
});
});