Index: trunk/kernel/units/email_events/email_events_event_handler.php =================================================================== diff -u -N -r3145 -r3391 --- trunk/kernel/units/email_events/email_events_event_handler.php (.../email_events_event_handler.php) (revision 3145) +++ trunk/kernel/units/email_events/email_events_event_handler.php (.../email_events_event_handler.php) (revision 3391) @@ -72,7 +72,7 @@ { trigger_error('Invalid email event name '.$email_event.'. Use only UPPERCASE characters and dots as email event names', E_USER_ERROR); } - + $to_user_id = $event->getEventParam('EmailEventToUserId'); $email_event_type = $event->getEventParam('EmailEventType'); @@ -119,8 +119,13 @@ $from_user_object = &$this->Application->recallObject('u.-email'.$from_user_id); $from_user_object->Load($from_user_id); // here if we don't have from_user loaded, it takes a default user from config values - $from_user_email = $from_user_object->GetDBField('Email') ? $from_user_object->GetDBField('Email') : $this->Application->ConfigValue('Smtp_AdminMailFrom'); - $from_user_name = trim($from_user_object->GetDBField('FirstName').' '.$from_user_object->GetDBField('LastName')); + if ( $from_user_object->IsLoaded() ) { + $from_user_email = $from_user_object->GetDBField('Email'); + $from_user_name = trim($from_user_object->GetDBField('FirstName').' '.$from_user_object->GetDBField('LastName')); + } + else { + $from_user_email = $this->Application->ConfigValue('Smtp_AdminMailFrom'); + } $to_user_object = &$this->Application->recallObject('u.-email'.$to_user_id); $to_user_object->Load($to_user_id); @@ -130,10 +135,10 @@ $this->Application->setUnitOption('u', 'AutoLoad', $old_autoload); if($direct_send_params){ - $to_user_email = ($direct_send_params['to_email']?$direct_send_params['to_email']:$to_user_email); - $to_user_name = ($direct_send_params['to_name']?$direct_send_params['to_name']:$to_user_name); - $from_user_email = ($direct_send_params['from_email']?$direct_send_params['from_email']:$from_user_email); - $from_user_name = ($direct_send_params['from_name']?$direct_send_params['from_name']:$from_user_name); + $to_user_email = ( $direct_send_params['to_email'] ? $direct_send_params['to_email'] : $to_user_email ); + $to_user_name = ( $direct_send_params['to_name'] ? $direct_send_params['to_name'] : $to_user_name ); + $from_user_email = ( $direct_send_params['from_email'] ? $direct_send_params['from_email'] : $from_user_email); + $from_user_name = ( $direct_send_params['from_name'] ? $direct_send_params['from_name'] : $from_user_name ); $message_body_additional = $direct_send_params['message']; } @@ -197,12 +202,12 @@ $event->status=erFAIL; } } - + if ($event->status == erSUCCESS){ if (!$from_user_name) { $from_user_name = strip_tags( $this->Application->ConfigValue('Site_Name') ); } - $sql = 'INSERT INTO '.TABLE_PREFIX.'EmailLog SET + $sql = 'INSERT INTO '.TABLE_PREFIX.'EmailLog SET fromuser = '.$this->Conn->qstr($from_user_name.' ('.$from_user_email.')').', addressto = '.$this->Conn->qstr($to_user_name.' ('.$to_user_email.')').', subject = '.$this->Conn->qstr($email_object->Subject).', Index: trunk/core/units/email_events/email_events_event_handler.php =================================================================== diff -u -N -r3145 -r3391 --- trunk/core/units/email_events/email_events_event_handler.php (.../email_events_event_handler.php) (revision 3145) +++ trunk/core/units/email_events/email_events_event_handler.php (.../email_events_event_handler.php) (revision 3391) @@ -72,7 +72,7 @@ { trigger_error('Invalid email event name '.$email_event.'. Use only UPPERCASE characters and dots as email event names', E_USER_ERROR); } - + $to_user_id = $event->getEventParam('EmailEventToUserId'); $email_event_type = $event->getEventParam('EmailEventType'); @@ -119,8 +119,13 @@ $from_user_object = &$this->Application->recallObject('u.-email'.$from_user_id); $from_user_object->Load($from_user_id); // here if we don't have from_user loaded, it takes a default user from config values - $from_user_email = $from_user_object->GetDBField('Email') ? $from_user_object->GetDBField('Email') : $this->Application->ConfigValue('Smtp_AdminMailFrom'); - $from_user_name = trim($from_user_object->GetDBField('FirstName').' '.$from_user_object->GetDBField('LastName')); + if ( $from_user_object->IsLoaded() ) { + $from_user_email = $from_user_object->GetDBField('Email'); + $from_user_name = trim($from_user_object->GetDBField('FirstName').' '.$from_user_object->GetDBField('LastName')); + } + else { + $from_user_email = $this->Application->ConfigValue('Smtp_AdminMailFrom'); + } $to_user_object = &$this->Application->recallObject('u.-email'.$to_user_id); $to_user_object->Load($to_user_id); @@ -130,10 +135,10 @@ $this->Application->setUnitOption('u', 'AutoLoad', $old_autoload); if($direct_send_params){ - $to_user_email = ($direct_send_params['to_email']?$direct_send_params['to_email']:$to_user_email); - $to_user_name = ($direct_send_params['to_name']?$direct_send_params['to_name']:$to_user_name); - $from_user_email = ($direct_send_params['from_email']?$direct_send_params['from_email']:$from_user_email); - $from_user_name = ($direct_send_params['from_name']?$direct_send_params['from_name']:$from_user_name); + $to_user_email = ( $direct_send_params['to_email'] ? $direct_send_params['to_email'] : $to_user_email ); + $to_user_name = ( $direct_send_params['to_name'] ? $direct_send_params['to_name'] : $to_user_name ); + $from_user_email = ( $direct_send_params['from_email'] ? $direct_send_params['from_email'] : $from_user_email); + $from_user_name = ( $direct_send_params['from_name'] ? $direct_send_params['from_name'] : $from_user_name ); $message_body_additional = $direct_send_params['message']; } @@ -197,12 +202,12 @@ $event->status=erFAIL; } } - + if ($event->status == erSUCCESS){ if (!$from_user_name) { $from_user_name = strip_tags( $this->Application->ConfigValue('Site_Name') ); } - $sql = 'INSERT INTO '.TABLE_PREFIX.'EmailLog SET + $sql = 'INSERT INTO '.TABLE_PREFIX.'EmailLog SET fromuser = '.$this->Conn->qstr($from_user_name.' ('.$from_user_email.')').', addressto = '.$this->Conn->qstr($to_user_name.' ('.$to_user_email.')').', subject = '.$this->Conn->qstr($email_object->Subject).', Index: trunk/admin/install/upgrades/readme_1_1_4.txt =================================================================== diff -u -N -r3108 -r3391 --- trunk/admin/install/upgrades/readme_1_1_4.txt (.../readme_1_1_4.txt) (revision 3108) +++ trunk/admin/install/upgrades/readme_1_1_4.txt (.../readme_1_1_4.txt) (revision 3391) @@ -1,4 +1,17 @@ -0009270 - Email events were sent to incorrect users -0007619 - Reset to base toolbar icon added for disabled button state (Stylesheets) -0009436 - Registration of user is broken (no in release), fixed. -0007193 - Block styles without base style were not saved during coping from Temp -> Live table +Readme notes for In-portal Platform 1.1.4 +Intechnic Corporation, December 23, 2005 + +This release has been solely focused on integrating In-portal with mod_rewrite. +The integration allows In-portal to generate and parse meaningful, +friendly URLs with no query string. Please consult the product manual +section 4.2.12. "URLs Structure & Mod_Rewrite" for more information. +A number of bug-fixes has also been included in this release. + +IMPORTANT: +Upgrade Notes + +After upgrading to this version, please open Administrative Console, +Structure & Data -> Catalog section and click +the 'Rebuild Category Cache' button (an icon with a folder and blue arrows between Approve and Cut icons). +Then go to Configuration -> Themes and click 'Rescan Themes' button (the last one in the toolbar). +These operations are critical before enabling mod_rewrite functionality. \ No newline at end of file