You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

common.php 1.3KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. <?php
  2. // vim:ts=4:sw=4:et
  3. ini_set('include_path', get_include_path() . ':' . dirname(__FILE__));
  4. @include_once('Zend/Version.php');
  5. if (!class_exists('Zend_Version', false)) {
  6. die("Zend Framework not found. Please check the INSTALL File.");
  7. }
  8. chdir("..");
  9. if (!defined('SM_PATH')) {
  10. define('SM_PATH', '../');
  11. }
  12. include_once(dirname(__FILE__) . '/config.php');
  13. include_once(dirname(__FILE__) . '/functions.inc.php');
  14. include_if_exists(dirname(__FILE__) . '/../include/validate.php');
  15. if (file_exists(dirname(__FILE__) . '/../include/validate.php')) {
  16. include_once(dirname(__FILE__) . '/include/validate.php');
  17. } else {
  18. include_if_exists(SM_PATH . 'src/validate.php');
  19. }
  20. include_once(SM_PATH . 'functions/page_header.php');
  21. include_once(SM_PATH . 'functions/display_messages.php');
  22. include_once(SM_PATH . 'functions/imap.php');
  23. include_if_exists(SM_PATH . 'functions/array.php');
  24. if (file_exists(SM_PATH . 'src/load_prefs.php')) {
  25. include_once(SM_PATH . 'src/load_prefs.php');
  26. } else {
  27. include_if_exists(SM_PATH . 'include/load_prefs.php');
  28. }
  29. // overwrite squirrelmail's content type to utf8...
  30. header("Content-Type: text/html; charset=utf8");
  31. //global $VACCONFMESSAGE;
  32. bindtextdomain('postfixadmin', dirname(__FILE__) . '/postfixadmin/locale');
  33. textdomain('postfixadmin');