I have urls in this format:-
/scan/anything/se=hello-world/se=word.html
/scan/anything/se=hello-world/se=1.5/
/scan/anything/se=temp-2.5/se=1.5.html
I'm trying to match word characters after each se= plus the dash and decimal and capture them.
The regex I have come up with is this:-
^/scan/.*?se=([\w-.]*)/?(?:se=)([\w-.]*)/?(?:.html)?
Because I have added a dot(.) in the character class to match the decimal point it also matches .html so captures word.html and 1.5.html rather than just "word" and "1.5" from urls 1 and 3, how can I stop it matching .html I've tried various negations but none seem to work.
Desired output:
- hello-world and word
- hello-world and 1.5
- temp-2.5 and 1.5