Regex unexpected token

javascript, jquery, jquery-validation-engine

Solution

Replace

   "regex": ^([0-9]|0[0-9]|1[0-3]|2[0-3]):[0-5][0-9]$,

with

   "regex": /^([0-9]|0[0-9]|1[0-3]|2[0-3]):[0-5][0-9]$/,

See the syntax of regex literals.

Problem

When I add this regex into validation engine I get a javascript error: "unexpected token", it seems that the regex is wrong because it is underline with red, why? ``` "time1":{ "regex": ^([0-9]|0[0-9]|1[0-3]|2[0-3]):[0-5][0-9]$, "alertText": "* Invalid Time" } ```

Original source