Ejemplo n.º 1
0
 /**
  *  register the default filters without any service provider
  *
  */
 private function setDefaultFilters()
 {
     FilterBag::addFilter('int', '([0-9]+)');
     FilterBag::addFilter('sef', '([a-zA-ZÇŞĞÜÖİçşğüöı0-9+_\\-\\. ]+)');
     FilterBag::addFilter('string', '([a-zA-Z]+)');
 }
Ejemplo n.º 2
0
 /**
  * Register a new filter with name and type
  *
  * @param string $name The name of filter
  * @param string $type The type of filter
  * @return $this
  */
 public function filter($name, $type = '')
 {
     FilterBag::addFilter($name, $type);
     return $this;
 }