diff --git a/app/Controllers/MainController.php b/app/Controllers/MainController.php index 18ccb5f..146f5df 100644 --- a/app/Controllers/MainController.php +++ b/app/Controllers/MainController.php @@ -62,6 +62,11 @@ class MainController { Page::set('Fav'); + } + public static function gallery() + { + Page::set('Gallery'); + } public static function favauthors() { diff --git a/app/Core/Routes.php b/app/Core/Routes.php index 1e7c09c..e2a0c4b 100644 --- a/app/Core/Routes.php +++ b/app/Core/Routes.php @@ -33,6 +33,7 @@ class Routes Router::get('/api/photo/compress', 'ApiController@photocompress'); Router::get('/api/photo/loadrecent', 'ApiController@recentphotos'); Router::get('/api/users/load/$id', 'ApiController@loaduser'); + Router::get('/article/$id', 'MainController@gallery'); if (Auth::userid() > 0) { diff --git a/views/pages/Gallery.php b/views/pages/Gallery.php new file mode 100644 index 0000000..0e56fc5 --- /dev/null +++ b/views/pages/Gallery.php @@ -0,0 +1,101 @@ + + + + +
+ + + + + + + + + + + + + + + + +
+ =$gallery['title']?>+ + + $gallery['id'])); + foreach ($photos as $p) { + $photo = new Photo($p['photo_id']); + $user = new User($p['user_id']); + echo '
+
'; + } + ?> + + + + + |
+ ||