Putting back SM_PATH the way it should be and eliminating chdir in the
[squirrelmail.git] / plugins / mail_fetch / setup.php
index 27c4b53b733c02f5c34c615a85bb37a04f749b81..1c27171951184c7d28629ee7ee9a0c503bc927d4 100644 (file)
@@ -11,7 +11,8 @@
     **  $Id$
     **/
 
     **  $Id$
     **/
 
-    require_once( '../plugins/mail_fetch/functions.php' );
+    define('SM_PATH','../../');
+    require_once(SM_PATH . 'plugins/mail_fetch/functions.php' );
 
     function squirrelmail_plugin_init_mail_fetch() {
         global $squirrelmail_plugin_hooks;
 
     function squirrelmail_plugin_init_mail_fetch() {
         global $squirrelmail_plugin_hooks;
     function mail_fetch_setnew()    {
 
         global $data_dir,$username;
     function mail_fetch_setnew()    {
 
         global $data_dir,$username;
-        // require_once ('../src/load_prefs.php');
-        // require_once ('../src/validate.php');
-        require_once('../functions/prefs.php');
+        require_once(SM_PATH . 'functions/prefs.php');
 
         if( $username <> '' ) {
             // Creates the pref file if it does not exist.
 
         if( $username <> '' ) {
             // Creates the pref file if it does not exist.