本文整理汇总了PHP中UserController::edit方法的典型用法代码示例。如果您正苦于以下问题:PHP UserController::edit方法的具体用法?PHP UserController::edit怎么用?PHP UserController::edit使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类UserController
的用法示例。
在下文中一共展示了UserController::edit方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: function
UserController::logout();
});
$routes->get('/logout/', function () {
UserController::logout();
});
$routes->get('/register/', function () {
UserController::register();
});
$routes->post('/register/', function () {
UserController::handle_register();
});
$routes->post('/user/:user_id/delete', function ($item_id) {
UserController::destroy($item_id);
});
$routes->get('/user/:user_id/edit', function ($user_id) {
UserController::edit($user_id);
});
$routes->post('/user/:user_id/edit', function ($user_id) {
UserController::update($user_id);
});
// Vaatteen esittelysivu
$routes->get('/user/:item_id', function ($user_id) {
UserController::show($user_id);
});
// Vaatteet
// Vaatteiden indeksisivu
$routes->get('/items/', function () {
ItemController::index();
});
// Vaatteen lisäyssivu
$routes->get('/items/new', function () {
示例2: function
UserController::create();
});
$routes->post('/signup', function () {
UserController::store();
});
$routes->get('/user', function () {
UserController::index();
});
$routes->get('/user/:id', function ($id) {
UserController::show($id);
});
$routes->post('/user/:id', function ($id) {
UserController::update($id);
});
$routes->get('/user/:id/edit', function ($id) {
UserController::edit($id);
});
$routes->get('/user/:id/destroy', function ($id) {
UserController::destroy($id);
});
$routes->get('/group', function () {
GroupController::index();
});
$routes->post('/group', function () {
GroupController::store();
});
$routes->get('/group/new', function () {
GroupController::create();
});
$routes->get('/group/:id', function ($id) {
GroupController::show($id);
示例3: array
$id = $_GET['id'];
$p = array();
$user = new UserController($conn);
$user->lang = $lang;
$user->UserLevel = $UserLevel;
$user->UserID = $UserID;
$user->lang_str = $lang_str;
switch ($action) {
case "list":
$user->browse();
break;
case "add":
$user->add();
break;
case "edit":
$user->edit($id);
break;
case "save":
$vars['edittype'] = $_POST['edittype'];
$vars['password'] = $_POST['password'];
$vars['password2'] = $_POST['password2'];
$vars['id'] = $_POST['id'];
$vars['user_id'] = $_POST['user_id'];
$vars['user_name'] = $_POST['user_name'];
$vars['title'] = $_POST['title'];
$vars['level'] = $_POST['level'];
$vars['email'] = $_POST['email'];
$vars['active'] = $_POST['active'];
$user->save($p, $vars);
break;
case "delete":