[thelist] Block a Referring URL

VOLKAN ÖZÇELİK volkan.ozcelik at gmail.com
Fri Mar 10 14:36:15 CST 2006

Here is something I do in my Global.asax for a similar task
(a site was mirroring all my content and was demonstrating it as it was theirs.
possibly opening a low level TCP connection, sucking all the data and
pushing it to their site)

protected void Application_BeginRequest(object sender, EventArgs e)
	/*get the url of the request*/
	string url=Converter.ToLowerCaseURL(Request.Url.ToString());
		url.IndexOf("example.com")==-1 &&
		url.IndexOf("example.net")==-1 &&
		url.IndexOf("example.org")==-1 &&
		url.IndexOf("xxx.xxx.xxx.xxx")==-1 /*the static IP of the site*/

Begin_Request is called on each and every request as its name implies.

I don't know how it translates into PHP but I think it kinda solves
your problem.

Does that make sense?

Volkan Ozcelik
+>Yep! I'm blogging! : http://www.volkanozcelik.com/volkanozcelik/blog/
+> My projects/studies/trials/errors : http://www.sarmal.com/

More information about the thelist mailing list