Regular Expressions 101

Sponsors

Library entries

0
pcre2

vehicle-registration

German vehicle registration signs
Submitted by musemind - 22 days ago
0
pcre2

match domains from any text

match domains from any text
Submitted by seocringe - 22 days ago
0
pcre2

Match case sensitive string

Match case sensitive string
Submitted by anonymous - 22 days ago
0
pcre2

Date verification

date verification
Submitted by anonymous - 23 days ago
0
pcre2

device-linux

test
Submitted by anonymous - 23 days ago
0
pcre2

Pan card number details

https://regex101.com/r/eeW6Wz/2
Submitted by anonymous - a month ago
0
pcre2

test

test
Submitted by anonymous - a month ago
0
pcre2

Descbuilder

Filtr indeksów monitorów wg regexp
Submitted by HSI - a month ago
0
pcre2

my_regex

sample regex expression
Submitted by anonymous - a month ago
0
pcre2

Not ending with file ending

Not ending with png svg or jpg
Submitted by anonymous - a month ago

Get path from any text

Vote

5

Regular Expression
pcre2

/
((?:(?# path without "" )(?<opening>(?# 'C:/', '//', '//./<UNC/C:>', '//?/<UNC/C:>' or '%VariableWindows%')(?<UNCPrefix>[\/\\][\/\\][?.][\/\\](?:UNC[\/\\])?)?(?<montage>\b[a-zA-Z]:[\/\\])|(?:(?:(?&UNCPrefix))|(?:[\/\\][\/\\](?!(?&montage))))|(?:%\w+%[\/\\]?))(?:(?# directory btw // )[^\/\\<>:"|?\n\r ][^\/\\<>:"|?\n\r]*(?<![ ])[\/\\])*(?:(?#we search for fileName only if next character is pathFriendly)(?=[^\/\\<>:"'|?\n\r;, ])(?:(?#name file ? dir ?)(?:[^\/\\<>:"|?\n\r;, .](?: (?=\w))?(?:\*(?!= ))?(?!(?&montage)))+)?(?:(?#extention)\.\w+)*))|(?:(?# path quoted "" or '' )["'](?&opening)(?=.*?["'])(?:[^\/\\<>:'"|?\n\r]+[\/\\]?)+?["']))
/
g

Description

Loading markdown...
Submitted by nitrateag - 3 months ago