summaryrefslogtreecommitdiffstats
path: root/index.php
blob: 579dc71dc2097a2a8b7041320bc53146ff7b5967 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
<?php
// Copyright (C) 2014 Paul Kocialkowski <contact@paulk.fr>, GNU GPLv3+

require_once("include/photos.php");

include("include/header.php");

photos_albums_discover();

if ($_GET["album_path"] != null && $_GET["album_file"] != NULL) {
	$rc = photos_album_file_show($_GET["album_path"], $_GET["album_file"]);
	if ($rc < 0)
		photos_error("Unable to show album file");
} else if ($_GET["album_path"] != null) {
	$rc = photos_album_files_show($_GET["album_path"]);
	if ($rc < 0)
		photos_error("Unable to show album files");
} else {
	$rc = photos_albums_show();
	if ($rc < 0)
		photos_error("Unable to show albums");
}

include("include/footer.php");
?>