Subversion Repositories SvarDOS

Rev

Rev 89 | Rev 140 | Go to most recent revision | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 89 Rev 120
1
<?php
1
<?php
2
  $arts = array(
2
  $arts = array(
3
  'support' => 'How do I get in touch with Svarog386\'s people?',
3
  'support' => 'How do I get in touch with Svarog386\'s people?',
4
  'pkgincl' => 'Packages inclusion rules',
4
  'pkgincl' => 'Packages inclusion rules',
5
  'pkgformat' => 'Package format',
5
  'pkgformat' => 'Package format',
-
 
6
  'licensing' => 'Svarog386 licensing',
6
  'onlinerepos' => 'Svarog386 online repositories'
7
  'onlinerepos' => 'Svarog386 online repositories'
7
  );
8
  );
8
 
9
 
9
  natcasesort($arts);
10
  natcasesort($arts);
10
 
11
 
11
  if (isset($_GET['art'])) {
12
  if (isset($_GET['art'])) {
12
    $art = $_GET['art'];
13
    $art = $_GET['art'];
13
    if (!array_key_exists($art, $arts)) {
14
    if (!array_key_exists($art, $arts)) {
14
      echo "<p>invalid article!</p>";
15
      echo "<p>invalid article!</p>";
15
      return;
16
      return;
16
    } else {
17
    } else {
17
      echo "<p class=\"title\">" . htmlentities($arts[$art]) . "</p>\n";
18
      echo "<p class=\"title\">" . htmlentities($arts[$art]) . "</p>\n";
18
      echo "<p class=\"copyr\">This is an article from the Svarog386 tech base</p>\n";
19
      echo "<p class=\"copyr\">This is an article from the Svarog386 tech base</p>\n";
19
      echo '<p class="tech">';
20
      echo '<p class="tech">';
20
      echo htmlentities(file_get_contents('tech/' . $art . '.txt'));
21
      echo htmlentities(file_get_contents('tech/' . $art . '.txt'));
21
      echo "</p>\n";
22
      echo "</p>\n";
22
      return;
23
      return;
23
    }
24
    }
24
  }
25
  }
25
?>
26
?>
26
 
27
 
27
<p class="title">Svarog386 technical notes</p>
28
<p class="title">Svarog386 technical notes</p>
28
<p class="copyr">no documentation is perfect, this one's no exception</p>
29
<p class="copyr">no documentation is perfect, this one's no exception</p>
29
<table style="margin: 0 auto;">
30
<table style="margin: 0 auto;">
30
 
31
 
31
<?php
32
<?php
32
foreach ($arts as $file=>$title) {
33
foreach ($arts as $file=>$title) {
33
  echo "<tr><td><a href=\"?p=tech&art={$file}\">" . htmlentities($title) . "</a></td></tr>";
34
  echo "<tr><td><a href=\"?p=tech&art={$file}\">" . htmlentities($title) . "</a></td></tr>";
34
}
35
}
35
?>
36
?>
36
 
37
 
37
</table>
38
</table>
38
 
39