new faq
[phpmyadmin/crack.git] / index.php3
blob40dbd31a309d45bb17d6c6ba0d65f2604247fa41
1 <?php
2 /* $Id$ */
3 // vim: expandtab sw=4 ts=4 sts=4:
6 /**
7 * Gets core libraries and defines some variables
8 */
9 require('./libraries/grab_globals.lib.php3');
10 require('./libraries/common.lib.php3');
12 // Gets the default font sizes
13 PMA_setFontSizes();
15 // Gets the host name
16 // loic1 - 2001/25/11: use the new globals arrays defined with php 4.1+
17 if (empty($HTTP_HOST)) {
18 if (!empty($_ENV) && isset($_ENV['HTTP_HOST'])) {
19 $HTTP_HOST = $_ENV['HTTP_HOST'];
21 else if (!empty($HTTP_ENV_VARS) && isset($HTTP_ENV_VARS['HTTP_HOST'])) {
22 $HTTP_HOST = $HTTP_ENV_VARS['HTTP_HOST'];
24 else if (@getenv('HTTP_HOST')) {
25 $HTTP_HOST = getenv('HTTP_HOST');
27 else {
28 $HTTP_HOST = '';
33 /**
34 * Defines the frameset
36 // loic1: If left light mode -> urldecode the db name
37 if (isset($lightm_db)) {
38 $db = urldecode($lightm_db);
39 unset($lightm_db);
41 $url_query = PMA_generate_common_url(isset($db) ? $db : '');
43 header('Content-Type: text/html; charset=' . $GLOBALS['charset']);
45 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN"
46 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">
47 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $available_languages[$lang][2]; ?>" lang="<?php echo $available_languages[$lang][2]; ?>" dir="<?php echo $text_dir; ?>">
48 <head>
49 <title>phpMyAdmin <?php echo PMA_VERSION; ?> - <?php echo $HTTP_HOST; ?></title>
50 <meta http-equiv="Content-Type" content="text/html; charset=<?php echo $GLOBALS['charset']; ?>" />
51 <style type="text/css">
52 <!--
53 body {font-family: <?php echo $right_font_family; ?>; font-size: <?php echo $font_size; ?>}
54 //-->
55 </style>
56 </head>
58 <frameset cols="<?php echo $cfg['LeftWidth']; ?>,*" rows="*">
59 <frame src="left.php3?<?php echo $url_query; ?>" name="nav" frameborder="1" />
60 <frame src="<?php echo (empty($db)) ? 'main.php3' : $cfg['DefaultTabDatabase']; ?>?<?php echo $url_query; ?>" name="phpmain" />
62 <noframes>
63 <body bgcolor="#FFFFFF">
64 <p><?php echo $strNoFrames; ?></p>
65 </body>
66 </noframes>
67 </frameset>
69 </html>