Javascript in chrome plugin has syntax error
- by Cyclone
chrome.tabs.executeScript(null, {code:"$.each(selectValues, function(key='" + timestamp + "', value='Custom')
{
$('#expire').
append($(\"<option></option>\").
attr(\"value\",key).
text(value));
});"});
It says that the first line has a syntax error, and the WebKit inspector shows odd highlighting patterns.
What's wrong with that? A friend thinks I need to escape some characters somewhere.
Thanks for the help!