So I'm just getting started here, apologies in advance if this is a stupid question but I can't seem to load content onto the page if the <span> was echoed in a heredoc. For instance:
If a user enters an incorrect password, the php reads...
}else{
echo<<<HERE
Sorry, your b.s. password didn't work! <span id = "reload">Try again?</span>
HERE;
Within the $(init) contained in the page, is the following:
$("#reload").click(main);
Later, the main function is:
function main(){
$("Output").html("Maint.txt");
}
In testing the page, the main function works fine in the beginning(before called by the span within the PHP), and the span is clearly recognized (text color changes, as does the cursor shape) but once it is clicked nothing happens. Any ideas?