Skip to content

Instantly share code, notes, and snippets.

@jmhobbs
Created March 15, 2012 17:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jmhobbs/2045349 to your computer and use it in GitHub Desktop.
Save jmhobbs/2045349 to your computer and use it in GitHub Desktop.
Make Kohana 3 Routes Case Insensitive (globally)
<?php
/* APPPATH/classes/route.php */
class Route extends Kohana_Route {
public static function compile ( $uri, array $regex = NULL ) {
if ( ! is_string( $uri ) ) { return; }
return parent::compile( $uri, $regex ) . 'i';
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment