Changeset 3268 in subversion
- Timestamp:
- Feb 13, 2010 12:33:25 PM (3 years ago)
- Location:
- trunk/roundcubemail
- Files:
-
- 4 edited
-
index.php (modified) (1 diff)
-
program/include/rcmail.php (modified) (4 diffs)
-
program/include/rcube_plugin_api.php (modified) (1 diff)
-
program/steps/mail/func.inc (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/roundcubemail/index.php
r3258 r3268 31 31 require_once 'program/include/iniset.php'; 32 32 33 // init application and start session with requested task33 // init application, start session, init output class, etc. 34 34 $RCMAIL = rcmail::get_instance(); 35 36 // init output class37 $OUTPUT = !empty($_REQUEST['_remote']) ? $RCMAIL->init_json() : $RCMAIL->load_gui(!empty($_REQUEST['_framed']));38 39 // init plugin API40 $RCMAIL->plugins->init();41 35 42 36 // turn on output buffering -
trunk/roundcubemail/program/include/rcmail.php
r3258 r3268 131 131 $_SESSION['task'] = $this->task; 132 132 133 // create IMAP object 134 if ($this->task == 'login') 135 $this->imap_init(); 136 133 // init output class 134 if (!empty($_REQUEST['_remote'])) 135 $GLOBALS['OUTPUT'] = $this->init_json(); 136 else 137 $GLOBALS['OUTPUT'] = $this->load_gui(!empty($_REQUEST['_framed'])); 138 137 139 // create plugin API and load plugins 138 140 $this->plugins = rcube_plugin_api::get_instance(); 141 142 // init plugins 143 $this->plugins->init(); 139 144 } 140 145 … … 396 401 // set global object for backward compatibility 397 402 $GLOBALS['IMAP'] = $this->imap; 398 403 404 $hook = $this->plugins->exec_hook('imap_init', array('fetch_headers' => $this->imap->fetch_add_headers)); 405 if ($hook['fetch_headers']) 406 $this->imap->fetch_add_headers = $hook['fetch_headers']; 407 399 408 if ($connect) 400 409 $this->imap_connect(); … … 410 419 { 411 420 $conn = false; 421 422 if (!$this->imap) 423 $this->imap_init(); 412 424 413 425 if ($_SESSION['imap_host'] && !$this->imap->conn) { … … 494 506 if ($user = rcube_user::query($username, $host)) 495 507 $username = $user->data['username']; 508 509 if (!$this->imap) 510 $this->imap_init(); 496 511 497 512 // exit if IMAP login failed -
trunk/roundcubemail/program/include/rcube_plugin_api.php
r3258 r3268 151 151 152 152 // maybe also register a shudown function which triggers shutdown functions of all plugin objects 153 154 155 // call imap_init right now156 // (should actually be done in rcmail::imap_init() but plugins are not initialized then)157 if ($rcmail->imap) {158 $hook = $this->exec_hook('imap_init', array('fetch_headers' => $rcmail->imap->fetch_add_headers));159 if ($hook['fetch_headers'])160 $rcmail->imap->fetch_add_headers = $hook['fetch_headers'];161 }162 153 } 163 154 -
trunk/roundcubemail/program/steps/mail/func.inc
r3261 r3268 25 25 $NOIMAP_ACTIONS = array('spell', 'addcontact', 'autocomplete', 'upload', 'display-attachment', 'remove-attachment'); 26 26 27 // Init IMAP object28 $RCMAIL->imap_init();29 30 27 // log in to imap server 31 28 if (!in_array($RCMAIL->action, $NOIMAP_ACTIONS) && !$RCMAIL->imap_connect()) { … … 43 40 if ($mbox = get_input_value('_mbox', RCUBE_INPUT_GPC)) 44 41 $IMAP->set_mailbox(($_SESSION['mbox'] = $mbox)); 45 else 42 else if ($IMAP) 46 43 $_SESSION['mbox'] = $IMAP->get_mailbox_name(); 47 44
Note: See TracChangeset
for help on using the changeset viewer.
