🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: rocksolid.nodes.announce
Article #38

Re: New default theme for def3

#38
From: trw
Date: Mon, 11 Nov 2019 20:16
23 lines
2097 bytes
ok, fixed the color as well. the function is in scripts_common.inc, the new function is this:

/** Apply different colors to different levels of quoted text. */
function color_quotes($body, $forum_opt)
{
	$body = str_replace("\r\n", PHP_EOL, $body);	// Get rid of carriage returns on non-Windows systems.

	if ($forum_opt & 16) {	// BBCode tag style.
		$body = preg_replace('/^>\h*>\h*>\h*>(.*)$/m', '>>>> \1',  $body);
		$body = preg_replace('/^>\h*>\h*>(.*)$/m',     '>>> \1', $body);
		$body = preg_replace('/^>\h*>(.*)$/m',         '>> \1',       $body);
		$body = preg_replace('/^>(.*)$/m',             '> \1',        $body);
	} else if (!($forum_opt & 8)) {	// Tag style is not NONE (thus, HTML).
		$body = preg_replace('/^>\h*>\h*>\h*>(.*)$/m', '<font color="mintcream"> >>>> \1</font>', $body);
		$body = preg_replace('/^>\h*>\h*>(.*)$/m',     '<font color="lightsteelblue"> >>> \1</font>',   $body);
		$body = preg_replace('/^>\h*>(.*)$/m',         '<font color="lightblue"> >> \1</font>',            $body);
		$body = preg_replace('/^>(.*)$/m',             '<font color="cornflowerblue"> > \1</font>',                $body);
	}

	return $body;
}

Posted on def3
Technical Details
Message-ID: <qqcfi8$eud$1@i2pn2.org>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!archive!apf9.newsdeef.eu!i2pn2.org!.POSTED!not-for-mail
References: <qqce6t$cr5$1@i2pn2.org>

Show Full Headers
Complete Article Headers
Message-ID: <qqcfi8$eud$1@i2pn2.org>
Subject: Re: New default theme for def3
Date: Mon, 11 Nov 2019 15:16:08 -0500
From: trw <trw@i2pmail.org>
References: <qqce6t$cr5$1@i2pn2.org>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!archive!apf9.newsdeef.eu!i2pn2.org!.POSTED!not-for-mail
Newsgroups: rocksolid.nodes.announce
Organization: Dancing elephants
Lines: 21
Reply-To: trw <trw@i2pmail.org>
Mime-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Date: Mon, 11 Nov 2019 20:16:09 -0000 (UTC)
Injection-Info: i2pn2.org; posting-account="def.i2p";
 logging-data="15309"; mail-complaints-to="usenet@i2pn2.org"
User-Agent: FUDforum 3.0.7
X-FUDforum: 6666cd76f96956469e7be39d750cc7d9 <126914>