X-Git-Url: https://vcs.fsf.org/?p=squirrelmail.git;a=blobdiff_plain;f=plugins%2Fabook_take%2Fsetup.php;h=768c5d468f562fcc4e61aed1d1baddb89fc216b9;hp=1130d9241e39649c81bca9203783eb5a4fa043c0;hb=4b4abf93a9624311afef0c385023724ee46a2b60;hpb=08185f2a7631c3a12cb1ac085fec3be471b56b00 diff --git a/plugins/abook_take/setup.php b/plugins/abook_take/setup.php index 1130d924..768c5d46 100755 --- a/plugins/abook_take/setup.php +++ b/plugins/abook_take/setup.php @@ -1,206 +1,62 @@ \n"; - $abook_found_email[$hits[0]] = 1; - } - } - return; + abook_take_read(); } +function abook_take_loading_prefs() { + include_once(SM_PATH . 'plugins/abook_take/functions.php'); -function abook_take_read_array($array) -{ - $i = 0; - while ($i < count($array)) - { - abook_take_read_string($array[$i]); - $i ++; - } + abook_take_pref(); } +function abook_take_options_display_inside() { + include_once(SM_PATH . 'plugins/abook_take/functions.php'); -function abook_take_read() -{ - global $color, $abook_take_location; - global $body, $abook_take_hide, $message, $imapConnection; - - if ($abook_take_hide) - return; - - echo '
' . "\n" . - html_tag( 'table', '', $abook_take_location, $color[10], 'cellpadding="3" cellspacing="0" border="0"' ) . - html_tag( 'tr' ) . - html_tag( 'td', '', 'left' ) . - html_tag( 'table', '', '', $color[5], 'cellpadding="2" cellspacing="1" border="0"' ) . - html_tag( 'tr' ) . - html_tag( 'td' ); - - abook_take_read_string($message->header->from); - abook_take_read_array($message->header->cc); - abook_take_read_array($message->header->reply_to); - abook_take_read_array($message->header->to); - - - $new_body = $body; - $pos = strpos($new_body, - '">' . _("Download this as a file") . '
'); - if (is_int($pos)) - { - $new_body = substr($new_body, 0, $pos); - } - - $trans = get_html_translation_table(HTML_ENTITIES); - $trans[' '] = ' '; - $trans = array_flip($trans); - $new_body = strtr($new_body, $trans); - - $new_body = urldecode($new_body); - $new_body = strip_tags($new_body); - - $new_body = strtr($new_body, "\n", ' '); - - abook_take_read_string($body); - - echo ''; - ?> - - - - - - -
- ' . - '' . - '' . - '' . - ' ' . _("on the Read screen") .'
' . - ' ' . _("Hide the box") . '
' . - ' ' . _("Try to verify addresses") . ''; -} - - -function abook_take_save() -{ - global $username, $data_dir; - global $abook_take_abook_take_location; - global $abook_take_abook_take_hide; - global $abook_take_abook_take_verify; - - - if (isset($abook_take_abook_take_location)) - { - setPref($data_dir, $username, 'abook_take_location', $abook_take_abook_take_location); - } - else - { - setPref($data_dir, $username, 'abook_take_location', 'center'); - } - - if (isset($abook_take_abook_take_hide)) - { - setPref($data_dir, $username, 'abook_take_hide', '1'); - } - else - { - setPref($data_dir, $username, 'abook_take_hide', ''); - } +function abook_take_options_display_save() { + include_once(SM_PATH . 'plugins/abook_take/functions.php'); - if (isset($abook_take_abook_take_verify)) - { - setPref($data_dir, $username, 'abook_take_verify', '1'); - } - else - { - setPref($data_dir, $username, 'abook_take_verify', ''); - } + abook_take_save(); } -?> +?> \ No newline at end of file