Beispiel #1
0
Macaw::post('/admin/link_update/(:num)', function ($slug) {
    $System = new SystemController();
    $System->link_update($slug);
});
//添加友链
Macaw::get('/admin/link_add/', 'SystemController@add_link');
Macaw::post('/admin/link_add/', 'SystemController@add_link');
//删除友情链接
Macaw::get('/admin/link_del/(:num)', function ($slug) {
    $System = new SystemController();
    $System->del_link($slug);
});
//分类链接
Macaw::get('/category/(:num).html', function ($slug) {
    $home = new HomeController();
    $home->category($slug);
});
//ajax刷新
Macaw::get('/home/getdata/', function () {
    $home = new HomeController();
    $home->getAjaxData();
});
//文章链接
Macaw::get('/article/(:num).html', function ($slug) {
    $home = new HomeController();
    $home->artice($slug);
});
//登录
Macaw::get('/admin/login/', 'LoginController@login');
Macaw::post('/admin/login/', 'LoginController@login');
//验证码