Olaf Doschke
Programmer
Let's see if someone still is doing SSI here. Just out of curiosity I try to create a little building block templating just using SSI #includes.
You can imagine finally this is about processing v('QUERY_STRING') later instead of keyvaluepairs.
I expected key1 to contain "value1" only, it should be the capturing group defined by parenthesis in the regex: ([a-zA-Z0-9]*) after the constant "key1=" part of the regex.
Instead $1 is empty.
So is there something wrong with how the current version (Apache/2.4.10) processes regex?
Bye, Olaf.
Code:
<!--#set var="keyvaluepairs" value="key1=value1&key2=value2" -->
<!--#if expr="v('keyvaluepairs')=~/\bkey2=([a-zA-Z0-9]*)/" -->
<!--#set var="match" value="$0" -->
<!--#set var="key2" value="$1" -->
<!--#echo var="match" -->
<!--#echo var="key2" -->
<!--#endif -->
You can imagine finally this is about processing v('QUERY_STRING') later instead of keyvaluepairs.
I expected key1 to contain "value1" only, it should be the capturing group defined by parenthesis in the regex: ([a-zA-Z0-9]*) after the constant "key1=" part of the regex.
Instead $1 is empty.
So is there something wrong with how the current version (Apache/2.4.10) processes regex?
Bye, Olaf.