website view libs/archives.php @ rev 751
Move archives.php to libs/
author | Christophe Lincoln <pankso@slitaz.org> |
---|---|
date | Mon Jan 24 00:02:41 2011 +0100 (2011-01-24) |
parents | |
children | fb64fecc9b66 |
line source
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
2 <html xmlns="http://www.w3.org/1999/xhtml">
3 <head>
4 <title>lists.tuxfamily.org/slitaz mailing list</title>
5 <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
6 <!-- link rel="stylesheet" type="text/css" href="/slitaz.css" / -->
7 <style type="text/css">
8 body {
9 background: #ffffff;
10 color: black;
11 font: 13px sans-serif, vernada, arial;
12 margin: 0;
13 #border-top: 34px solid #f1f1f1;
14 }
15 table {
16 border: 1px solid #000000;
17 width: variable;
18 border-collapse: collapse;
19 margin: 2px 2px;
20 }
21 td {
22 border: 1px dotted #6495ed;
23 width: variable;
24 padding: 2px;
25 }
26 .rowodd {
27 background-color: #ffffff;
28 }
29 .roweven {
30 background-color: #e1ffe1; /* the tower */
31 }
32 th {
33 border: 1px solid #000000;
34 width: variable;
35 padding: 4px;
36 }
37 .alignright {
38 text-align: right;
39 }
40 </style>
41 </head>
42 <body>
43 <?php
45 function translate($word)
46 {
47 if (isset($_GET['lang'])) switch ($_GET['lang']) {
48 case "de" :
49 switch ($word) {
50 case "Archives" : return "Archiv";
51 case "Archive" : return "Archiv";
52 case "View by" : return "Ansicht von";
53 case "Number" : return "Zahl";
54 case "Total size": return "Gesamtgr\ö\ße";
55 case " or " : return " oder ";
56 case "Date" : return "datum";
57 }
58 break;
59 case "es" :
60 switch ($word) {
61 case "Archives" : return "Archivos";
62 case "Archive" : return "Archivo";
63 case "View by" : return "Vista";
64 case "Number" : return "n\úmero";
65 case "Total size": return "Tama\ño total";
66 case "Thread" : return "hilo";
67 case " or " : return " o ";
68 case "Date" : return "Fecha";
69 }
70 break;
71 case "fr" :
72 switch ($word) {
73 case "View by" : return "Tri\é par";
74 case "Number" : return "Nombre";
75 case "Total size": return "Volume";
76 case "Thread" : return "Sujet";
77 case " or " : return " ou ";
78 }
79 break;
80 case "pt" :
81 switch ($word) {
82 case "Archives" : return "Arquivos";
83 case "Archive" : return "Arquivo";
84 case "View by" : return "Exibir por";
85 case "Number" : return "n\úmero";
86 case "Total size": return "O tamanho total";
87 case "Thread" : return "T\ópico";
88 case " or " : return " ou ";
89 case "Date" : return "Data";
90 }
91 break;
92 }
93 return $word;
94 }
96 echo '<h4>'.translate("Archives").' 2007-'.date('Y')."</h4>\n";
98 $url = "http://listengine.tuxfamily.org/lists.tuxfamily.org/slitaz/";
100 $script = "-e '/<table>/,/<\/table>/!d' ";
101 $script .= "-e 's|html\"|html\" target=\"_blank\"|g' ";
102 $script .= "-e 's|href=\"|href=\"$url|g' ";
103 foreach (array("Archive","View by","Number","Total size",
104 "Thread"," or ","Date") as $word) {
105 $script .= "-e 's|".$word."|".translate($word)."|' ";
106 }
107 system("wget -q -O - $url | sed $script");
108 ?>
109 </body>
110 </html>