From 74b61ee2d7f133e6ebc1d1e61866bd164a8af0af Mon Sep 17 00:00:00 2001 From: x99bachelart Date: Sun, 28 Sep 2003 12:09:58 +0000 Subject: [PATCH] signatures are dropped in replies --- install.d/profile.inc.php | 1 + post.php | 7 ++++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/install.d/profile.inc.php b/install.d/profile.inc.php index b61e863..7d62c5e 100644 --- a/install.d/profile.inc.php +++ b/install.d/profile.inc.php @@ -32,6 +32,7 @@ function getprofile() { $array['lastnews'] = time()-86400; $array['locale'] = "locales/fr.inc.php"; $array['subscribe'] = array(); + $array['dropsig'] = true; return $array; } ?> diff --git a/post.php b/post.php index 2a00705..fe848f2 100644 --- a/post.php +++ b/post.php @@ -48,7 +48,12 @@ if (isset($group) && isset($id) && isset($_REQUEST['type']) && if ($post) { $subject = (preg_match("/^re:/i",$post->headers->subject)?"":"Re: ") .$post->headers->subject; - $body = $post->headers->name." wrote :\n".wrap($post->body, ">"); + if ($profile['dropsig']) { + $quotetext = preg_replace("/^(.*)\n-- \n.*$/m","\1",$post->body); + } else { + $quotetext = $post->body; + } + $body = $post->headers->name." wrote :\n".wrap($quotetext, "> "); if (isset($post->headers->followup)) $target=$post->headers->followup; else -- 2.1.4