Skip to content

Instantly share code, notes, and snippets.

@ronan-gloo
Created October 10, 2012 19:55
Show Gist options
  • Save ronan-gloo/3868001 to your computer and use it in GitHub Desktop.
Save ronan-gloo/3868001 to your computer and use it in GitHub Desktop.
if ( ! class_exists($class))
{
if ( ! class_exists($class = $viewmodel) or ! class_exists($class = '\\View_'.ucfirst($viewmodel)))
{
throw new \OutOfBoundsException('ViewModel "View_'.ucfirst(str_replace(array('/', DS), '_', $viewmodel)).'" could not be found.');
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment