jquery + regex. How to use quotation marks to print HTML code?
I just don't get this right. How do I use quotation marks to get this work?
$("div a').replaceWith('<a href="#" onclick="'+data['hash']+'")>Link</a>');
I have tried for example this and other variations:
$("div a').replaceWith('<a href="#"
onclick="'+data[/\'hash/\']+'")>Link</a>');
I'm far from being regex expert...
No comments:
Post a Comment