Xanga AdAs I was looking at the Xanga web html for some new (but not so new) skinning on my page, I realized that their ad system was changed. Somehow I never noticed it was placed on the side menu as opposed to the original top banner. I guess it's a better choice... for everyone. Hardly ever see it simply because of my logger code placement is generated on top of it... I win. But what's peculiar is the way the ad is generated. Now I'm a pretty curious person, so I like to challenge myself to remove "crap" in this case... the ad. There were several ad removers for the old Xanga ads and most aren't reliable as they are either not cross browser compatible or they just use some special mechanism to cover it up. I did manage to figure out a way to "remove" the old ad solving the cross browser issue while staying efficient. That means, the ad doesn't appear for one second then do a magic poof. Of course, I never released that code or even used it (sorry, but that was the "right" thing to do). Anyway, I'm sure there are already talented programmers out there that's figured out how to adblock for this ad. Although it shouldn't take a genius to figure this one out. The old ad generates the ads via a script placed near the end of a web page. Good choice (for xanga) because most script kiddies wouldn't know how to intercept that code when it comes only after all the user code / style is completed. Through the flow of how our browser retrieves and displays web data, there is no possible way to access/modify any code that comes afterwards, only the ones before hand. Therefore ways it could be done were to create some sort of timed script that will be executed. Or if one could figure out the tags to remove from css (which seemed impossible, at least from what I understood). Again, aesthetic fixes could also be done since the ad position never changes. So it follows a pathway:
xanga stuff >> user header >> xanga stuff >> user website stats >> generate ad But that was then, and this is now. So what's new? A stupid move by Xanga. I'm puzzled as to why they ever changed it. I mean, ads on the top would probably give them more income, granted that they did have some million users (if I'm not wrong). The current ad is "loaded" before all user code/styles. Again, out of users reach, but notice that it's only "loaded" before user custom data. It's actually generated after "some" user custom data... the header. What does that mean? This is what the pathway looks like now. xanga stuff >> prepare ad variables >> user header (cha ching) >> xanga stuff >> generate ad from variables >> xanga stuff >> user website stats Guess what? This means users can mingle with the variables before it gets sent the ad generator. It's kinda like abortion, except on a more "friendly" theme. All you have to do is flip the magic switch to false... <script> window.initAds = false; </script> If they are smart, they'd put the js file loading right before where it generates. Let's see how popular (or unpopular since I've deserted it for some time) my xanga site is and hopefully one of them will hop by this blog to learn a lesson. |