Wiki source for HideReferrers


Show raw source

===Hide referrer link to prevent spam===

[''Note: This is now included in Wikka by default starting with Wikka 1.1.3.1'']

A simple workaround discussed with DreckFehler (See comments in: WakkaWiki) to avoid massive linking from spambots. The link to the referrers page is only visible to registered users (and not to search engines). Make the following modification in ##footer.php##:

**original:**

%%(php)<a href="<?php echo $this->href("referrers") ?>"
title="Click to view a list of URLs referring to this page.">Referrers</a> ::
%%
**modified:**

%%(php)<?php echo ($this->GetUser() ? "<a href='".$this->href("referrers")."'>Referrers</a> :: " : "") ?>
%%

-- DarTar

Thanks. -- JsnX

----
Yeah, thanks a lot.

Additionally, I added

%%if ($this->GetUser()) {%%
to the top and

%%} else {
print("<em>You have to be logged in to access referrer information.</em>");
}%%
to the bottom (at the appropriate places, of course ;) of both referrers.php and referrers_sites.php (handlers/page/, Wakka 0.1.2) to generally prevent access to these pages for beings who are not logged in.

--RalfLehmann, 2004-08-07
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki