Integrating Google AdSense with DNN 4.5.2 

DotNetNuke 4.5.2 has given us yet another great default function for our websites. Like many individuals I use Google AdSense to provide content based advertising to my users.  Traditionally to integrate Google Adsense you were forced to put a "Text/HTML" module on a page and then add the Javascript to either the source view of the editor, or to the header or footer of the module.  Well in DNN 4.5.2 the core team has added a "Google AdSense" module which makes the integration a breeze!  This article will walk you through the few short steps needed to configure the module and get you started!

Setup

Before you actually add the module to your page it is a good idea to setup your Google AdSense account and make note of your "AdSense ID:". If you have not created an account you may visit the Google AdSense site to setup your account.  The registration process is free and very simple!  Once you have logged in note your ID and then you may continue to configure the module.

Configuration

Now for the simple part, you need to configure your DNN installation to have an instance of the Google AdSense Module. Simply follow the below steps to complete the process.

  1. Select the "Google AdSense" module and the proper pane and click "Add" from the Control Panel
    Control panel
  2. Click the "Adsense Setup" link to configure the module
    Adsense Setup Link
  3. Enter your "AdSense ID" and choose your dispaly options (I used the Horizontal Letterboard Option), then click "Update" to save
    Adsense Settings
  4. Now, from the action menu open the module settings
  5. Expand the "Advanced Settings" section and check the "Display Module on All Pages" option, this will ensure that all regular content pages will have the advertisements displayed
    Advanced Module Settings
  6. Expand the "Page Settings" section and uncheck the "Display Container" and "Allow Print" options, this ensures that your ad's appear without the default module container
    Page Settings
  7. Click "Update" to save your changes.

This completes your setup for the AdSense module. One thing you want to note is that when you are logged in as the admin, you will still see the module container, even though other users will not. This is standard DNN behavior and is done to ensure you will always have access to the admin functions.

Posted by Mitchel on Wednesday, May 30, 2007
 

Comments

It seems that there is a problem with the "upgrade package" 4.5.5
It does not include some files for Google Adsense....
See complete thread on DNN forums:
http://www.dotnetnuke.com/Community/Forums/tabid/795/forumid/107/threadid/158762/scope/posts/Default.aspx

DV FX

By Déclic Vidéo FX on Monday, August 06, 2007 at 1:23 PM

Does this module compliant with the new Google Adsense feature: "PRODUCTS/Referrals" ????

DV FX

By Déclic Vidéo FX on Tuesday, October 30, 2007 at 10:39 AM

hey,
i added the Google adsense in as mentioned in ur blog , but my problem is that when i want to insert 2 google adsense module in one page , the 2nd module do not show any ads, it seems only one google adsense work with one google id, plz tell me how can i show 2 google ad sense in one page , or is there a way i can use one module 2wise in one page ,
plz reply
AHtesham

By ahtesham on Wednesday, January 14, 2009 at 8:10 AM

Is Adsense still available in the latest release of DNN? The install package I used didn't have the Adsense module.

By Joseph Allen on Wednesday, September 09, 2009 at 6:12 PM

Was this module dropped in 5.1.4 ? I can't seem to find it anywhere. Thank you.

By Jake on Monday, November 23, 2009 at 5:19 AM

Name (required)

Email (required)

Website

CAPTCHA image
Enter the code shown above:

Content provided in this blog is provided "AS-IS" and the information should be used at your own discretion.  The thoughts and opinions expressed are the personal thoughts of Mitchel Sellers and do not reflect the opinions of his employer.

Friend of RedGate

www.datasprings.com - DotNetNuke Modules ICG Hosting

Click here for advertising information.

Content in this blog is copyright protected.  Re-publishing on other websites is allowed as long as proper credit and backlink to the article is provided.  Any other re-publishing or distribution of this content is prohibited without written permission from Mitchel Sellers.