Jump to content
MakeWebGames

JavaScript Form Maker


Script47

Recommended Posts

Nice!

Though, your regex is flawed on line 64+.

 

  • Using [A-z] will include all ASCII characters from the range A to z, which isn't intended (I would assume). See ASCII table. [A-z] will allow special characters like [, ], /, ^ - See example
  • You're missing your anchors to match the entire string. For example; ^[A-z]+$

 

I wouldn't advise building the JSON string manually, either. I would build the array, then use JSON.stringify.

Edited by sniko
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...