home *** CD-ROM | disk | FTP | other *** search
/ Cricao de Sites - 650 Layouts Prontos / WebMasters.iso / Servidores / xampp-win32-1.6.7-installer.exe / phpMyAdmin / libraries / server_common.inc.php < prev    next >
Encoding:
PHP Script  |  2008-06-23  |  1.3 KB  |  62 lines

  1. <?php
  2. /* vim: set expandtab sw=4 ts=4 sts=4: */
  3. /**
  4.  * @uses    PMA_generate_common_url()
  5.  * @uses    PMA_isSuperuser()
  6.  * @uses    PMA_DBI_select_db()
  7.  * @uses    PMA_DBI_fetch_result()
  8.  * @uses    PMA_DBI_QUERY_STORE
  9.  * @uses    $userlink
  10.  * @version $Id: server_common.inc.php 11326 2008-06-17 21:32:48Z lem9 $
  11.  */
  12. if (! defined('PHPMYADMIN')) {
  13.     exit;
  14. }
  15.  
  16. /**
  17.  * Gets some core libraries
  18.  */
  19. require_once './libraries/common.inc.php';
  20.  
  21. /**
  22.  * Handles some variables that may have been sent by the calling script
  23.  * Note: this can be called also from the db panel to get the privileges of
  24.  *       a db, in which case we want to keep displaying the tabs of
  25.  *       the Database panel
  26.  */
  27. if (empty($viewing_mode)) {
  28.     $db = $table = '';
  29. }
  30.  
  31. /**
  32.  * Set parameters for links
  33.  */
  34. $url_query = PMA_generate_common_url($db);
  35.  
  36. /**
  37.  * Defines the urls to return to in case of error in a sql statement
  38.  */
  39. $err_url = 'main.php' . $url_query;
  40.  
  41. /**
  42.  * Displays the headers
  43.  */
  44. require_once './libraries/header.inc.php';
  45.  
  46. /**
  47.  * @global boolean Checks for superuser privileges
  48.  */
  49. $is_superuser = PMA_isSuperuser();
  50.  
  51. // now, select the mysql db
  52. if ($is_superuser) {
  53.     PMA_DBI_select_db('mysql', $userlink);
  54. }
  55.  
  56. /**
  57.  * @global array binary log files
  58.  */
  59. $binary_logs = PMA_DBI_fetch_result('SHOW MASTER LOGS', 'Log_name', null, null,
  60.     PMA_DBI_QUERY_STORE);
  61. ?>
  62.