-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathindex.php
More file actions
34 lines (27 loc) · 854 Bytes
/
Copy pathindex.php
File metadata and controls
34 lines (27 loc) · 854 Bytes
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
26
27
28
29
30
31
32
33
34
<?php
Echo "<link rel='shortcut icon' href='img/favicon.ico'>";
include_once("mysql.php");
include_once("funksjoner.php");
db_connnect();
$main = file_get_contents('main.html');
$message = "";
$cpam = "";
if ($_FILES != null){
$message = $message.save_file();
}
if ($GLOBALS['db_is_connected'])
{
$mdf = check_img_modification('Bilder/');
if ($mdf){
$message = $message.'\n'.$mdf;
}
}
$files = get_imgs();
$gallery = VisBilder($files);
$main = preg_replace('/#parameters#/', $cpam, $main);
$main = preg_replace('/#gallery#/', $gallery, $main);
$tags_str = gen_tags($files);
$main = preg_replace('/#tags#/', $tags_str, $main);
echo($main); //displays the contents of the file main.html
if (!empty($message)) alert_message($message); // pop-up message
?>