mirror of
https://git.code.sf.net/p/quake/website
synced 2025-01-31 04:30:44 +00:00
better sanity checking
This commit is contained in:
parent
c7aedc8017
commit
3494001aba
1 changed files with 12 additions and 12 deletions
24
cvar.php
24
cvar.php
|
@ -36,19 +36,19 @@
|
|||
printArray ($cvar_list, $program);
|
||||
}
|
||||
|
||||
if (strchr ($program, '.') || strchr ($program, '/')) {
|
||||
echo 'Go away.';
|
||||
return;
|
||||
if (strchr ($program, '.') || strchr ($program, '/') || !is_file ('doc/' . $program . '-cvar.txt')) {
|
||||
echo 'no such program.';
|
||||
} else {
|
||||
tableBoxHeader ('black', tableHeadColor);
|
||||
tableTitle ("cvar flags", 2, tableHeadColor);
|
||||
echo '<TR><TD>r</TD><TD>read only. Must be set on command line or in the config file.</TD></TR>';
|
||||
echo '<TR><TD>*</TD><TD>Archived. Will be saved to config.cfg.</TD></TR>';
|
||||
echo '<TR><TD>u</TD><TD>Userinfo. Changes will be sent to the server.</TD></TR>';
|
||||
echo '<TR><TD>s</TD><TD>Serverinfo. Changes will be sent to the clients.</TD></TR>';
|
||||
tableBoxFooter ();
|
||||
echo '<P></P>';
|
||||
printCvarlist ($program);
|
||||
}
|
||||
tableBoxHeader ('black', tableHeadColor);
|
||||
tableTitle ("cvar flags", 2, tableHeadColor);
|
||||
echo '<TR><TD>r</TD><TD>read only. Must be set on command line or in the config file.</TD></TR>';
|
||||
echo '<TR><TD>*</TD><TD>Archived. Will be saved to config.cfg.</TD></TR>';
|
||||
echo '<TR><TD>u</TD><TD>Userinfo. Changes will be sent to the server.</TD></TR>';
|
||||
echo '<TR><TD>s</TD><TD>Serverinfo. Changes will be sent to the clients.</TD></TR>';
|
||||
tableBoxFooter ();
|
||||
echo '<P></P>';
|
||||
printCvarlist ($program);
|
||||
?>
|
||||
|
||||
<?
|
||||
|
|
Loading…
Reference in a new issue