homepage Welcome to WebmasterWorld Guest from
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Visit PubCon.com
Home / Forums Index / Google / Google AdSense
Forum Library, Charter, Moderators: incrediBILL & jatar k & martinibuster

Google AdSense Forum

How to detect if Adsense code is removed

 8:26 am on Nov 16, 2005 (gmt 0)

Hi guys,

I run a free hosting site with AdSense placed on all pages. Some users find ways of:

a) completely removing the adsense code
b) putting a javascript that stops the ads from loading
c) place their own adsense banners on the pages

I want to write a script/spider that can go through all the pages hosted by me and detect if "a" or "b" or "c" is being done.

Can someone give some suggestion?

How can I scan and locate pages which have tampered with the adsense code?

Thanks in advance!



 10:00 am on Nov 16, 2005 (gmt 0)

Best would be to give up this dangerouse business model.

You have no control against every sort of possible TOS violations.

Free homepages can have usual
* copyright problems offering MP3
* racist or related materials
* all other material prohibited by TOS

So I suggest to change to a stable long time business model with AdSense.


 12:35 pm on Nov 16, 2005 (gmt 0)

If you get booted from Adsense, it's _very_ hard to get back in, I believe.


 1:09 pm on Nov 16, 2005 (gmt 0)

jetteroheller and tigertom
what about if you have paid the free hosting services like geocities or angelfire by upgrating your membership so your site is free from there adds,is like your own site,right? so you can put adsense or any affiliate you like.That is why many free hosts offer an upgrade with the same money that will cost a hosting of a domain.


 1:25 pm on Nov 16, 2005 (gmt 0)

Well, I would guess that, as far as Google is concerned, you are responsible for the sites your code appears on, but I don't know.


 6:00 pm on Nov 16, 2005 (gmt 0)

I am not asking you about my business model, nor do I need your help with that.

If you don't have an answer to my question, don't post in this thread.



 6:10 pm on Nov 16, 2005 (gmt 0)

If you don't have an answer to my question, don't post in this thread.


Not really the best way to generate productive replies.

Anyway it's not clear what you're asking. You already laid out exactly what you need to do. Download one of the many free spiders available or run a script on your own server to locate all the web pages, then write a program in whatever programming language you wish to scan them. Certainly (a) and (c) should be trivial to detect. What part of this don't you know how to do?


 6:17 pm on Nov 16, 2005 (gmt 0)

I was going to answer your question, but after seeing your second response I've changed my mind.



 6:19 pm on Nov 16, 2005 (gmt 0)

I am not sure I grasp your current control over the pages.

Do you require each page to include a specific link or embed it? What type of pages, PHP, ASP, HTML?

If I had something like this, presuming all pages are HTML or PHP, all files are on hard drive(s), and my Adsense script is provided to the users as a "link" to an "include file", verses the complete script.

You can use a script to grep or cqp for the lack of Adsense link/code in each HTML/PHP/ASP/whatever file and pipe results into an other file. you can put this up as a cron job, and just sendmail the results to your mailbox.

[edited by: Tapolyai at 6:21 pm (utc) on Nov. 16, 2005]


 6:20 pm on Nov 16, 2005 (gmt 0)

cqp = Corpus Query Processor
grep = general regular expresssion parser


 6:51 pm on Nov 16, 2005 (gmt 0)

I am not asking you about my business model

But this business modell is exactly Your problem.

I suggest reading all the "I get banned" threads in this forum.

Global Options:
 top home search open messages active posts  

Home / Forums Index / Google / Google AdSense
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved