Subversion Repositories SvarDOS

Rev

Rev 1270 | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1270 Rev 1718
1
<!DOCTYPE html>
1
<!DOCTYPE html>
2
<html>
2
<html>
3
  <head>
3
  <head>
4
<?php
4
<?php
-
 
5
  include 'mateuszbb.php';
-
 
6
 
5
  $chapters = array('' => 'Main page',
7
  $chapters = array('' => 'Main page',
6
                    'repo' => 'Packages',
8
                    'repo' => 'Packages',
7
                    'help' => 'Help',
9
                    'help' => 'Help',
8
                    'forum' => 'Forum');
10
                    'forum' => 'Forum');
9
 
11
 
10
  /* pages available through ?p=xxx but not listed in main menu */
12
  /* pages available through ?p=xxx but not listed in main menu */
11
  $hidden_pages = array('files');
13
  $hidden_pages = array('files');
12
 
14
 
13
  $p = '';
15
  $p = '';
14
  /* validate that ?p=xxx targets a valid subpage */
16
  /* validate that ?p=xxx targets a valid subpage */
15
  if (! empty($_GET['p'])) {
17
  if (! empty($_GET['p'])) {
16
    if (!empty($chapters[$_GET['p']])) $p = $_GET['p'];
18
    if (!empty($chapters[$_GET['p']])) $p = $_GET['p'];
17
    if (in_array($_GET['p'], $hidden_pages, true)) $p = $_GET['p'];
19
    if (in_array($_GET['p'], $hidden_pages, true)) $p = $_GET['p'];
18
  }
20
  }
19
 
21
 
-
 
22
  echo '    <title>';
20
  if (empty($p)) {
23
  if (empty($p)) {
21
    echo '<title>SvarDOS</title>';
24
    echo 'SvarDOS';
-
 
25
  } else if (($p === 'forum') && (!empty($_GET['thread']))) {
-
 
26
    echo htmlspecialchars(mateuszbb_tytulwatku($_GET['thread']));
22
  } else {
27
  } else {
23
    echo '<title>SvarDOS ' . $chapters[$p] . '</title>';
28
    echo 'SvarDOS ' . $chapters[$p];
24
  }
29
  }
25
  echo "\n";
30
  echo "</title>\n";
26
?>
31
?>
27
    <meta name="keywords" content="svardos,svarog386,freedos">
32
    <meta name="keywords" content="svardos,svarog386,freedos">
28
    <meta name="author" content="Mateusz Viste">
33
    <meta name="author" content="Mateusz Viste">
29
    <meta name="robots" content="index, follow">
34
    <meta name="robots" content="index, follow">
30
    <meta charset="UTF-8">
35
    <meta charset="UTF-8">
31
    <meta name="viewport" content="width=device-width, initial-scale=1">
36
    <meta name="viewport" content="width=device-width, initial-scale=1">
32
    <link rel="stylesheet" href="style.css">
37
    <link rel="stylesheet" href="style.css">
33
  </head>
38
  </head>
34
  <body>
39
  <body>
35
 
40
 
36
  <p style="margin: 0 0 -1em auto; font-size: 0.9em; text-align: right;"><a href="/">Main page</a> I <a href="?p=repo">Packages</a> I <a href="?p=help">Help</a> I <a href="?p=forum">Forum</a>  <!-- I <a href="?p=nls">NLS</a>--></p>
41
  <p style="margin: 0 0 -1em auto; font-size: 0.9em; text-align: right;"><a href="/">Main page</a> I <a href="?p=repo">Packages</a> I <a href="?p=help">Help</a> I <a href="?p=forum">Forum</a>  <!-- I <a href="?p=nls">NLS</a>--></p>
37
 
42
 
38
<?php
43
<?php
39
 
44
 
40
  if (empty($p)) {
45
  if (empty($p)) {
41
    include 'index-main.php';
46
    include 'index-main.php';
42
  } else {
47
  } else {
43
    include "index-{$p}.php";
48
    include "index-{$p}.php";
44
  }
49
  }
45
 
50
 
46
?>
51
?>
47
  </body>
52
  </body>
48
</html>
53
</html>
49
 
54