How would I write a regular expression (C#) which will check a given string to see if any of its characters are characters OTHER than the following:
a-z
A-Z
Æ æ Å å Ø ø - '
Thanks!
Hello I need help with Regular Expression,
I want to match each section (number and it's text - 2 groups), the text can be multi line, each section ends when another section starts (another number) or when .END is reached or EOF.
Demo
Expression:
\(\d{1,3}\) ([\s\S]*?)(\.END|\(\d{1,3}\))
Input text:
(1) some text some text
some text some text
some text some text
(2) some text some textsome text
(3) some textsome text
some textsome textsome text
(4) some text
.END
first group should match number (with brackets) and second group should match corresponded text.
I've got (To) [a-z]+ as regular expression and I've got sentence:
To kot dziki pies.
And If I compile it I will retrieve To kot.
So what can I do to rtrieve only word after (only kot) "To" instead of "To kot"
I have a string of names like this "J. Smith; B. Jones; O. Henry"
I can match all but the last name with
\w+.*?;
Is there a regular expression that will match all the names, including the last one?
I have a regular expression, links = re.compile('<a(.+?)href=(?:"|\')?((?:https?://|/)[^\'"]+)(?:"|\')?(.*?)>(.+?)</a>',re.I).findall(data)
to find links in some html, it is taking a long time on certain html, any optimization advice?
One that it chokes on is http://freeyourmindonline.net/Blog/
I need to change some characters that are not ASCII to '_'.
For example,
Tannh‰user - Tann_huser
If I use regular expression with Python, how can I do this?
Is there better way to do this not using RE?
I already know the basics of RegEx but I'm not sure where to go from here, I'm looking for both a good and above all easy to understand guide but I am also looking for things to use RegEx's for, it's all well and good reading about it but if you never use them then they will not stick in your mind.
I have already found regular-expressions.info but I'm sure there are more.
Hi
Please help me with a regular expression to validate the following format
dd/mm
This is for validating a Birthday field and the year is not required.
Thanks
I need a regular in expression in PHP that I can plug into preg_match_all and find if an @ sign and any character number or letter follows right after that. So if I put "@patrick hello there" it will come up true, if I put in "I saw her @ the mall" it will be false.
Thank you :)
I am trying to write a regular expression for somethin like
s1 = I am at Boston at Dowtown
s2 = I am at Miami
I am interested in the words after at eg: Boston, Downtown, Miami
I have not been successful in creating a regex for that. Somethin like
> .*? (at \w+)+.*
gives just Boston in s1 (Downtown is missed). it just matches the first "at" Any suggestions
I need regular expression to match braces correct e.g for every open one close one
abc{abc{bc}xyz} I need it get all it from {abc{bc}xyz} not get {abc{bc} I tried this
({.*?})
What will be proper regular expression for git repositories?
example link:
[email protected]:someone/someproject.git
so it will be like
server can be url or ip
Project can contain some other characters than alphanumeric like '-'
I'm not sure what is the role of '/'
any suggestions?
I know this may be the simplest question ever asked on Stack Overflow, but what is the regular expression for a decimal with a precision of 2?
Valid examples:
123.12
2
56754
92929292929292.12
0.21
3.1
Invalid examples:
12.1232
2.23332
e666.76
Sorry for the lame question, but for the life of me I haven't been able to find anyone that can help!
The decimal place may be option, and that integers may also be included.
What will be the regular expression in javascript to match a name field,
which allows only letters, apostrophes and hyphons?
so that jhon's avat-ar or Josh is valid?
Thanks
I need help on regular expression on the condition (4) below:
Begin with a-z
End with a-z0-9
allow 3 special characters like ._-
The characters in (3) must be followed by alphanumeric characters, and it cannot be followed by any characters in (3) themselves.
Not sure how to do this. Any help is appreciated, with the sample and some explanations.
I am an amateur in JavaScript. I saw this other question, and it made me wonder.
Can you tell me what does the below regular expression exactly mean?
split(/\|(?=\w=>)/)
Does it split the string with "|"?
Hi
what will be the regular expression to extract challenge var value
i am interested in this vlaue
03AHJ_Vut9LJLOJuCsjF9PbSSMncTyUe7Y4dHX11eRLae3LGfDZ0hSfDR7jZq2ZrKJxyC-LRSSppv72oHKaQMsd-EnoVNL6p7liTh7siN26zzTA_E2rcC_JQ15613Azz4qm8HjPtAyksUdc7QZydszwolk92hBPrAAig
this value changes every time we refresh it so the expression has to be generic enough to pick up what ever is the value
var RecaptchaState = {
site : '6LeKCL8SAAAAADV5Dr-lfY2eOEV8rubeN25BAKp2',
challenge : '03AHJ_Vut9LJLOJuCsjF9PbSSMncTyUe7Y4dHX11eRLae3LGfDZ0hSfDR7jZq2ZrKJxyC-LRSSppv72oHKaQMsd-EnoVNL6p7liTh7siN26zzTA_E2rcC_JQ15613Azz4qm8HjPtAyksUdc7QZydszwolk92hBPrAAig',
is_incorrect : false,
programming_error : '',
error_message : '',
server : 'http://www.google.com/recaptcha/api/',
timeout : 18000};
any help will be appreciated, or any method to extract this value in any server side lang
Can someone give me the regular expression to match something like /this/is/the/path or /this/is/the/path/ and matches like:
$1=this
$2=is
$3=the
$4=path
([^/]+)/ matches one, but I'm not quite sure how to get it to repeat.
FYI: this is for a mod rewrite RewriteRule match.
I need a regular expression to validate string with one or more of these characters:
a-z
A-Z
'
àòèéùì
simple white space
FOR EXAMPLE these string are valide:
D' argon calabrò
maryòn l' Ancol
these string are NOT valide:
hello38239
my_house
work [tab] with me
I tryed this:
re.match(r"^[a-zA-Z 'òàèéìù]+$", self.cleaned_data['title'].strip())
It seems to work in my python shell but in Django I get this error:
SyntaxError at /home/
("Non-ASCII character '\\xc3' ...
Why ?
Does anyone know of a regular expression for matching on a sequence of four numbers? I need a match on ascending (1234), descending (4321), or the same (1111).
Looking for some help with a Regular Expression to do the following:
Must be Alpha Char
Must be at least 1 Char
Must NOT be a specific value, e.g. != "Default"
Thanks for any help,
Dave
I'm good at learning new languages and platforms, though whenever I try to learn Reg Ex I cannot make sense of it. I once even used the Regular Expression Designer to try and put some together.
What's a good starting point to understanding what looks like the only rocket-science programming language in the world?
Links to articles, books or anything else that could help me get my grounding would be appreciated.