I'm getting a Javascript minification error saying:
(9,8617-8631): run-time error JS5017: Syntax error in regular expression: /\<br>(.*?)/ig
(9,8757-8776): run-time error JS5017: Syntax error in regular expression: /\<p>(.*?)\<\/p>/ig
The javascript where these occur is:
$htmlPattern = [
/\<br>(.*?)/ig,
/\<br\/>(.*?)/ig
];
$htmlReplace = [
'<p>$1</p>',
'<p>$1</p>'
];
...and...
$htmlContent = $htmlContent.replace(/\<p>(.*?)\<\/p>/ig, '<div>$1</div>');
Can anyone see what the problem is with the regular expressions noted?
Thanks, Mark
(.*?)/ig` or `/
]*>(.*?)/ig` – Boann Jan 23 '14 at 13:44