3 * Copyright (C) 2008 Stefan Hajnoczi <stefanha@gmail.com>.
5 * This program is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU General Public License as
7 * published by the Free Software Foundation; either version 2 of the
8 * License, or any later version.
10 * This program is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
20 // The path to the errcode.py script.
21 $ERRCODE_PATH = './errcode.py';
26 <title>gPXE Error Code Lookup</title>
28 body, pre, div, form, p, h2, b, tt {
36 font-family: sans-serif;
41 background-color: #ddd;
49 border: 1px dashed black;
55 if (!empty($_REQUEST['e']) && preg_match('/^(0x)?[0-9a-f]{8}$/', $_REQUEST['e'])) {
59 system($ERRCODE_PATH . " " . $_REQUEST['e']);
65 <form action="" method="post">
66 <label for="e">Error code:</label>
67 <input type="text" name="e" id="e" value="0x12345678"></input>
68 <input type="submit" value="Lookup"></input>
74 Firefox users can right-click on the <b>Error code</b>
75 text box and select <b>Add a Keyword for this Search...</b>.
76 Set <b>name</b> to <tt>gPXE Error Code Lookup</tt> and
77 <b>keyword</b> to <tt>gxpe</tt> Then you can look up error
78 codes by typing something like the following in your address
79 bar: <tt>gpxe 0x3c018003</tt>