Source for file appConfig.php

Documentation is available at appConfig.php

  1. <?php
  2. /**
  3. * Application settings
  4. *
  5. * Defines all application settings
  6. *
  7. * @package Sylar
  8. * @version 1.0
  9. * @since 15/feb/08
  10. * @author Gianluca Giusti [brdp] <g.giusti@giano-solutions.com>
  11. * @copyright Sylar Development Team
  12. */
  13.  
  14.  
  15. // Layout Config
  16. //______________________________________________________________________________
  17.  
  18.  
  19.  
  20. /**
  21. * Application Html pages default title
  22. */
  23. define('APP_HTML_TITLE', "Giano Application");
  24.  
  25.  
  26. /** Application default locale set */
  27.  
  28. define('APP_DEFAULT_LOCALE', 'en_EN');
  29.  
  30.  
  31. /**
  32. * Application default Character set
  33. */
  34. define('APP_DEFAULT_CHARSET', 'UTF-8');
  35.  
  36.  
  37.  
  38.  
  39.  
  40. // Sylar Framework Settings
  41. //______________________________________________________________________________
  42.  
  43.  
  44.  
  45.  
  46.  
  47. /**
  48. * Application name
  49. * The root directory of application.
  50. * for example: http://localhost/sylarApp/
  51. * the Application Name is "sylarApp" but if you ar working on domain you can leave blank
  52. * the costant: define('APPLICATION_NAME', "");
  53. * Remember the "/" at the end of the name!
  54. */
  55. define('SYLAR_APPLICATION_NAME', "sylarExampleApp/");
  56.  
  57. /**
  58. * Sylar folder name
  59. * Directory name of sylar framework
  60. * Remember the "/" at the end of the name!
  61. */
  62. define('SYLAR_FOLDER_NAME', "sylar/");
  63.  
  64. /**
  65. * Application Web Root
  66. * The http root directory of Application
  67. */
  68. define('SYLAR_APPLICATION_ROOT_URL', 'http://'.$_SERVER["SERVER_NAME"].':'.$_SERVER["SERVER_PORT"].'/'.SYLAR_APPLICATION_NAME);
  69.  
  70. /**
  71. * Application FileSystem Root
  72. * The root directory of Application on the FileSystem of the server
  73. */
  74. define('SYLAR_APPLICATION_ROOT_FS', ''.$_SERVER["DOCUMENT_ROOT"].'/'.SYLAR_APPLICATION_NAME);
  75.  
  76. /**
  77. * Sylar Web Root
  78. * The http root directory of Sylar Framework
  79. */
  80. define('SYLAR_ROOT_URL', SYLAR_APPLICATION_ROOT_URL.SYLAR_FOLDER_NAME);
  81.  
  82. /**
  83. * Sylar FileSystem Root
  84. * The root directory of Sylar Framework on the FileSystem of the server
  85. */
  86. define('SYLAR_ROOT_FS', SYLAR_APPLICATION_ROOT_FS.SYLAR_FOLDER_NAME);
  87.  
  88. /**
  89. * Application Classes root dir
  90. * The root directory of Application classes repository
  91. */
  92. define('SYLAR_APPLICATION_CLASSES_ROOT_FS', SYLAR_APPLICATION_ROOT_FS."exampleApp/classes/");
  93.  
  94. /**
  95. * Database Connection Config
  96. * Define all DB used in the application with Sylar and relative parameters.
  97. * Which one db is used by default from the list above
  98. */
  99. $SYLAR_DB["develop"] = array('username' => 'sylar', 'password' => 'sylar', 'schema' => 'sylarExampleDB', 'host'=> 'localhost', 'driver'=>'mysql');
  100. $SYLAR_DB["test"] = array('username' => 'db_user', 'password' => 'db_pwd', 'schema' => 'db_name', 'host'=> 'localhost', 'driver'=>'mysql');
  101. $SYLAR_DB["production"] = array('username' => 'db_user', 'password' => 'db_pwd', 'schema' => 'db_name', 'host'=> 'localhost', 'driver'=>'mysql');
  102.  
  103. define('SYLAR_USED_DB', 'develop');
  104.  
  105.  
  106.  
  107.  
  108.  
  109. // Application Settings
  110. //______________________________________________________________________________
  111.  
  112.  
  113.  
  114.  
  115.  
  116. /**
  117. * Application Javascript Repository
  118. * The URL root of repository
  119. */
  120. define('APP_JAVASCRIPT_URL_ROOT', SYLAR_APPLICATION_ROOT_URL.'exampleApp/javascript/');
  121.  
  122.  
  123. /**
  124. * Layout Template Name
  125. * the name is the same of directory in layouts folder
  126. */
  127. define('APP_LAYOUT_TEMPLATE', 'default');
  128.  
  129.  
  130. /**
  131. * Application Css Repository
  132. * The URL root of repository
  133. */
  134. define('APP_LAYOUT_CSS_URL_ROOT', SYLAR_APPLICATION_ROOT_URL.'exampleApp/layouts/'.APP_LAYOUT_TEMPLATE.'/css/');
  135.  
  136.  
  137. /**
  138. * Application Locale root on Filesystem
  139. * IT MUST BE DEFINED
  140. */
  141. define('APP_LOCALE_ROOT_FS', SYLAR_APPLICATION_ROOT_FS.'exampleApp/locale/');
  142.  
  143.  
  144.  
  145.  
  146.  
  147. // Ok! load the Sylar Framework!
  148. //______________________________________________________________________________
  149.  
  150.  
  151.  
  152. require_once SYLAR_ROOT_FS.'sylar_loader.php';
  153.  
  154. ?>

Documentation generated on Thu, 24 Apr 2008 16:14:13 +0200 by phpDocumentor 1.3.0RC3