Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
syncEnrollments
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Yeray Santana Hualde
syncEnrollments
Commits
f7dcb057
Commit
f7dcb057
authored
Jul 02, 2011
by
Taylor Otwell
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
added more html5 form elements.
parent
2da478cc
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
51 additions
and
1 deletion
+51
-1
routes.php
application/routes.php
+0
-1
form.php
system/form.php
+51
-0
No files found.
application/routes.php
View file @
f7dcb057
...
@@ -19,7 +19,6 @@ return array(
...
@@ -19,7 +19,6 @@ return array(
'GET /'
=>
function
()
'GET /'
=>
function
()
{
{
return
Form
::
input
(
'email'
,
'email'
,
''
,
array
(
'required'
,
'class'
=>
'awesome'
));
return
View
::
make
(
'home/index'
);
return
View
::
make
(
'home/index'
);
},
},
...
...
system/form.php
View file @
f7dcb057
...
@@ -259,6 +259,45 @@ class Form {
...
@@ -259,6 +259,45 @@ class Form {
return
static
::
input
(
'date'
,
$name
,
$value
,
$attributes
);
return
static
::
input
(
'date'
,
$name
,
$value
,
$attributes
);
}
}
/**
* Create a HTML time input element.
*
* @param string $name
* @param string $value
* @param array $attributes
* @return string
*/
public
static
function
time
(
$name
,
$value
=
null
,
$attributes
=
array
())
{
return
static
::
input
(
'time'
,
$name
,
$value
,
$attributes
);
}
/**
* Create a HTML datetime input element.
*
* @param string $name
* @param string $value
* @param array $attributes
* @return string
*/
public
static
function
datetime
(
$name
,
$value
=
null
,
$attributes
=
array
())
{
return
static
::
input
(
'datetime'
,
$name
,
$value
,
$attributes
);
}
/**
* Create a HTML local datetime input element.
*
* @param string $name
* @param string $value
* @param array $attributes
* @return string
*/
public
static
function
datetime_local
(
$name
,
$value
=
null
,
$attributes
=
array
())
{
return
static
::
input
(
'datetime-local'
,
$name
,
$value
,
$attributes
);
}
/**
/**
* Create a HTML file input element.
* Create a HTML file input element.
*
*
...
@@ -295,6 +334,18 @@ class Form {
...
@@ -295,6 +334,18 @@ class Form {
return
static
::
input
(
'reset'
,
null
,
$value
,
$attributes
);
return
static
::
input
(
'reset'
,
null
,
$value
,
$attributes
);
}
}
/**
* Create a HTML image input element.
*
* @param string $value
* @param array $attributes
* @return string
*/
public
static
function
image
(
$value
,
$attributes
=
array
())
{
return
static
::
input
(
'image'
,
null
,
$value
,
$attributes
);
}
/**
/**
* Create a HTML button element.
* Create a HTML button element.
*
*
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment