I am getting the following error:
Uncaught SyntaxError: Unexpected token ILLEGAL
and this is showing on line 1 of my page.
I am using the following code:
$('.hollaBackClick').live('click', function(){
var currentElement = $(this);
var hollaID = currentElement.attr('hollaID');
var userID = currentElement.attr('userID');
var username = currentElement.attr('username');
var hollaBackBoxHTML = '<form id="hollaBackForm">' +
'<input type="hidden" name="hollaID" value="' + hollaID + '" />' +
'<input type="hidden" name="userID" value="' + userID + '" />' +
'<input type="hidden" name="username" value="' + username + '" />' +
'<textarea name="hollaBackContent" id="hollaBackContent" placeholder="HollardBack@' + username + '" />' +
'<input type="submit" name="hollaBackSubmit" id="hollaBackSubmit" value="HollaBack" />' +
'</form>';
currentElement.after(hollaBackBoxHTML);
});
I am using click events all over the website and this is the only place I get the error and I am somewhat stumped into what could be causing the issue…
are you trying to do like this?