home *** CD-ROM | disk | FTP | other *** search
/ Enter 2004 June / ENTER.ISO / files / xampp-win32-1.4.5-installer.exe / xampp / config_import.lib.php < prev    next >
Encoding:
PHP Script  |  2004-02-14  |  33.1 KB  |  1,281 lines

  1. <?php
  2. /* $Id: config_import.lib.php,v 2.5.2.1 2004/02/15 01:18:53 rabus Exp $ */
  3. // vim: expandtab sw=4 ts=4 sts=4:
  4.  
  5.  
  6. /**
  7.  * This file provides support for older config files.
  8.  */
  9.  
  10. /**
  11.  * U S A G E
  12.  *
  13.  * After having added a new directive to the config.inc.php file, you need to
  14.  * put some backwards compatibility code into this file.
  15.  *
  16.  * This usually looks like this:
  17.  *
  18.  * if (!isset($myNewDirective)) {
  19.  *     $myNewDirective = 'my default value';
  20.  * }
  21.  *
  22.  * If the new directive is meant as a replacement for an old one, please use the
  23.  * following layout:
  24.  *
  25.  * if (!isset($myNewDirective)) {
  26.  *     if (isset($myOldDirective)) {
  27.  *         $myNewDirective = $myOldDirective;
  28.  *         unset($myOldDirective);
  29.  *     } else {
  30.  *         $myNewDirective = '';
  31.  *     }
  32.  * }
  33.  *
  34.  * In order to make this file readable for other developers, please try to use
  35.  * the same order of directives here as you do in config.inc.php.
  36.  *
  37.  * After having done all this, search libraries/common.lib.php for the
  38.  * following paragraph (x and y are integers):
  39.  *
  40.  * if ($cfg['FileRevision'][0] < x || $cfg['FileRevision'][1] < y) {
  41.  *     require_once('./libraries/config_import.lib.php');
  42.  * }
  43.  *
  44.  * Finally, set x and y to the _new_ revision number of config.inc.php and
  45.  * you're done! x would be the major version, y the minor version number of the
  46.  * new revision, e.g. 2.34 becomes: x = 2, y = 34
  47.  */
  48.  
  49. if (!isset($cfg['PmaAbsoluteUri'])) {
  50.     if (isset($cfgPmaAbsoluteUri)) {
  51.         $cfg['PmaAbsoluteUri'] = $cfgPmaAbsoluteUri;
  52.         unset($cfgPmaAbsoluteUri);
  53.     } else {
  54.         $cfg['PmaAbsoluteUri'] = '';
  55.     }
  56. }
  57.  
  58. if (!isset($cfg['PmaAbsoluteUri_DisableWarning'])) {
  59.     $cfg['PmaAbsoluteUri_DisableWarning'] = FALSE;
  60. }
  61.  
  62. if (!isset($cfg['PmaNoRelation_DisableWarning'])) {
  63.     $cfg['PmaNoRelation_DisableWarning'] = FALSE;
  64. }
  65.  
  66. // do not set a default value here!
  67. if (!isset($cfg['blowfish_secret'])) {
  68.     $cfg['blowfish_secret'] = '';
  69. }
  70.  
  71. if (!isset($cfg['Servers'])) {
  72.     if (isset($cfgServers)) {
  73.         $cfg['Servers'] = $cfgServers;
  74.         unset($cfgServers);
  75.     } else {
  76.     $server = 0;
  77.     }
  78. }
  79.  
  80. if (isset($cfg['Servers'])) {
  81.     for ($i=1; (!empty($cfg['Servers'][$i]['host']) || (isset($cfg['Servers'][$i]['connect_type']) && $cfg['Servers'][$i]['connect_type'] == 'socket')); $i++) {
  82.         if (!isset($cfg['Servers'][$i]['host'])) {
  83.             $cfg['Servers'][$i]['host'] = '';
  84.         }
  85.         if (!isset($cfg['Servers'][$i]['port'])) {
  86.             $cfg['Servers'][$i]['port'] = '';
  87.         }
  88.  
  89.         if (!isset($cfg['Servers'][$i]['socket'])) {
  90.             $cfg['Servers'][$i]['socket'] = '';
  91.         }
  92.  
  93.         if (!isset($cfg['Servers'][$i]['connect_type'])) {
  94.             $cfg['Servers'][$i]['connect_type'] = 'tcp';
  95.         }
  96.  
  97.         if (!isset($cfg['Servers'][$i]['controluser']) && isset($cfg['Servers'][$i]['stduser'])) {
  98.             $cfg['Servers'][$i]['controluser'] = $cfg['Servers'][$i]['stduser'];
  99.             $cfg['Servers'][$i]['controlpass'] = $cfg['Servers'][$i]['stdpass'];
  100.             unset($cfg['Servers'][$i]['stduser'], $cfg['Servers'][$i]['stdpass']);
  101.         } else if (!isset($cfg['Servers'][$i]['controluser'])) {
  102.             $cfg['Servers'][$i]['controluser'] = $cfg['Servers'][$i]['controlpass'] = '';
  103.         }
  104.  
  105.         if (!isset($cfg['Servers'][$i]['auth_type'])) {
  106.             $cfg['Servers'][$i]['auth_type']  = (isset($cfg['Servers'][$i]['adv_auth']) && $cfg['Servers'][$i]['adv_auth'])
  107.                                          ? 'http'
  108.                                          : 'config';
  109.             unset($cfg['Servers'][$i]['adv_auth']);
  110.         }
  111.  
  112.         // for users who use the "first" blowfish mechanism
  113.         if (isset($cfg['Servers'][$i]['blowfish_secret'])) {
  114.             if (empty($cfg['blowfish_secret'])) {
  115.                 $cfg['blowfish_secret'] = $cfg['Servers'][$i]['blowfish_secret'];
  116.             }
  117.             unset($cfg['Servers'][$i]['blowfish_secret']);
  118.         }
  119.  
  120.         if (!isset($cfg['Servers'][$i]['compress'])) {
  121.             $cfg['Servers'][$i]['compress'] = FALSE;
  122.         }
  123.  
  124.         if (!isset($cfg['Servers'][$i]['user'])) {
  125.             $cfg['Servers'][$i]['user'] = 'root';
  126.         }
  127.  
  128.         if (!isset($cfg['Servers'][$i]['password'])) {
  129.             $cfg['Servers'][$i]['password'] = '';
  130.         }
  131.  
  132.         if (!isset($cfg['Servers'][$i]['only_db'])) {
  133.             $cfg['Servers'][$i]['only_db'] = '';
  134.         }
  135.  
  136.         if (!isset($cfg['Servers'][$i]['verbose'])) {
  137.             $cfg['Servers'][$i]['verbose'] = '';
  138.         }
  139.  
  140.         if (!isset($cfg['Servers'][$i]['pmadb'])) {
  141.             if (isset($cfg['Servers'][$i]['bookmarkdb'])) {
  142.                 $cfg['Servers'][$i]['pmadb'] = $cfg['Servers'][$i]['bookmarkdb'];
  143.                 unset($cfg['Servers'][$i]['bookmarkdb']);
  144.             } else {
  145.                 $cfg['Servers'][$i]['pmadb'] = '';
  146.             }
  147.         }
  148.  
  149.         if (!isset($cfg['Servers'][$i]['bookmarktable'])) {
  150.             $cfg['Servers'][$i]['bookmarktable'] = '';
  151.         }
  152.  
  153.         if (!isset($cfg['Servers'][$i]['relation'])) {
  154.             $cfg['Servers'][$i]['relation'] = '';
  155.         }
  156.  
  157.         if (!isset($cfg['Servers'][$i]['table_info'])) {
  158.             $cfg['Servers'][$i]['table_info'] = '';
  159.         }
  160.  
  161.         if (!isset($cfg['Servers'][$i]['table_coords'])) {
  162.             $cfg['Servers'][$i]['table_coords'] = '';
  163.         }
  164.  
  165.         if (!isset($cfg['Servers'][$i]['column_info'])) {
  166.             if (isset($cfg['Servers'][$i]['column_comments'])) {
  167.                 $cfg['Servers'][$i]['column_info'] = $cfg['Servers'][$i]['column_comments'];
  168.                 unset($cfg['Servers'][$i]['column_comments']);
  169.             } else {
  170.                 $cfg['Servers'][$i]['column_info'] = '';
  171.             }
  172.         }
  173.  
  174.         if (!isset($cfg['Servers'][$i]['pdf_pages'])) {
  175.             $cfg['Servers'][$i]['pdf_pages'] = '';
  176.         }
  177.  
  178.         if (!isset($cfg['Servers'][$i]['history'])) {
  179.             $cfg['Servers'][$i]['history'] = '';
  180.         }
  181.  
  182.         if (!isset($cfg['Servers'][$i]['verbose_check'])) {
  183.             $cfg['Servers'][$i]['verbose_check'] = TRUE;
  184.         }
  185.  
  186.         if (!isset($cfg['Servers'][$i]['AllowDeny'])) {
  187.             $cfg['Servers'][$i]['AllowDeny'] = array ('order' => '',
  188.                                                       'rules' => array());
  189.         }
  190.     }
  191. }
  192.  
  193. if (!isset($cfg['ServerDefault'])) {
  194.     if (isset($cfgServerDefault)) {
  195.         $cfg['ServerDefault'] = $cfgServerDefault;
  196.         unset($cfgServerDefault);
  197.     } else {
  198.         $cfg['ServerDefault'] = 1;
  199.     }
  200. }
  201.  
  202. if (!isset($cfg['OBGzip'])) {
  203.     if (isset($cfgOBGzip)) {
  204.         $cfg['OBGzip'] = $cfgOBGzip;
  205.         unset($cfgOBGzip);
  206.     } else {
  207.         $cfg['OBGzip'] = 'auto';
  208.     }
  209. }
  210.  
  211. if (!isset($cfg['PersistentConnections'])) {
  212.     if (isset($cfgPersistentConnections)) {
  213.         $cfg['PersistentConnections'] = $cfgPersistentConnections;
  214.         unset($cfgPersistentConnections);
  215.     } else {
  216.         $cfg['PersistentConnections'] = FALSE;
  217.     }
  218. }
  219.  
  220. if (!isset($cfg['ExecTimeLimit'])) {
  221.     if (isset($cfgExecTimeLimit)) {
  222.         $cfg['ExecTimeLimit'] = $cfgExecTimeLimit;
  223.         unset($cfgExecTimeLimit);
  224.     } else {
  225.         $cfg['ExecTimeLimit'] = 300;
  226.     }
  227. }
  228.  
  229. if (!isset($cfg['SkipLockedTables'])) {
  230.     if (isset($cfgSkipLockedTables)) {
  231.         $cfg['SkipLockedTables'] = $cfgSkipLockedTables;
  232.         unset($cfgSkipLockedTables);
  233.     } else {
  234.         $cfg['SkipLockedTables'] = FALSE;
  235.     }
  236. }
  237.  
  238. if (!isset($cfg['ShowSQL'])) {
  239.     if (isset($cfgShowSQL)) {
  240.         $cfg['ShowSQL'] = $cfgShowSQL;
  241.         unset($cfgShowSQL);
  242.     } else {
  243.         $cfg['ShowSQL'] = TRUE;
  244.     }
  245. }
  246.  
  247. if (!isset($cfg['AllowUserDropDatabase'])) {
  248.     if (isset($cfgAllowUserDropDatabase)) {
  249.         $cfg['AllowUserDropDatabase'] = $cfgAllowUserDropDatabase;
  250.         unset($cfgAllowUserDropDatabase);
  251.     } else {
  252.         $cfg['AllowUserDropDatabase'] = FALSE;
  253.     }
  254. }
  255.  
  256. if (!isset($cfg['Confirm'])) {
  257.     if (isset($cfgConfirm)) {
  258.         $cfg['Confirm'] = $cfgConfirm;
  259.         unset($cfgConfirm);
  260.     } else {
  261.         $cfg['Confirm'] = TRUE;
  262.     }
  263. }
  264.  
  265. if (!isset($cfg['LoginCookieRecall'])) {
  266.     if (isset($cfgLoginCookieRecall)) {
  267.         $cfg['LoginCookieRecall'] = $cfgLoginCookieRecall;
  268.         unset($cfgLoginCookieRecall);
  269.     } else {
  270.         $cfg['LoginCookieRecall'] = TRUE;
  271.     }
  272. }
  273.  
  274. if (!isset($cfg['UseDbSearch'])) {
  275.     $cfg['UseDbSearch'] = TRUE;
  276. }
  277.  
  278. if (!isset($cfg['IgnoreMultiSubmitErrors'])) {
  279.     $cfg['IgnoreMultiSubmitErrors'] = FALSE;
  280. }
  281.  
  282. if (!isset($cfg['VerboseMultiSubmit'])) {
  283.     $cfg['VerboseMultiSubmit'] = TRUE;
  284. }
  285.  
  286. if (!isset($cfg['AllowArbitraryServer'])) {
  287.     $cfg['AllowArbitraryServer'] = FALSE;
  288. }
  289.  
  290. if (!isset($cfg['LeftFrameLight'])) {
  291.     if (isset($cfgLeftFrameLight)) {
  292.         $cfg['LeftFrameLight'] = $cfgLeftFrameLight;
  293.         unset($cfgLeftFrameLight);
  294.     } else {
  295.         $cfg['LeftFrameLight'] = TRUE;
  296.     }
  297. }
  298.  
  299. if (!isset($cfg['LeftFrameTableSeparator'])) {
  300.     $cfg['LeftFrameTableSeparator'] = '__';
  301. }
  302.  
  303. if (!isset($cfg['LeftFrameTableLevel'])) {
  304.     $cfg['LeftFrameTableLevel'] = '1';
  305. }
  306.  
  307. if (!isset($cfg['LightTabs'])) {
  308.     $cfg['LightTabs'] = FALSE;
  309. }
  310.  
  311. if (!isset($cfg['PropertiesIconic'])) {
  312.     $cfg['PropertiesIconic'] = TRUE;
  313. }
  314.  
  315. if (!isset($cfg['PropertiesNumColumns'])) {
  316.     $cfg['PropertiesNumColumns'] = 1;
  317. }
  318.  
  319. if (!isset($cfg['ShowTooltip'])) {
  320.     if (isset($cfgShowTooltip)) {
  321.         $cfg['ShowTooltip'] = $cfgShowTooltip;
  322.     } else {
  323.         $cfg['ShowTooltip'] = TRUE;
  324.     }
  325. }
  326.  
  327. if (!isset($cfg['LeftDisplayLogo'])) {
  328.     $cfg['LeftDisplayLogo'] = TRUE;
  329. }
  330.  
  331. if (!isset($cfg['LeftDisplayServers'])) {
  332.     $cfg['LeftDisplayServers'] = FALSE;
  333. }
  334.  
  335. if (!isset($cfg['ShowStats'])) {
  336.     if (isset($cfgShowStats)) {
  337.         $cfg['ShowStats'] = $cfgShowStats;
  338.         unset($cfgShowStats);
  339.     } else {
  340.         $cfg['ShowStats'] = TRUE;
  341.     }
  342. }
  343.  
  344. if (!isset($cfg['ShowMysqlInfo'])) {
  345.     if (isset($cfgShowMysqlInfo)) {
  346.         $cfg['ShowMysqlInfo'] = $cfgShowMysqlInfo;
  347.         unset($cfgShowMysqlInfo);
  348.     } else {
  349.         $cfg['ShowMysqlInfo'] = FALSE;
  350.     }
  351. }
  352.  
  353. if (!isset($cfg['ShowMysqlVars'])) {
  354.     if (isset($cfgShowMysqlVars)) {
  355.         $cfg['ShowMysqlVars'] = $cfgShowMysqlVars;
  356.         unset($cfgShowMysqlVars);
  357.     } else {
  358.         $cfg['ShowMysqlVars'] = FALSE;
  359.     }
  360. }
  361.  
  362. if (!isset($cfg['ShowPhpInfo'])) {
  363.     if (isset($cfgShowPhpInfo)) {
  364.         $cfg['ShowPhpInfo'] = $cfgShowPhpInfo;
  365.         unset($cfgShowPhpInfo);
  366.     } else {
  367.         $cfg['ShowPhpInfo'] = FALSE;
  368.     }
  369. }
  370.  
  371. if (!isset($cfg['ShowChgPassword'])) {
  372.     if (isset($cfgShowChgPassword)) {
  373.         $cfg['ShowChgPassword'] = $cfgShowChgPassword;
  374.         unset($cfgShowChgPassword);
  375.     } else {
  376.         $cfg['ShowChgPassword'] = FALSE;
  377.     }
  378. }
  379.  
  380. if (!isset($cfg['SuggestDBName'])) {
  381.     $cfg['SuggestDBName'] = TRUE;
  382. }
  383.  
  384. if (!isset($cfg['ShowBlob'])) {
  385.     if (isset($cfgShowBlob)) {
  386.         $cfg['ShowBlob'] = $cfgShowBlob;
  387.         unset($cfgShowBlob);
  388.     } else {
  389.         $cfg['ShowBlob'] = FALSE;
  390.     }
  391. }
  392.  
  393. if (!isset($cfg['NavigationBarIconic'])) {
  394.     if (isset($cfgNavigationBarIconic)) {
  395.         $cfg['NavigationBarIconic'] = $cfgNavigationBarIconic;
  396.         unset($cfgNavigationBarIconic);
  397.     } else {
  398.         $cfg['NavigationBarIconic'] = TRUE;
  399.     }
  400. }
  401.  
  402. if (!isset($cfg['ShowAll'])) {
  403.     if (isset($cfgShowAll)) {
  404.         $cfg['ShowAll'] = $cfgShowAll;
  405.         unset($cfgShowAll);
  406.     } else {
  407.         $cfg['ShowAll'] = FALSE;
  408.     }
  409. }
  410.  
  411. if (!isset($cfg['MaxRows'])) {
  412.     if (isset($cfgMaxRows)) {
  413.         $cfg['MaxRows'] = $cfgMaxRows;
  414.         unset($cfgMaxRows);
  415.     } else {
  416.         $cfg['MaxRows'] = 30;
  417.     }
  418. }
  419.  
  420. if (!isset($cfg['Order'])) {
  421.     if (isset($cfgOrder)) {
  422.         $cfg['Order'] = $cfgOrder;
  423.         unset($cfgOrder);
  424.     } else {
  425.         $cfg['Order'] = 'ASC';
  426.     }
  427. }
  428.  
  429. if (!isset($cfg['ProtectBinary'])) {
  430.     if (isset($cfgProtectBinary)) {
  431.         $cfg['ProtectBinary'] = $cfgProtectBinary;
  432.         unset($cfgProtectBinary);
  433.     } else if (isset($cfg['ProtectBlob'])) {
  434.         $cfg['ProtectBinary']   = ($cfg['ProtectBlob'] ? 'blob' : FALSE);
  435.         unset($cfg['ProtectBlob']);
  436.     } else if (isset($cfgProtectBlob)) {
  437.         $cfg['ProtectBinary']   = ($cfgProtectBlob ? 'blob' : FALSE);
  438.         unset($cfgProtectBlob);
  439.     } else {
  440.         $cfg['ProtectBinary']   = 'blob';
  441.     }
  442. }
  443.  
  444. if (!isset($cfg['ShowFunctionFields'])) {
  445.     if (isset($cfgShowFunctionFields)) {
  446.         $cfg['ShowFunctionFields'] = $cfgShowFunctionFields;
  447.         unset($cfgShowFunctionFields);
  448.     } else {
  449.         $cfg['ShowFunctionFields'] = TRUE;
  450.     }
  451. }
  452.  
  453. if (!isset($cfg['CharEditing'])) {
  454.     $cfg['CharEditing'] = 'input';
  455. }
  456.  
  457. if (!isset($cfg['ZipDump'])) {
  458.     if (isset($cfgZipDump)) {
  459.         $cfg['ZipDump'] = $cfgZipDump;
  460.         unset($cfgZipDump);
  461.     } else {
  462.         $cfg['ZipDump'] = TRUE;
  463.     }
  464. }
  465.  
  466. if (!isset($cfg['GZipDump'])) {
  467.     if (isset($cfgGZipDump)) {
  468.         $cfg['GZipDump'] = $cfgGZipDump;
  469.         unset($cfgGZipDump);
  470.     } else {
  471.         $cfg['GZipDump'] = TRUE;
  472.     }
  473. }
  474.  
  475. if (!isset($cfg['BZipDump'])) {
  476.     if (isset($cfgBZipDump)) {
  477.         $cfg['BZipDump'] = $cfgBZipDump;
  478.         unset($cfgBZipDump);
  479.     } else {
  480.         $cfg['BZipDump'] = TRUE;
  481.     }
  482. }
  483. if (!isset($cfg['CompressOnFly'])) {
  484.     $cfg['CompressOnFly']         = TRUE;
  485. }
  486.  
  487. if (!isset($cfg['DefaultTabServer'])) {
  488.     $cfg['DefaultTabServer'] = 'main.php';
  489. }
  490.  
  491. if (!isset($cfg['DefaultTabDatabase'])
  492.     // rabus: config.inc.php rev. 1.112 had this default value.
  493.     || $cfg['DefaultTabDatabase'] == 'Structure') {
  494.     $cfg['DefaultTabDatabase'] = 'db_details_structure.php';
  495. }
  496.  
  497. if (!isset($cfg['DefaultTabTable'])
  498.     // rabus: config.inc.php rev. 1.112 had this default value.
  499.     || $cfg['DefaultTabTable'] == 'Structure') {
  500.     $cfg['DefaultTabTable'] = 'tbl_properties_structure.php';
  501. }
  502.  
  503. if (!isset($cfg['MySQLManualBase'])) {
  504.     if (isset($cfgManualBaseShort)) {
  505.         $cfg['MySQLManualBase'] = $cfgManualBaseShort;
  506.         $cfg['MySQLManualType'] = 'old';
  507.         unset($cfgManualBaseShort);
  508.     } else if (isset($cfg['ManualBaseShort'])) {
  509.         $cfg['MySQLManualBase'] = $cfg['ManualBaseShort'];
  510.         $cfg['MySQLManualType'] = 'old';
  511.         unset($cfg['ManualBaseShort']);
  512.     } else {
  513.         $cfg['MySQLManualBase'] = 'http://www.mysql.com/doc/en';
  514.         $cfg['MySQLManualType'] = 'searchable';
  515.     }
  516. }
  517.  
  518. if (!isset($cfg['MySQLManualType'])) {
  519.     $cfg['MySQLManualType'] = 'none';
  520. }
  521.  
  522. if (!isset($cfg['DefaultLang'])) {
  523.     if (isset($cfgDefaultLang)) {
  524.         $cfg['DefaultLang'] = $cfgDefaultLang;
  525.         unset($cfgDefaultLang);
  526.     } else {
  527.         $cfg['DefaultLang'] = 'en-iso-8859-1';
  528.     }
  529. }
  530.  
  531. if (!isset($cfg['DefaultCharset'])) {
  532.     $cfg['DefaultCharset'] = 'iso-8859-1';
  533. }
  534.  
  535. if (!isset($cfg['AllowAnywhereRecoding'])) {
  536.     $cfg['AllowAnywhereRecoding'] = FALSE;
  537. }
  538.  
  539. if (!isset($cfg['RecodingEngine'])) {
  540.     $cfg['RecodingEngine'] = 'auto';
  541. }
  542.  
  543. if (!isset($cfg['IconvExtraParams'])) {
  544.     $cfg['IconvExtraParams'] = '';
  545. }
  546.  
  547. if (!isset($cfg['Lang']) &&isset($cfgLang)) {
  548.     $cfg['Lang'] = $cfgLang;
  549.     unset($cfgLang);
  550. }
  551.  
  552. if (!isset($cfg['LeftWidth'])) {
  553.     if (isset($cfgLeftWidth)) {
  554.         $cfg['LeftWidth'] = $cfgLeftWidth;
  555.         unset($cfgLeftWidth);
  556.     } else {
  557.         $cfg['LeftWidth'] = 150;
  558.     }
  559. }
  560.  
  561. if (!isset($cfg['LeftBgColor'])) {
  562.     if (isset($cfgLeftBgColor)) {
  563.         $cfg['LeftBgColor'] = $cfgLeftBgColor;
  564.         unset($cfgLeftBgColor);
  565.     } else {
  566.         $cfg['LeftBgColor'] = '#D0DCE0';
  567.     }
  568. }
  569.  
  570. if (!isset($cfg['LeftPointerColor'])) {
  571.     if (isset($cfgLeftPointerColor)) {
  572.         $cfg['LeftPointerColor'] = $cfgLeftPointerColor;
  573.         unset($cfgLeftPointerColor);
  574.     } else {
  575.         $cfg['LeftPointerColor'] = '#CCFFCC';
  576.     }
  577. }
  578.  
  579. if (!isset($cfg['RightBgColor'])) {
  580.     if (isset($cfgRightBgColor)) {
  581.         $cfg['RightBgColor'] = $cfgRightBgColor;
  582.         unset($cfgRightBgColor);
  583.     } else {
  584.         $cfg['RightBgColor'] = '#F5F5F5';
  585.     }
  586. }
  587.  
  588. if (!isset($cfg['RightBgImage'])) {
  589.     $cfg['RightBgImage'] = '';
  590. }
  591.  
  592. if (!isset($cfg['Border'])) {
  593.     if (isset($cfgBorder)) {
  594.         $cfg['Border'] = $cfgBorder;
  595.         unset($cfgBorder);
  596.     } else {
  597.         $cfg['Border'] = 0;
  598.     }
  599. }
  600.  
  601. if (!isset($cfg['ThBgcolor'])) {
  602.     if (isset($cfgThBgcolor)) {
  603.         $cfg['ThBgcolor'] = $cfgThBgcolor;
  604.         unset($cfgThBgcolor);
  605.     } else {
  606.         $cfg['ThBgcolor'] = '#D3DCE3';
  607.     }
  608. }
  609.  
  610. if (!isset($cfg['BgcolorOne'])) {
  611.     if (isset($cfgBgcolorOne)) {
  612.         $cfg['BgcolorOne'] = $cfgBgcolorOne;
  613.         unset($cfgBgcolorOne);
  614.     } else {
  615.         $cfg['BgcolorOne'] = '#CCCCCC';
  616.     }
  617. }
  618.  
  619. if (!isset($cfg['BgcolorTwo'])) {
  620.     if (isset($cfgBgcolorTwo)) {
  621.         $cfg['BgcolorTwo'] = $cfgBgcolorTwo;
  622.         unset($cfgBgcolorTwo);
  623.     } else {
  624.         $cfg['BgcolorTwo'] = '#DDDDDD';
  625.     }
  626. }
  627.  
  628. if (!isset($cfg['BrowsePointerColor'])) {
  629.     if (isset($cfgBrowsePointerColor)) {
  630.         $cfg['BrowsePointerColor'] = $cfgBrowsePointerColor;
  631.         unset($cfgBrowsePointerColor);
  632.     } else {
  633.         $cfg['BrowsePointerColor'] = '#CCFFCC';
  634.     }
  635. }
  636.  
  637. if (!isset($cfg['BrowseMarkerColor'])) {
  638.     if (isset($cfgBrowseMarkerColor)) {
  639.         $cfg['BrowseMarkerColor'] = $cfgBrowseMarkerColor;
  640.         unset($cfgBrowseMarkerColor);
  641.     } else if (isset($cfg['BrowseMarkRow'])) {
  642.         $cfg['BrowseMarkerColor']   = (!empty($cfg['BrowsePointerColor']) && !empty($cfg['BrowseMarkRow']))
  643.                                       ? '#FFCC99'
  644.                                       : '';
  645.         unset($cfg['BrowseMarkRow']);
  646.     } else if (isset($cfgBrowseMarkRow)) {
  647.         $cfg['BrowseMarkerColor']   = (!empty($cfg['BrowsePointerColor']) && !empty($cfgBrowseMarkRow))
  648.                                       ? '#FFCC99'
  649.                                       : '';
  650.         unset($cfgBrowseMarkRow);
  651.     } else {
  652.         $cfg['BrowseMarkerColor'] = '#FFCC99';
  653.     }
  654. }
  655.  
  656. if (!isset($cfg['TextareaCols'])) {
  657.     if (isset($cfgTextareaCols)) {
  658.         $cfg['TextareaCols'] = $cfgTextareaCols;
  659.         unset($cfgTextareaCols);
  660.     } else {
  661.         $cfg['TextareaCols'] = 40;
  662.     }
  663. }
  664.  
  665. if (!isset($cfg['LongtextDoubleTextarea'])) {
  666.     $cfg['LongtextDoubleTextarea'] = TRUE;
  667. }
  668.  
  669. if (!isset($cfg['TextareaRows'])) {
  670.     if (isset($cfgTextareaRows)) {
  671.         $cfg['TextareaRows'] = $cfgTextareaRows;
  672.         unset($cfgTextareaRows);
  673.     } else {
  674.         $cfg['TextareaRows'] = 7;
  675.     }
  676. }
  677.  
  678. if (!isset($cfg['TextareaAutoSelect'])) {
  679.     $cfg['TextareaAutoSelect']  = TRUE;
  680. }
  681.  
  682. if (!isset($cfg['CharTextareaCols'])) {
  683.     $cfg['CharTextareaCols'] = 40;
  684. }
  685.  
  686. if (!isset($cfg['CharTextareaRows'])) {
  687.     $cfg['CharTextareaRows'] = 2;
  688. }
  689.  
  690. if (!isset($cfg['LimitChars'])) {
  691.     if (isset($cfgLimitChars)) {
  692.         $cfg['LimitChars'] = $cfgLimitChars;
  693.         unset($cfgLimitChars);
  694.     } else {
  695.         $cfg['LimitChars'] = 50;
  696.     }
  697. }
  698.  
  699. if (!isset($cfg['ModifyDeleteAtLeft'])) {
  700.     if (isset($cfgModifyDeleteAtLeft)) {
  701.         $cfg['ModifyDeleteAtLeft'] = $cfgModifyDeleteAtLeft;
  702.         unset($cfgModifyDeleteAtLeft);
  703.     } else {
  704.         $cfg['ModifyDeleteAtLeft'] = TRUE;
  705.     }
  706. }
  707.  
  708. if (!isset($cfg['ModifyDeleteAtRight'])) {
  709.     if (isset($cfgModifyDeleteAtRight)) {
  710.         $cfg['ModifyDeleteAtRight'] = $cfgModifyDeleteAtRight;
  711.         unset($cfgModifyDeleteAtRight);
  712.     } else {
  713.         $cfg['ModifyDeleteAtRight'] = FALSE;
  714.     }
  715. }
  716.  
  717. if (!isset($cfg['DefaultDisplay'])) {
  718.     if (isset($cfgDefaultDisplay)) {
  719.         $cfg['DefaultDisplay'] = $cfgDefaultDisplay;
  720.         unset($cfgDefaultDisplay);
  721.     } else {
  722.         $cfg['DefaultDisplay'] = 'horizontal';
  723.     }
  724. }
  725. if (!isset($cfg['DefaultPropDisplay'])) {
  726.     $cfg['DefaultPropDisplay'] = 'horizontal';
  727. }
  728.  
  729. if (!isset($cfg['RepeatCells'])) {
  730.     if (isset($cfgRepeatCells)) {
  731.         $cfg['RepeatCells'] = $cfgRepeatCells;
  732.         unset($cfgRepeatCells);
  733.     } else {
  734.         $cfg['RepeatCells'] = 100;
  735.     }
  736. }
  737.  
  738. if (!isset($cfg['HeaderFlipType'])) {
  739.     $cfg['HeaderFlipType'] = 'css';
  740. }
  741.  
  742. if (!isset($cfg['ShowBrowseComments'])) {
  743.     $cfg['ShowBrowseComments'] = TRUE;
  744. }
  745.  
  746. if (!isset($cfg['ShowPropertyComments'])) {
  747.     $cfg['ShowPropertyComments'] = TRUE;
  748. }
  749.  
  750. if (!isset($cfg['QueryFrame'])) {
  751.     $cfg['QueryFrame'] = TRUE;
  752. }
  753.  
  754. if (!isset($cfg['QueryFrameJS'])) {
  755.     $cfg['QueryFrameJS'] = TRUE;
  756. }
  757.  
  758. if (!isset($cfg['QueryFrameDebug'])) {
  759.     $cfg['QueryFrameDebug'] = FALSE;
  760. }
  761.  
  762. if (!isset($cfg['QueryWindowWidth'])) {
  763.     $cfg['QueryWindowWidth'] = 550;
  764. }
  765.  
  766. if (!isset($cfg['QueryWindowHeight'])) {
  767.     $cfg['QueryWindowHeight'] = 310;
  768. }
  769.  
  770. if (!isset($cfg['QueryHistoryMax'])) {
  771.     $cfg['QueryHistoryMax'] = 25;
  772. }
  773.  
  774. if (!isset($cfg['QueryHistoryDB'])) {
  775.     $cfg['QueryHistoryDB'] = FALSE;
  776. }
  777.  
  778. if (!isset($cfg['QueryWindowDefTab'])) {
  779.     $cfg['QueryWindowDefTab'] = 'sql';
  780. }
  781.  
  782. if (!isset($cfg['BrowseMIME'])) {
  783.     $cfg['BrowseMIME'] = TRUE;
  784. }
  785.  
  786. if (!isset($cfg['MaxExactCount'])) {
  787.     $cfg['MaxExactCount'] = 20000;
  788. }
  789.  
  790. if (!isset($cfg['WYSIWYG-PDF'])) {
  791.     $cfg['WYSIWYG-PDF'] = TRUE;
  792. }
  793.  
  794. if (!isset($cfg['DefaultQueryTable'])) {
  795.     $cfg['DefaultQueryTable'] = 'SELECT * FROM %t WHERE 1';
  796. }
  797.  
  798. if (!isset($cfg['DefaultQueryDatabase'])) {
  799.     $cfg['DefaultQueryDatabase']= '';
  800. }
  801.  
  802. if (!isset($cfg['ShowTooltipAliasDB'])) {
  803.     $cfg['ShowTooltipAliasDB'] = FALSE;
  804. }
  805.  
  806. if (!isset($cfg['ShowTooltipAliasTB'])) {
  807.     $cfg['ShowTooltipAliasTB'] = FALSE;
  808. }
  809.  
  810. if (!isset($cfg['SQLQuery']['Edit'])) {
  811.     $cfg['SQLQuery']['Edit'] = TRUE;
  812. }
  813.  
  814. if (!isset($cfg['SQLQuery']['Explain'])) {
  815.     $cfg['SQLQuery']['Explain'] = TRUE;
  816. }
  817.  
  818. if (!isset($cfg['SQLQuery']['ShowAsPHP'])) {
  819.     $cfg['SQLQuery']['ShowAsPHP'] = TRUE;
  820. }
  821.  
  822. if (!isset($cfg['SQLQuery']['Validate'])) {
  823.     $cfg['SQLQuery']['Validate'] = FALSE;
  824. }
  825.  
  826. if (!isset($cfg['UploadDir'])) {
  827.     $cfg['UploadDir'] = '';
  828. }
  829.  
  830. if (!isset($cfg['SaveDir'])) {
  831.     $cfg['SaveDir'] = '';
  832. }
  833.  
  834. if (!isset($cfg['docSQLDir'])) {
  835.     $cfg['docSQLDir'] = '';
  836. }
  837.  
  838. if (!isset($cfg['SQLValidator']['use'])) {
  839.     $cfg['SQLValidator']['use'] = FALSE;
  840. }
  841.  
  842. if (!isset($cfg['SQLValidator']['username'])) {
  843.     $cfg['SQLValidator']['username'] = '';
  844. }
  845.  
  846. if (!isset($cfg['SQLValidator']['password'])) {
  847.     $cfg['SQLValidator']['password'] = '';
  848. }
  849.  
  850. if (!isset($cfg['DBG']['enable'])) {
  851.     $cfg['DBG']['enable'] = FALSE;
  852. }
  853.  
  854. if (!isset($cfg['DBG']['profile']['enable'])) {
  855.     $cfg['DBG']['profile']['enable'] = FALSE;
  856. }
  857.  
  858. if (!isset($cfg['DBG']['profile']['threshold'])) {
  859.     $cfg['DBG']['profile']['threshold'] = 0.5;
  860. }
  861.  
  862. if (!isset($cfg['SQP']['fmtType'])) {
  863.     $cfg['SQP']['fmtType'] = 'html';
  864. }
  865.  
  866. if (!isset($cfg['SQP']['fmtInd'])) {
  867.     $cfg['SQP']['fmtInd'] = '1';
  868. }
  869.  
  870. if (!isset($cfg['SQP']['fmtIndUnit'])) {
  871.     $cfg['SQP']['fmtIndUnit'] = 'em';
  872. }
  873.  
  874. if (!isset($cfg['SQP']['fmtColor']['comment'])) {
  875.     $cfg['SQP']['fmtColor']['comment'] = '#808000';
  876. }
  877.  
  878. if (!isset($cfg['SQP']['fmtColor']['digit'])) {
  879.     $cfg['SQP']['fmtColor']['digit'] = '';
  880. }
  881.  
  882. if (!isset($cfg['SQP']['fmtColor']['digit_hex'])) {
  883.     $cfg['SQP']['fmtColor']['digit_hex'] = 'teal';
  884. }
  885.  
  886. if (!isset($cfg['SQP']['fmtColor']['digit_integer'])) {
  887.     $cfg['SQP']['fmtColor']['digit_integer'] = 'teal';
  888. }
  889.  
  890. if (!isset($cfg['SQP']['fmtColor']['digit_float'])) {
  891.     $cfg['SQP']['fmtColor']['digit_float'] = 'aqua';
  892. }
  893.  
  894. if (!isset($cfg['SQP']['fmtColor']['punct'])) {
  895.     $cfg['SQP']['fmtColor']['punct'] = 'fuchsia';
  896. }
  897.  
  898. if (!isset($cfg['SQP']['fmtColor']['alpha'])) {
  899.     $cfg['SQP']['fmtColor']['alpha'] = '';
  900. }
  901.  
  902. if (!isset($cfg['SQP']['fmtColor']['alpha_columnType'])) {
  903.     $cfg['SQP']['fmtColor']['alpha_columnType'] = '#FF9900';
  904. }
  905.  
  906. if (!isset($cfg['SQP']['fmtColor']['alpha_columnAttrib'])) {
  907.     $cfg['SQP']['fmtColor']['alpha_columnAttrib'] = '#0000FF';
  908. }
  909.  
  910. if (!isset($cfg['SQP']['fmtColor']['alpha_reservedWord'])) {
  911.     $cfg['SQP']['fmtColor']['alpha_reservedWord'] = '#990099';
  912. }
  913.  
  914. if (!isset($cfg['SQP']['fmtColor']['alpha_functionName'])) {
  915.     $cfg['SQP']['fmtColor']['alpha_functionName'] = '#FF0000';
  916. }
  917.  
  918. if (!isset($cfg['SQP']['fmtColor']['alpha_identifier'])) {
  919.     $cfg['SQP']['fmtColor']['alpha_identifier'] = 'black';
  920. }
  921.  
  922. if (!isset($cfg['SQP']['fmtColor']['alpha_charset'])) {
  923.     $cfg['SQP']['fmtColor']['alpha_charset'] = '#6495ed';
  924. }
  925.  
  926. if (!isset($cfg['SQP']['fmtColor']['alpha_variable'])) {
  927.     $cfg['SQP']['fmtColor']['alpha_variable'] = '#800000';
  928. }
  929.  
  930. if (!isset($cfg['SQP']['fmtColor']['quote'])) {
  931.     $cfg['SQP']['fmtColor']['quote'] = '#008000';
  932. }
  933.  
  934. if (!isset($cfg['SQP']['fmtColor']['quote_double'])) {
  935.     $cfg['SQP']['fmtColor']['quote_double'] = '';
  936. }
  937.  
  938. if (!isset($cfg['SQP']['fmtColor']['quote_single'])) {
  939.     $cfg['SQP']['fmtColor']['quote_single'] = '';
  940. }
  941.  
  942. if (!isset($cfg['SQP']['fmtColor']['quote_backtick'])) {
  943.     $cfg['SQP']['fmtColor']['quote_backtick'] = '';
  944. }
  945.  
  946. if (!isset($cfg['AvailableCharsets'])) {
  947.     $cfg['AvailableCharsets'] = array(
  948.         'iso-8859-1',
  949.         'iso-8859-2',
  950.         'iso-8859-3',
  951.         'iso-8859-4',
  952.         'iso-8859-5',
  953.         'iso-8859-6',
  954.         'iso-8859-7',
  955.         'iso-8859-8',
  956.         'iso-8859-9',
  957.         'iso-8859-10',
  958.         'iso-8859-11',
  959.         'iso-8859-12',
  960.         'iso-8859-13',
  961.         'iso-8859-14',
  962.         'iso-8859-15',
  963.         'windows-1250',
  964.         'windows-1251',
  965.         'windows-1252',
  966.         'windows-1256',
  967.         'windows-1257',
  968.         'koi8-r',
  969.         'big5',
  970.         'gb2312',
  971.         'utf-8',
  972.         'utf-7',
  973.         'x-user-defined',
  974.         'euc-jp',
  975.         'ks_c_5601-1987',
  976.         'tis-620',
  977.         'SHIFT_JIS'
  978.     );
  979. }
  980.  
  981. if (!isset($cfg['ColumnTypes'])) {
  982.     if (isset($cfgColumnTypes)) {
  983.         $cfg['ColumnTypes'] = $cfgColumnTypes;
  984.         unset($cfgColumnTypes);
  985.     } else {
  986.         $cfg['ColumnTypes'] = array(
  987.             'VARCHAR',
  988.             'TINYINT',
  989.             'TEXT',
  990.             'DATE',
  991.             'SMALLINT',
  992.             'MEDIUMINT',
  993.             'INT',
  994.             'BIGINT',
  995.             'FLOAT',
  996.             'DOUBLE',
  997.             'DECIMAL',
  998.             'DATETIME',
  999.             'TIMESTAMP',
  1000.             'TIME',
  1001.             'YEAR',
  1002.             'CHAR',
  1003.             'TINYBLOB',
  1004.             'TINYTEXT',
  1005.             'BLOB',
  1006.             'MEDIUMBLOB',
  1007.             'MEDIUMTEXT',
  1008.             'LONGBLOB',
  1009.             'LONGTEXT',
  1010.             'ENUM',
  1011.             'SET'
  1012.         );
  1013.     }
  1014. }
  1015.  
  1016. if (!isset($cfg['AttributeTypes'])) {
  1017.     if (isset($cfgAttributeTypes)) {
  1018.         $cfg['AttributeTypes'] = $cfgAttributeTypes;
  1019.         unset($cfgAttributeTypes);
  1020.     } else {
  1021.         $cfg['AttributeTypes'] = array(
  1022.            '',
  1023.            'BINARY',
  1024.            'UNSIGNED',
  1025.            'UNSIGNED ZEROFILL'
  1026.         );
  1027.     }
  1028. }
  1029.  
  1030. if ($cfg['ShowFunctionFields']) {
  1031.     if (!isset($cfg['Functions'])) {
  1032.         if (isset($cfgFunctions)) {
  1033.             $cfg['Functions'] = $cfgFunctions;
  1034.         } else {
  1035.             $cfg['Functions'] = array(
  1036.                'ASCII',
  1037.                'CHAR',
  1038.                'SOUNDEX',
  1039.                'LCASE',
  1040.                'UCASE',
  1041.                'NOW',
  1042.                'PASSWORD',
  1043.                'MD5',
  1044.                'ENCRYPT',
  1045.                'RAND',
  1046.                'LAST_INSERT_ID',
  1047.                'COUNT',
  1048.                'AVG',
  1049.                'SUM',
  1050.                'CURDATE',
  1051.                'CURTIME',
  1052.                'FROM_DAYS',
  1053.                'FROM_UNIXTIME',
  1054.                'PERIOD_ADD',
  1055.                'PERIOD_DIFF',
  1056.                'TO_DAYS',
  1057.                'UNIX_TIMESTAMP',
  1058.                'USER',
  1059.                'WEEKDAY',
  1060.                'CONCAT'
  1061.             );
  1062.         }
  1063.  
  1064.         // Which column types will be mapped to which Group?
  1065.         $cfg['RestrictColumnTypes'] = array(
  1066.            'VARCHAR'      => 'FUNC_CHAR',
  1067.            'TINYINT'      => 'FUNC_NUMBER',
  1068.            'TEXT'         => 'FUNC_CHAR',
  1069.            'DATE'         => 'FUNC_DATE',
  1070.            'SMALLINT'     => 'FUNC_NUMBER',
  1071.            'MEDIUMINT'    => 'FUNC_NUMBER',
  1072.            'INT'          => 'FUNC_NUMBER',
  1073.            'BIGINT'       => 'FUNC_NUMBER',
  1074.            'FLOAT'        => 'FUNC_NUMBER',
  1075.            'DOUBLE'       => 'FUNC_NUMBER',
  1076.            'DECIMAL'      => 'FUNC_NUMBER',
  1077.            'DATETIME'     => 'FUNC_DATE',
  1078.            'TIMESTAMP'    => 'FUNC_DATE',
  1079.            'TIME'         => 'FUNC_DATE',
  1080.            'YEAR'         => 'FUNC_DATE',
  1081.            'CHAR'         => 'FUNC_CHAR',
  1082.            'TINYBLOB'     => 'FUNC_CHAR',
  1083.            'TINYTEXT'     => 'FUNC_CHAR',
  1084.            'BLOB'         => 'FUNC_CHAR',
  1085.            'MEDIUMBLOB'   => 'FUNC_CHAR',
  1086.            'MEDIUMTEXT'   => 'FUNC_CHAR',
  1087.            'LONGBLOB'     => 'FUNC_CHAR',
  1088.            'LONGTEXT'     => 'FUNC_CHAR',
  1089.            'ENUM'         => '',
  1090.            'SET'          => ''
  1091.         );
  1092.  
  1093.         // Map above defined groups to any function
  1094.         $cfg['RestrictFunctions'] = array(
  1095.             'FUNC_CHAR'   => array(
  1096.                 'ASCII',
  1097.                 'CHAR',
  1098.                 'SOUNDEX',
  1099.                 'LCASE',
  1100.                 'UCASE',
  1101.                 'PASSWORD',
  1102.                 'MD5',
  1103.                 'ENCRYPT',
  1104.                 'LAST_INSERT_ID',
  1105.                 'USER',
  1106.                 'CONCAT'
  1107.             ),
  1108.  
  1109.             'FUNC_DATE'   => array(
  1110.                 'NOW',
  1111.                 'CURDATE',
  1112.                 'CURTIME',
  1113.                 'FROM_DAYS',
  1114.                 'FROM_UNIXTIME',
  1115.                 'PERIOD_ADD',
  1116.                 'PERIOD_DIFF',
  1117.                 'TO_DAYS',
  1118.                 'UNIX_TIMESTAMP',
  1119.                 'WEEKDAY'
  1120.             ),
  1121.  
  1122.             'FUNC_NUMBER' => array(
  1123.                 'ASCII',
  1124.                 'CHAR',
  1125.                 'MD5',
  1126.                 'ENCRYPT',
  1127.                 'RAND',
  1128.                 'LAST_INSERT_ID',
  1129.                 'COUNT',
  1130.                 'AVG',
  1131.                 'SUM'
  1132.             )
  1133.         );
  1134.     }
  1135.  
  1136.     if (!isset($cfg['DefaultFunctions'])) {
  1137.         $cfg['DefaultFunctions'] = array(
  1138.             'FUNC_CHAR'         => '',
  1139.             'FUNC_DATE'         => '',
  1140.             'FUNC_NUMBER'       => '',
  1141.             'first_timestamp'   => 'NOW'
  1142.         );
  1143.     }
  1144. }
  1145.  
  1146. if (!isset($cfg['GD2Available'])) {
  1147.     $cfg['GD2Available'] = 'auto';
  1148. }
  1149. if (!isset($cfg['PDFPageSizes'])) {
  1150.     $cfg['PDFPageSizes']        = array('A3', 'A4', 'A5', 'letter', 'legal');
  1151. }
  1152. if (!isset($cfg['PDFDefaultPageSize'])) {
  1153.     $cfg['PDFDefaultPageSize']  = 'A4';
  1154. }
  1155. if (!isset($cfg['CtrlArrowsMoving'])) {
  1156.     $cfg['CtrlArrowsMoving'] = TRUE;
  1157. }
  1158.  
  1159. if (!isset($cfg['Export']['format'])) {
  1160.     $cfg['Export']['format'] = 'sql';
  1161. } // sql/latex/excel/csv/xml
  1162. if (!isset($cfg['Export']['compression'])) {
  1163.     $cfg['Export']['compression'] = 'none';
  1164. } // none/zip/gzip/bzip2
  1165.  
  1166. if (!isset($cfg['Export']['asfile'])) {
  1167.     $cfg['Export']['asfile'] = FALSE;
  1168. }
  1169. if (!isset($cfg['Export']['onserver'])) {
  1170.     $cfg['Export']['onserver'] = FALSE;
  1171. }
  1172. if (!isset($cfg['Export']['onserver_overwrite'])) {
  1173.     $cfg['Export']['onserver_overwrite'] = FALSE;
  1174. }
  1175. if (!isset($cfg['Export']['remember_file_template'])) {
  1176.     $cfg['Export']['remember_file_template'] = TRUE;
  1177. }
  1178. if (!isset($cfg['Export']['csv_null'])) {
  1179.     $cfg['Export']['csv_null']                  = 'NULL';
  1180. }
  1181. if (!isset($cfg['Export']['csv_columns'])) {
  1182.     $cfg['Export']['csv_columns'] = FALSE;
  1183. }
  1184. if (!isset($cfg['Export']['excel_null'])) {
  1185.     $cfg['Export']['excel_null']                = 'NULL';
  1186. }
  1187. if (!isset($cfg['Export']['excel_columns'])) {
  1188.     $cfg['Export']['excel_columns'] = FALSE;
  1189. }
  1190. if (!isset($cfg['Export']['excel_edition'])) {
  1191.     $cfg['Export']['excel_edition'] = 'win';
  1192. }
  1193. if (!isset($cfg['Export']['latex_null'])) {
  1194.     $cfg['Export']['latex_null']                = '\textit{NULL}';
  1195. }
  1196. if (!isset($cfg['Export']['csv_separator'])) {
  1197.     $cfg['Export']['csv_separator'] = ';';
  1198. }
  1199. if (!isset($cfg['Export']['csv_enclosed'])) {
  1200.     $cfg['Export']['csv_enclosed'] = '"';
  1201. }
  1202. if (!isset($cfg['Export']['csv_escaped'])) {
  1203.     $cfg['Export']['csv_escaped'] = '\\';
  1204. }
  1205. if (!isset($cfg['Export']['csv_terminated'])) {
  1206.     $cfg['Export']['csv_terminated'] = 'AUTO';
  1207. }
  1208.  
  1209. if (!isset($cfg['Export']['latex_structure'])) {
  1210.     $cfg['Export']['latex_structure'] = TRUE;
  1211. }
  1212. if (!isset($cfg['Export']['latex_data'])) {
  1213.     $cfg['Export']['latex_data'] = TRUE;
  1214. }
  1215. if (!isset($cfg['Export']['latex_columns'])) {
  1216.     $cfg['Export']['latex_columns'] = TRUE;
  1217. }
  1218. if (!isset($cfg['Export']['latex_relation'])) {
  1219.     $cfg['Export']['latex_relation'] = TRUE;
  1220. }
  1221. if (!isset($cfg['Export']['latex_comments'])) {
  1222.     $cfg['Export']['latex_comments'] = TRUE;
  1223. }
  1224. if (!isset($cfg['Export']['latex_mime'])) {
  1225.     $cfg['Export']['latex_mime'] = TRUE;
  1226. }
  1227. if (!isset($cfg['Export']['latex_caption'])) {
  1228.     $cfg['Export']['latex_caption'] = TRUE;
  1229. }
  1230. if (!isset($cfg['Export']['latex_data_label'])) {
  1231.     $cfg['Export']['latex_data_label'] = 'tab:__TABLE__-data';
  1232. }
  1233. if (!isset($cfg['Export']['latex_structure_label'])) {
  1234.     $cfg['Export']['latex_structure_label'] = 'tab:__TABLE__-structure';
  1235. }
  1236.  
  1237. if (!isset($cfg['Export']['sql_drop_database'])) {
  1238.     $cfg['Export']['sql_drop_database'] = FALSE;
  1239. }
  1240. if (!isset($cfg['Export']['sql_drop_table'])) {
  1241.     $cfg['Export']['sql_drop_table'] = FALSE;
  1242. }
  1243. if (!isset($cfg['Export']['sql_auto_increment'])) {
  1244.     $cfg['Export']['sql_auto_increment'] = TRUE;
  1245. }
  1246. if (!isset($cfg['Export']['sql_structure'])) {
  1247.     $cfg['Export']['sql_structure'] = TRUE;
  1248. }
  1249. if (!isset($cfg['Export']['sql_data'])) {
  1250.     $cfg['Export']['sql_data'] = TRUE;
  1251. }
  1252. if (!isset($cfg['Export']['sql_backquotes'])) {
  1253.     $cfg['Export']['sql_backquotes'] = TRUE;
  1254. }
  1255. if (!isset($cfg['Export']['sql_dates'])) {
  1256.     $cfg['Export']['sql_dates'] = FALSE;
  1257. }
  1258. if (!isset($cfg['Export']['sql_relation'])) {
  1259.     $cfg['Export']['sql_relation'] = FALSE;
  1260. }
  1261. if (!isset($cfg['Export']['sql_columns'])) {
  1262.     $cfg['Export']['sql_columns'] = FALSE;
  1263. }
  1264. if (!isset($cfg['Export']['sql_delayed'])) {
  1265.     $cfg['Export']['sql_delayed'] = FALSE;
  1266. }
  1267. if (!isset($cfg['Export']['sql_type'])) {
  1268.     $cfg['Export']['sql_type'] = 'insert';
  1269. }
  1270. if (!isset($cfg['Export']['sql_extended'])) {
  1271.     $cfg['Export']['sql_extended'] = FALSE;
  1272. }
  1273. if (!isset($cfg['Export']['sql_comments'])) {
  1274.     $cfg['Export']['sql_comments'] = FALSE;
  1275. }
  1276. if (!isset($cfg['Export']['sql_mime'])) {
  1277.     $cfg['Export']['sql_mime'] = FALSE;
  1278. }
  1279.  
  1280. ?>
  1281.