Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Regex check in JIRA validation script

Scott Farrimond
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
November 16, 2017

I'm trying to check a custom field for a URL string (any URL).  I think I have the regex correct, but I haven't been able to get the syntax right.  

 

RegEx = ^(http:\\/\\/www\\.|https:\\/\\/www\\.|http:\\/\\/|https:\\/\\/)?[a-z0-9]+([\\-\\.]{1}[a-z0-9]+)*\\.[a-z]{2,5}(:[0-9]{1,5})?(\\/.*)?$ 

 

Anyone have a snippet that does something similar?

1 answer

0 votes
Aidan Derossett [Adaptavist]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
November 17, 2017

Hey Scott!

I'd like to help you out here, but I'm not quite sure I understand what the issue is. This is probably a stupid question, but what do you mean when you say "I haven't been able to get the syntax right?" You don't think your Regex syntax is right?

Thanks!

Aidan

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events