Exemplo n.º 1
0
 public function label($name, $text = null, $html_attributes = array())
 {
     if (!$text) {
         $text = Inflector::humanize($name);
     }
     return FormTagHelper::label_tag($this->get_field_name($name), $text, $html_attributes);
 }
Exemplo n.º 2
0
 public static function pluralize($count, $singular, $number_format = null)
 {
     $word = $count == 1 ? $singular : Inflector::pluralize($singular);
     return $number_format === null ? "{$count} {$word}" : sprintf($number_format, $count) . ' ' . $word;
 }