mirror of
https://github.com/laravel/laravel.git
synced 2025-02-20 11:53:14 +08:00
added more html5 form elements.
This commit is contained in:
parent
cd33e81702
commit
2da478cc38
@ -194,6 +194,19 @@ class Form {
|
||||
return static::input('search', $name, $value, $attributes);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a HTML color input element.
|
||||
*
|
||||
* @param string $name
|
||||
* @param string $value
|
||||
* @param array $attributes
|
||||
* @return string
|
||||
*/
|
||||
public static function color($name, $value = null, $attributes = array())
|
||||
{
|
||||
return static::input('color', $name, $value, $attributes);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a HTML number input element.
|
||||
*
|
||||
@ -207,6 +220,19 @@ class Form {
|
||||
return static::input('number', $name, $value, $attributes);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a HTML range input element.
|
||||
*
|
||||
* @param string $name
|
||||
* @param string $value
|
||||
* @param array $attributes
|
||||
* @return string
|
||||
*/
|
||||
public static function range($name, $value = null, $attributes = array())
|
||||
{
|
||||
return static::input('range', $name, $value, $attributes);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a HTML telephone input element.
|
||||
*
|
||||
@ -220,6 +246,19 @@ class Form {
|
||||
return static::input('tel', $name, $value, $attributes);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a HTML date input element.
|
||||
*
|
||||
* @param string $name
|
||||
* @param string $value
|
||||
* @param array $attributes
|
||||
* @return string
|
||||
*/
|
||||
public static function date($name, $value = null, $attributes = array())
|
||||
{
|
||||
return static::input('date', $name, $value, $attributes);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a HTML file input element.
|
||||
*
|
||||
@ -235,7 +274,7 @@ class Form {
|
||||
/**
|
||||
* Create a HTML submit input element.
|
||||
*
|
||||
* @param string $name
|
||||
* @param string $value
|
||||
* @param array $attributes
|
||||
* @return string
|
||||
*/
|
||||
@ -244,6 +283,18 @@ class Form {
|
||||
return static::input('submit', null, $value, $attributes);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a HTML reset input element.
|
||||
*
|
||||
* @param string $value
|
||||
* @param array $attributes
|
||||
* @return string
|
||||
*/
|
||||
public static function reset($value, $attributes = array())
|
||||
{
|
||||
return static::input('reset', null, $value, $attributes);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a HTML button element.
|
||||
*
|
||||
|
Loading…
x
Reference in New Issue
Block a user