Quote:
Originally Posted by FRDS
I'm not sure if this will work, but you can create a profile field call it Adsense Publisher Id, then put the adsense code in your template and replace the standard publisher id with $blog[fieldX].
|
This is something I have been looking into for sometime, however with one thing or another I have not yet got around to making it live. From what I have worked out so far a "mod" isn't really needed.
As you said you can use the fieldX value in the template for the product ID, however I think you also need the "google_ad_slot" and then some cunning way of managing width/height and ensuring that users don't insert a skycraper banner in the vertical slot.
Once you have that the only other thing you need to do is add a conditional statement that checks if the user has actually supplied a valid publisher id etc and if not revert back to the defaults for the site (or not display the banner at all)
The other complexity was brought in with 3.7 and the ad location templates, these are generic and used on all VB pages, so if you use these the conditional needs to check THIS_SCRIPT to make sure it is a blog page and not something else.
I was planning on doing is a regular expression check on the user fields (the default profile field manager supports this), again I never got around to finding out was the structure of the PID/Slot ID so I haven't got the regexes.
Obviously whatever is used in the end should never ever ever ever allow HTML to be embedded.
The final thing, is getting Google approval to do this.