Example #1
0
dgr_startup();
?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

<head>
	<title><?php 
echo gettext('DGrade - Error');
?>
</title>
	<meta http-equiv="content-type" content="text/html;charset=utf-8" />
	<meta name="generator" content="Geany 0.16" />
	<link type="text/css" rel="stylesheet" href="<?php 
echo dgr_get_style('..');
?>
" />
</head>

<body>

<div id="main">


<?php 
dgr_require('/includes/db.php');
function sql_tables_from_file($filename, &$dblink, $stop_on_error = true)
{
    $sql = file($filename);
    foreach ($sql as $sqlline) {
Example #2
0
try {
    $user = new DGradeUser();
    $style = dgr_get_style('.', $user->get_styleid());
    $semesters = dgr_get_semesters();
    $classes = $user->get_classes($semesters[0]['id']);
    if (count($classes) > 0) {
        $class = new DGradeClass($classes[0]['class_id']);
        $classload = true;
    } else {
        $classload = false;
    }
} catch (Exception $e) {
    $error = true;
    $classload = false;
    $errmsg = $e->getMessage();
    $style = dgr_get_style('.');
}
?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

<head>
	<title>DGrade - <?php 
echo gettext('main page');
?>
</title>
	<meta http-equiv="content-type" content="text/html;charset=utf-8" />
	<meta name="generator" content="Geany 0.16" />
	<link type="text/css" rel="stylesheet" href="<?php 
Example #3
0
 *      This program is distributed in the hope that it will be useful,
 *      but WITHOUT ANY WARRANTY; without even the implied warranty of
 *      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *      GNU General Public License for more details.
 *
 *      You should have received a copy of the GNU General Public License
 *      along with this program; if not, write to the Free Software
 *      Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
 *      MA 02110-1301, USA.
 */
require_once dirname(__FILE__) . '/common.php';
dgr_require('/includes/user.php');
dgr_startup();
try {
    $user = new DGradeUser();
    $style = dgr_get_style('.', $user->get_styleid());
} catch (Exception $e) {
    /* user not logged in */
    dgr_redirect('index.php');
}
if ($user->get_level() != 0) {
    die;
}
$users = dgr_get_users();
?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

<head>
Example #4
0
}
?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

<head>
	<title>DGrade - <?php 
echo gettext('starting page');
?>
</title>
	<meta http-equiv="content-type" content="text/html;charset=utf-8" />
	<meta name="generator" content="Geany 0.16" />
	<link type="text/css" rel="stylesheet" href="<?php 
echo dgr_get_style();
?>
" />
</head>

<body>
<div id="main">

<h1 class="header"><span class="rounded">DGrade</span></h1>

<?php 
if ($bad_login) {
    ?>
<h3 class="header error"><?php 
    echo $errmsg;
    ?>