Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

SyntaxError: missing ) after argument list in fire bug

I am getting the syntax error:

SyntaxError: missing ) after argument list

From this jQuery code:

$("#createEnquiry").text(${noEnqMsg});

What kinds of mistakes produce this Javascript Syntax error?

like image 406
shyamli Avatar asked Mar 12 '23 18:03

shyamli


1 Answers

I think you meant to use string quotes:

$("#createEnquiry").text("${noEnqMsg}");

Or maybe you though you were using template strings:

$("#createEnquiry").text(`${noEnqMsg}`);
like image 65
basarat Avatar answered Mar 23 '23 01:03

basarat