Please enable JavaScript to use regex101
/
^
r
e
g
e
x
[
\
-
_
]
?
1
0
1
$
/
i
Reg
ular
Ex
pressions
101
Upgrade to Pro
Enterprise
Regular Expression
/
^\/t(?:\/(\d+)\/[a-z_-]+\/?|op(\d+)\.html)$
/
gim
Input 1
1
New
good examples: /t/2/title/ /t/98127/welcome_world-here/ /top1.html /top2126.html /top102542/120939.html bad examples: #should not match /top2120/welcome/ /t/2121.html /t/2124/bla.html /blabla21051.html
Extraction
good examples: /t/2/title/ /t/98127/welcome_world-here/ /top1.html /top2126.html /top102542/120939.html bad examples: #should not match /top2120/welcome/ /t/2121.html /t/2124/bla.html /blabla21051.html