Skip to content

Commit

Permalink
use require() instead of include() when including file unconditionally
Browse files Browse the repository at this point in the history
  • Loading branch information
ruleant committed Sep 6, 2011
1 parent a1c9a65 commit a30554b
Show file tree
Hide file tree
Showing 12 changed files with 15 additions and 15 deletions.
2 changes: 1 addition & 1 deletion index.php
Expand Up @@ -69,7 +69,7 @@




// start output // start output
include './libraries/header_http.inc.php'; require './libraries/header_http.inc.php';
?> ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd"> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">
Expand Down
2 changes: 1 addition & 1 deletion libraries/engines/berkeleydb.lib.php
Expand Up @@ -7,7 +7,7 @@
/** /**
* Load BDB class. * Load BDB class.
*/ */
include_once './libraries/engines/bdb.lib.php'; require_once './libraries/engines/bdb.lib.php';


/** /**
* This is same as BDB. * This is same as BDB.
Expand Down
2 changes: 1 addition & 1 deletion libraries/engines/innobase.lib.php
Expand Up @@ -8,7 +8,7 @@
/** /**
* *
*/ */
include_once './libraries/engines/innodb.lib.php'; require_once './libraries/engines/innodb.lib.php';


/** /**
* *
Expand Down
2 changes: 1 addition & 1 deletion libraries/engines/mrg_myisam.lib.php
Expand Up @@ -7,7 +7,7 @@
/** /**
* *
*/ */
include_once './libraries/engines/merge.lib.php'; require_once './libraries/engines/merge.lib.php';


/** /**
* *
Expand Down
2 changes: 1 addition & 1 deletion libraries/schema/Dia_Relation_Schema.class.php
Expand Up @@ -5,7 +5,7 @@
* @package phpMyAdmin * @package phpMyAdmin
*/ */


include_once "Export_Relation_Schema.class.php"; require_once "Export_Relation_Schema.class.php";


/** /**
* This Class inherits the XMLwriter class and * This Class inherits the XMLwriter class and
Expand Down
2 changes: 1 addition & 1 deletion libraries/schema/Eps_Relation_Schema.class.php
Expand Up @@ -5,7 +5,7 @@
* @package phpMyAdmin * @package phpMyAdmin
*/ */


include_once "Export_Relation_Schema.class.php"; require_once "Export_Relation_Schema.class.php";


/** /**
* This Class is EPS Library and * This Class is EPS Library and
Expand Down
2 changes: 1 addition & 1 deletion pmd_display_field.php
Expand Up @@ -7,7 +7,7 @@
/** /**
* *
*/ */
include_once './libraries/pmd_common.php'; require_once './libraries/pmd_common.php';




$table = $T; $table = $T;
Expand Down
2 changes: 1 addition & 1 deletion pmd_pdf.php
Expand Up @@ -5,7 +5,7 @@
* @package phpMyAdmin-Designer * @package phpMyAdmin-Designer
*/ */


include_once './libraries/pmd_common.php'; require_once './libraries/pmd_common.php';


/** /**
* If called directly from the designer, first save the positions * If called directly from the designer, first save the positions
Expand Down
4 changes: 2 additions & 2 deletions pmd_relation_new.php
Expand Up @@ -8,9 +8,9 @@
/** /**
* *
*/ */
include_once './libraries/pmd_common.php'; require_once './libraries/pmd_common.php';
$die_save_pos = 0; $die_save_pos = 0;
include_once 'pmd_save_pos.php'; require_once 'pmd_save_pos.php';
extract($_POST, EXTR_SKIP); extract($_POST, EXTR_SKIP);


$tables = PMA_DBI_get_tables_full($db, $T1); $tables = PMA_DBI_get_tables_full($db, $T1);
Expand Down
4 changes: 2 additions & 2 deletions pmd_relation_upd.php
Expand Up @@ -8,11 +8,11 @@
/** /**
* *
*/ */
include_once './libraries/pmd_common.php'; require_once './libraries/pmd_common.php';
extract($_POST, EXTR_SKIP); extract($_POST, EXTR_SKIP);
extract($_GET, EXTR_SKIP); extract($_GET, EXTR_SKIP);
$die_save_pos = 0; $die_save_pos = 0;
include_once 'pmd_save_pos.php'; require_once 'pmd_save_pos.php';
list($DB1,$T1) = explode(".",$T1); list($DB1,$T1) = explode(".",$T1);
list($DB2,$T2) = explode(".",$T2); list($DB2,$T2) = explode(".",$T2);


Expand Down
2 changes: 1 addition & 1 deletion pmd_save_pos.php
Expand Up @@ -8,7 +8,7 @@
/** /**
* *
*/ */
include_once './libraries/pmd_common.php'; require_once './libraries/pmd_common.php';


$cfgRelation = PMA_getRelationsParam(); $cfgRelation = PMA_getRelationsParam();


Expand Down
4 changes: 2 additions & 2 deletions schema_export.php
Expand Up @@ -21,7 +21,7 @@


require_once './libraries/transformations.lib.php'; require_once './libraries/transformations.lib.php';
require_once './libraries/Index.class.php'; require_once './libraries/Index.class.php';
include_once "./libraries/schema/Export_Relation_Schema.class.php"; require_once "./libraries/schema/Export_Relation_Schema.class.php";


/** /**
* get all the export options and verify * get all the export options and verify
Expand All @@ -38,5 +38,5 @@
if (!file_exists('./libraries/schema/' . $path . '_Relation_Schema.class.php')) { if (!file_exists('./libraries/schema/' . $path . '_Relation_Schema.class.php')) {
PMA_Export_Relation_Schema::dieSchema($_POST['chpage'],$export_type,__('File doesn\'t exist')); PMA_Export_Relation_Schema::dieSchema($_POST['chpage'],$export_type,__('File doesn\'t exist'));
} }
include "./libraries/schema/".$path."_Relation_Schema.class.php"; require "./libraries/schema/".$path."_Relation_Schema.class.php";
$obj_schema = eval("new PMA_".$path."_Relation_Schema();"); $obj_schema = eval("new PMA_".$path."_Relation_Schema();");

0 comments on commit a30554b

Please sign in to comment.