Archive

Posts Tagged ‘adsense’

Text Link Ads!

April 3rd, 2007

Text Link ad is one of my favourite. I was very facinated by the text link ad code implemented by kontera
I think they are best in the industry. I wanted to develop something like that but couldn’t!!
Here I tried to parse html code so that my text link ad server can attach some specila effects to it(not like them).
One think you need for this is good knowledge of Javascript DOM. Lets Start!
You must add effects such that your basic design wont get affected,for that you shoukd exclude some basic html tags like ‘A’, ‘INPUT’ etc.
Lets define some html tags those must get ignored while parsing.

1
2
3
4
5
6
7
<pre lang="javascript" line="1">
var ignoredTags = new Array(
'!', 'A', 'BUTTON', 'HEAD', 'HTML', 
'INPUT', 'IMG','META', H1', 'H2', 
'H3', 'H4', 'H5', 'H6', 'OPTION',
'SCRIPT', 'SELECT', 'STYLE', 'TEXTAREA', 
'TITLE','XML');

and the function which check for ignored tags is
Read more…

Java Script , ,