When rerouting URLs patterns which contain "::" they don't match

Hi,

I have problem matching a pattern for a route

The following pattern is not matched

c::set('routes', array(
array(

  'pattern' => 'thing::([0-9]+)\.html',
  'action' => function ($numvar) {
     echo $numvar;
   }
 )

));

without the double colons it works perfectly (also with many other characters before the palceholder / regex)

c::set('routes', array(
array(

  'pattern' => 'thing([0-9]+)\.html',
  'action' => function ($numvar) {
     echo $numvar;
   }
 )

));

this actually echos $numvar

any suggestions, workarounds are much appreaciated

Guess it is regarded as a parameter (because if I enter such an URL into the address bar - with or without the route - it returns the home page) and parameters can’t be used in routes.

Thanks for the answer

maybe I can try a combination of a htaccess rewrite and a kirby route then?

replacing ‘::’ with ‘–’ or similar?

I’ll try this in the mean time

Update: rewriting via .htaccess works, now kirby accepts the string, thanks