Hi Guys,
I have this weird situation. I have a regex that is working perfectly in paint layout, but failing in design file ..... Here is the snippet of code I am using in Design file ...
<MySource_AREA id_name="is_city_cairns" design_area="show_if"> <MySource_SET name="condition" value="keyword_regexp"/> <MySource_SET name="condition_keyword" value="%asset_url%"/> <MySource_SET name="condition_keyword_match" value="^[a-z,0-9,\-,\.,/,:]*cairns[/,\-,a-z]+" /> <MySource_THEN>The city is Cairns</MySource_THEN> <MySource_ELSE>%asset_url%</MySource_ELSE> <!-- Just for Testing URL --> </MySource_AREA>
The above code always print the ELSE part ...... Why ????
My URL is something like this https://www.example.com.au/location/cairns/workshop
The regex is 100% correct, I have tested it in multiple online testers such as http://regexpal.com/
I have used the same regex in one of the paint layouts, where it works perfectly. Why it's not working in design file ?
I'll really appreciate any clues .... BTW, we are on version 4.10
Thanks