Syntaxerror:identifier starts immediately after numeric literal error resolution

Source: Internet
Author: User

A syntax error was encountered today in a project that jumps with Ajax and passes data in a URL

functionSave (Flag,checkflag) {$ (' #allInfoForm '). Ajaxsubmit ({dataType:' JSON ', type:"POST", data:{"Operationflag": Flag, "Checkflag": Checkflag, "ApplicationID": ' $!applicationid '}, Success:function(data) {if(data.success) {dialog.message (Data.message,"Prompt",function() {self.location.href=contextpath+ "/intopieces/applyintopiecewait/change.page?applicationid=" + ' $!applicationid ' + "&customerId=" + ' $!customerid ' + ' &applyquota= ' + ' $!applyquota ' + ' &serialnumber= ' + ' $!serialnumber ';                }); } Else{dialog.message (data.message); return false; }}, Error:function(data) {dialog.closeload (); Dialog.message ("Operation failed"); return false;    }        }); }

Syntaxerror:identifier starts immediately after numeric literal

The value of the parameter is:

ApplicationID 402881e74a384553014a385826a70003
Applyquota 1000
CustomerId 0000000049bb6a710149bb872c1d0007
SerialNumber 402881e74a384553014a385882e5000d

Workaround:

Applicationid= "+ ' $!applicationid ' +" &customerid= "+ ' $!customerid ' +" &applyquota= "+ ' $!applyquota ' +" & Serialnumber= "+ ' $!serialnumber ';

When stitching, the data to be transmitted is enclosed in '.

Syntaxerror:identifier starts immediately after numeric literal error resolution

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.