aboutsummaryrefslogtreecommitdiffstats
path: root/mail/nocc
diff options
context:
space:
mode:
authorale <ale@FreeBSD.org>2005-10-08 03:18:26 +0800
committerale <ale@FreeBSD.org>2005-10-08 03:18:26 +0800
commit77eb1a0127eb3b53aca80206f55f52fc1a0af6f5 (patch)
treec6f3c05eb4fecb7d5187b67b36e705a600657246 /mail/nocc
parent52a2327be4a1e601fcab2b8fc409b5991e4dfc90 (diff)
downloadfreebsd-ports-gnome-77eb1a0127eb3b53aca80206f55f52fc1a0af6f5.tar.gz
freebsd-ports-gnome-77eb1a0127eb3b53aca80206f55f52fc1a0af6f5.tar.zst
freebsd-ports-gnome-77eb1a0127eb3b53aca80206f55f52fc1a0af6f5.zip
- Add support for php 5.0.5
- Add pcre and session dependencies - Bump PORTREVISION
Diffstat (limited to 'mail/nocc')
-rw-r--r--mail/nocc/Makefile3
-rw-r--r--mail/nocc/files/patch-action.php40
-rw-r--r--mail/nocc/files/patch-functions.php26
-rw-r--r--mail/nocc/files/patch-send.php32
4 files changed, 100 insertions, 1 deletions
diff --git a/mail/nocc/Makefile b/mail/nocc/Makefile
index 363c4ef42127..c80eb7939afc 100644
--- a/mail/nocc/Makefile
+++ b/mail/nocc/Makefile
@@ -7,6 +7,7 @@
PORTNAME= nocc
PORTVERSION= 0.9.7
+PORTREVISION= 1
CATEGORIES= mail www
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= ${PORTNAME}
@@ -15,7 +16,7 @@ DISTNAME= ${PORTNAME}-${PORTVERSION:S/.r/RC/}
MAINTAINER= ale@FreeBSD.org
COMMENT= A web-based e-mail system which access POP3 and IMAP mail servers
-USE_PHP= imap
+USE_PHP= imap pcre session
WANT_PHP_WEB= yes
PKGMESSAGE= ${WRKDIR}/pkg-message
diff --git a/mail/nocc/files/patch-action.php b/mail/nocc/files/patch-action.php
new file mode 100644
index 000000000000..08a00084fcaf
--- /dev/null
+++ b/mail/nocc/files/patch-action.php
@@ -0,0 +1,40 @@
+--- action.php.orig Thu Jun 30 07:34:45 2005
++++ action.php Fri Oct 7 21:01:29 2005
+@@ -77,7 +77,8 @@
+ if ($conf->display_img_attach && (eregi('image', $tmp['mime']) && ($tmp['number'] != '')))
+ {
+ // if it's an image, display it
+- $img_type = array_pop(explode('/', $tmp['mime']));
++ $exploded = explode('/', $tmp['mime']);
++ $img_type = array_pop($exploded);
+ if (eregi('JPEG', $img_type) || eregi('JPG', $img_type) || eregi('GIF', $img_type) || eregi ('PNG', $img_type))
+ {
+ echo '<hr />';
+@@ -156,10 +157,12 @@
+ if (isset($user_prefs->reply_leadin) && ($user_prefs->reply_leadin != ''))
+ {
+ $parsed_leadin = NOCCUserPrefs::parseLeadin($user_prefs->reply_leadin, $content);
+- $mail_body = mailquote(strip_tags($content['body'], ''), $parsed_leadin, '');
++ $stripped_content = strip_tags($content['body'], '');
++ $mail_body = mailquote($stripped_content, $parsed_leadin, '');
+ }
+ else
+- $mail_body = mailquote(strip_tags($content['body'], ''), $content['from'], $html_wrote);
++ $stripped_content = strip_tags($content['body'], '');
++ $mail_body = mailquote($stripped_content, $content['from'], $html_wrote);
+ }
+
+ // Add signature
+@@ -204,8 +207,10 @@
+ // Set body
+ if(isset($user_prefs->outlook_quoting) && $user_prefs->outlook_quoting)
+ $mail_body = $original_msg . "\n" . $html_from . ': ' . $content['from'] . "\n" . $html_to . ': ' . $content['to'] . "\n" . $html_sent.': ' . $content['complete_date'] . "\n" . $html_subject . ': '. $content['subject'] . "\n\n" . strip_tags2($content['body'], '');
+- else
+- $mail_body = mailquote(strip_tags2($content['body'], ''), $content['from'], $html_wrote);
++ else {
++ $stripped_content = strip_tags2($content['body'], '');
++ $mail_body = mailquote($stripped_content, $content['from'], $html_wrote);
++ }
+
+ // Add signature
+ add_signature($mail_body);
diff --git a/mail/nocc/files/patch-functions.php b/mail/nocc/files/patch-functions.php
new file mode 100644
index 000000000000..5480dbbd39f1
--- /dev/null
+++ b/mail/nocc/files/patch-functions.php
@@ -0,0 +1,26 @@
+--- functions.php 2005/09/13 19:19:36 1.207
++++ functions.php 2005/09/14 18:57:08 1.208
+@@ -45,9 +45,10 @@
+ {
+ $subject = $from = $to = '';
+ $msgnum = $sorted[$i];
+- $ref_contenu_message = $pop->headerinfo($pop->msgno($msgnum), $ev);
++ $pop_msgno_msgnum = $pop->msgno($msgnum);
++ $ref_contenu_message = $pop->headerinfo($pop_msgno_msgnum, $ev);
+ if(NoccException::isException($ev)) return;
+- $struct_msg = $pop->fetchstructure($pop->msgno($msgnum), $ev);
++ $struct_msg = $pop->fetchstructure($pop_msgno_msgnum, $ev);
+ if(NoccException::isException($ev)) return;
+ $subject_array = nocc_imap::mime_header_decode($ref_contenu_message->subject);
+ for ($j = 0; $j < count($subject_array); $j++)
+@@ -182,7 +183,9 @@
+ if ($struct_msg->type == 3 || (isset($struct_msg->parts) && (sizeof($struct_msg->parts) > 0)))
+ GetPart($attach_tab, $struct_msg, NULL, $conf->display_rfc822);
+ else {
+- GetSinglePart($attach_tab, $struct_msg, $pop->fetchheader($mail, $ev), $pop->body($mail, $ev));
++ $pop_fetchheader_mail_ev = $pop->fetchheader($mail, $ev);
++ $pop_body_mail_ev = $pop->body($mail, $ev);
++ GetSinglePart($attach_tab, $struct_msg, $pop_fetchheader_mail_ev, $pop_body_mail_ev);
+ if(NoccException::isException($ev)) return;
+ }
+
diff --git a/mail/nocc/files/patch-send.php b/mail/nocc/files/patch-send.php
new file mode 100644
index 000000000000..2cf598028427
--- /dev/null
+++ b/mail/nocc/files/patch-send.php
@@ -0,0 +1,32 @@
+--- send.php 2005/07/03 20:43:02 1.134
++++ send.php 2005/09/14 18:57:08 1.135
+@@ -102,7 +102,8 @@
+ $mail->smtp_server = $_SESSION['nocc_smtp_server'];
+ $mail->smtp_port = $_SESSION['nocc_smtp_port'];
+ $mail->charset = $charset;
+- $mail->from = cut_address(trim($mail_from), $charset);
++ $trim_mail_from = trim($mail_from);
++ $mail->from = cut_address($trim_mail_from, $charset);
+ $mail->from = $mail->from[0];
+ $mail->priority = $_REQUEST['priority'];
+ $mail->receipt = isset($_REQUEST['receipt']);
+@@ -110,13 +111,16 @@
+ // $ip = (getenv('HTTP_X_FORWARDED_FOR') ? getenv('HTTP_X_FORWARDED_FOR') : getenv('REMOTE_ADDR'));
+ // $mail->headers .= 'X-Originating-Ip: [' . $ip . ']' . $mail->crlf;
+ $mail->headers .= 'User-Agent: ' . $conf->nocc_name . ' <' . $conf->nocc_url . '>';
+- $mail->to = cut_address(trim($mail_to), $charset);
+- $mail->cc = cut_address(trim($mail_cc), $charset);
++ $trim_mail_to = trim($mail_to);
++ $trim_mail_cc = trim($mail_cc);
++ $mail->to = cut_address($trim_mail_to, $charset);
++ $mail->cc = cut_address($trim_mail_cc, $charset);
+ $user_prefs = $_SESSION['nocc_user_prefs'];
+ if(isset($user_prefs->cc_self) && $user_prefs->cc_self) {
+ array_unshift($mail->cc, $mail->from);
+ }
+- $mail->bcc = cut_address(trim($mail_bcc), $charset);
++ $trim_mail_bcc = trim($mail_bcc);
++ $mail->bcc = cut_address($trim_mail_bcc, $charset);
+ if ($mail_subject != '')
+ $mail->subject = trim($mail_subject);
+