~ubuntu-branches/ubuntu/precise/boinc/precise

« back to all changes in this revision

Viewing changes to doc/docutil.php

Tags: 6.12.8+dfsg-1
* New upstream release.
* Simplified debian/rules

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
<?php
2
2
 
 
3
require_once("../inc/util_basic.inc");
 
4
require_once("../inc/translation.inc");
 
5
 
3
6
if (0) {
4
7
    $x = $_SERVER['PHP_SELF'];
5
8
    $path = "/tmp/php_pids/".getmypid();
15
18
    <input type=hidden name=sitesearch value=\"http://boinc.berkeley.edu\">
16
19
    <span class=\"nobar\">
17
20
    <input class=small name=q size=20>
18
 
    <input class=small type=submit value=Search>
 
21
    <input class=small type=submit value=".tra("Search").">
19
22
    </span>
20
23
    </form>
21
24
";
77
80
    echo "
78
81
        Copyright &copy; $y University of California.
79
82
        Permission is granted to copy, distribute and/or modify this document
80
 
        under the terms of the GNU Free Documentation License,
 
83
        under the terms of the 
 
84
        <a href=http://www.gnu.org/copyleft/fdl.html>GNU Free Documentation License</a>,
81
85
        Version 1.2 or any later version published by the Free Software Foundation.
82
86
    ";
83
87
}
95
99
    if (!$is_main) {
96
100
        echo "
97
101
            <center>
98
 
            <a href=\"/\">Return to BOINC main page</a>
 
102
            <a href=\"/\">".tra("Return to BOINC main page")."</a>
99
103
            </center><p>
100
104
        ";
101
105
    }
102
106
    echo "
103
 
        <font color=888888 size='2'>
 
107
        <span class=note>
 
108
        <font color=#888888>
104
109
    ";
105
110
    if ($translatable) {
106
 
        echo "
107
 
            This page is <a href=\"trac/wiki/TranslateIntro\">translatable</a>.<br>
 
111
        echo 
 
112
            sprintf(
 
113
                tra("This page is %stranslatable%s."),
 
114
                "<a href=\"trac/wiki/TranslateIntro\">",
 
115
                "</a>"
 
116
            ),
 
117
            "<br>
108
118
        ";
109
119
    }
110
120
    echo "
113
123
    copyright();
114
124
    echo "
115
125
        </font>
 
126
        </span>
116
127
        </body>
117
128
        </html>
118
129
    ";
163
174
function list_item_array($x) {
164
175
    echo "<tr>";
165
176
    foreach ($x as $h) {
166
 
        echo "<td valign=top>$h<br></td>";
 
177
        echo "<td valign=top>$h</td>";
167
178
    }
168
179
    echo "</tr>\n";
169
180
}
185
196
    echo "</table><p>\n";
186
197
}
187
198
 
188
 
function error_page($x) {
 
199
function boinc_error_page($x) {
189
200
    page_head("Error");
190
201
    echo $x;
191
202
    page_tail();
204
215
    ";
205
216
}
206
217
 
207
 
function get_str($name) {
208
 
    if (isset($_GET[$name])) {
209
 
        $x = $_GET[$name];
210
 
        $x = trim($x);
211
 
        return mysql_real_escape_string($x);
212
 
    }
213
 
    return null;
214
 
}
215
 
 
216
218
function show_link($url) {
217
219
    echo "<br><a href=$url>$url</a>";
218
220
}
219
221
 
220
 
function parse_element($xml, $tag) {
221
 
    $element = null;
222
 
    $closetag = "</" . substr($tag,1);
223
 
    $x = strstr($xml, $tag);
224
 
    if ($x) {
225
 
        if (strstr($tag, "/>")) return $tag;
226
 
        $y = substr($x, strlen($tag));
227
 
        $n = strpos($y, $closetag);
228
 
        if ($n) {
229
 
            $element = substr($y, 0, $n);
230
 
        }
 
222
function get_str2($x) {
 
223
    if (array_key_exists($x, $_GET)) {
 
224
        return $_GET[$x];
231
225
    }
232
 
    return trim($element);
 
226
    return null;
233
227
}
 
228
 
234
229
?>