New issue
Advanced search Search tips

Issue 645100 link

Starred by 2 users

Issue metadata

Status: Duplicate
Owner: ----
Closed: Sep 2016
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows
Pri: 2
Type: Bug



Sign in to add a comment

regular expression not working

Reported by vipulgar...@gmail.com, Sep 8 2016

Issue description

UserAgent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/53.0.2785.101 Safari/537.36

Example URL:

Steps to reproduce the problem:
Intermittent, occurs 2 out of 4 times. goes away on refreshing once or twice.

1. use regex ^([\w\.\-_]+)?\w+@[\w-_]+(\.\w+){1,}$ for email validation
2. chrome version 53 won't accept it
3. gives error
Pattern attribute value ^([\w\.\-_]+)?\w+@[\w-_]+(\.\w+){1,}$ is not a valid regular expression: Uncaught SyntaxError: Invalid regular expression: /^([\w\.\-_]+)?\w+@[\w-_]+(\.\w+){1,}$/: Invalid character class.

What is the expected behavior?
regex should have worked/been accepted by the browser.

What went wrong?
Its i giving error and stopping to proceed next.
Intermittent, occurs 2 out of 4 times. goes away on refreshing once or twice.

Does it occur on multiple sites: Yes

Is it a problem with a plugin? No 

Did this work before? Yes all many versions before 53, it worked on 52.....

Does this work in other browsers? Yes 

Chrome version: 53.0.2785.101  Channel: stable
OS Version: 6.1 (Windows 7, Windows Server 2008 R2)
Flash Version: Shockwave Flash 22.0 r0
 
Status: WontFix (was: Unconfirmed)
I pulled the old versions of chrome and tried in 47.0.2515.0 and in FireFox 48.0 as well. So likely you just didn't notice the error before. It is an incorrect RegExp. There isn't much we can do about that.

Comment 2 by tkent@chromium.org, Sep 9 2016

Components: -Blink Blink>Forms>Text
Mergedinto: 638197
Status: Duplicate (was: WontFix)
Firefox shows a similar error.

> ... @[\w-_]+ ...

This should be ... @[\w\-_]+ ...

Sign in to add a comment