AdSense Widget for WordPress Sidebar
April 1st, 2006
This is a Google AdSense widget I designed for the new WordPress Sidebar Widgets plug-in.
However, as a loyal reader has lovingly pointed out, if you want AdSense or any other kind of JavaScript component added to your sidebar all you need to do is paste it inside the standard Text Widgets that come built-in with Automattic's Sidebar Widgets plugin!
Unbelievably easy! And all this work for nothing. However, for fun I have left the original plugin up here in case you were interested in how I made the plugin.
Thanks to the people at Automattic, it is easy to install and requires no coding or template modification.
The Color, size and h2 title of your AdSense widget are all fully customizable from within the WordPress Presentations tab. No joke!
Requires:
Wordpress Sidebar Widgets Plugin
Download:
Here are the installation instructions...
Installation:
- Unzip and upload to your /wp-content/plugins/ directory
- Activate the plugin from inside WordPress (Plugins tab)
- Drag AdSense widget to your sidebar from inside WordPress (Presentation tab > Sidebar Widgets)
- Click the configuration icon and enter your google_ad_client ID
- Optional: customize the color, size, and sidebar h2 title
That's it! Enjoy.
In our daily life computers and software have gained integral position. Most of our professions are unimaginable without computer software running at its core. In last decade software industry has become the largest of all. Especially the web hosting business has flourished with the internet. Many cheap webhosting services are available to overcome digital divide created by this rapid advancement. As an effect of this growth a webhost firm is now under much pressure to provide quality services to large spectrum of clients.
Posted in: WordPress Plugins














April 25th, 2006 at 02:47 AM
Great! It would be even more powerful if it could be configured to not show ads depending on the current referred; eg. only show ads to people who have been referred by a website.
April 25th, 2006 at 15:52 PM
Everything looks good, but seems to break under PHP5. It's the array_merge() function, which broke a couple of my scripts when upgrading. I had to change line #78 from: $options = array_merge(widget_adsense_options(), get_option('widget_adsense')); to: $wadsense = get_option('widget_adsense'); $options = array_merge(widget_adsense_options(), array($wadsense)); And then everything worked fine. - Sean
April 19th, 2006 at 14:59 PM
[...] I was just about to start building an AdSense widget for Wordpress and thought I should take a quick look on the web to see if anyone beat me to the punch. Sure enough, Mike Smullin did. If you are looking for a clean and easy AdSense widget, this is the one to get. [...]
June 11th, 2006 at 08:41 AM
Hi The widget works fine, but it won't work when I have the Adsense-Deluxe (http://www.acmetech.com/blog/adsense-deluxe/) plugin activated. Any solution? G
June 11th, 2006 at 15:44 PM
Google limits you to a maximum of 3 AdSense blocks on a single page. If you embed AdSense code into your templates, this counts against the 3 unit maximum, and sometimes Google simply doesn’t have enough ads for your content, so you’ll get empty space in your pages unless you use AdSense’s features for showing alternate ads or folding the empty blocks. If my plugin doesn't work, try using those Text Widgets I mentioned above, instead. Also remember: the more AdSense ads you display on the page, the cheaper ads you get.
June 26th, 2006 at 23:49 PM
[...] Mike Smullin also made an AdSense widget. While it’s already possible for self-hosted blog admins to paste AdSense code into a Text widget, this might be a little bit nicer as it lets you customize color, size and title from the widget panel. [...]
July 5th, 2006 at 15:22 PM
[...] AdSense Widget for WordPress Sidebar - Google AdSense widget I designed for the new WordPress Sidebar Widgets plug-in. [...]
July 11th, 2006 at 03:30 AM
your widget rawks......
July 12th, 2006 at 21:39 PM
i'm getting this error when i put the adsense widget into the sidebar Warning: array_merge() [function.array-merge]: Argument #2 is not an array in /wp-content/plugins/widgets/adsense.php on line 78 Warning: Invalid argument supplied for foreach() in /wp-content/plugins/widgets/adsense.php on line 96
July 17th, 2006 at 20:26 PM
Works great for me, but right now the ads are showing in Spanish!
July 23rd, 2006 at 15:22 PM
[...] 一些widget About Me:这个应该不错 Picasa Web Matrix widget:加上google的picasa相册 Daiko’s Video Widget在侧栏增加一个google video播放器 AdSense widget:可以自定义AdSense Chip’s new widget:通过调用一个opml文件来显示你的blogroll[可能会减慢页面载入速度] useronline:在线访客情况,不知道这个版本能否正常显示。 Word Stats:统计每篇日志的字数和总字数。 gabbly widget:加上gabbly的聊天窗口。 Drop Down Archives:将存档以下拉方式显示。 Accessibility Widget:让访客可以选择浏览字体大小。 coComments widget:另一种显示回复发方式,见下面的sreenshot: [...]
July 24th, 2006 at 17:51 PM
I've noticed one minor issue: If there is space, the ad unit will be put on the same line as the H2.
July 25th, 2006 at 02:45 AM
[...] AdSense Widget for WordPress Sidebar - widget para la barra lateral de wordpress [...]
September 2nd, 2006 at 03:17 AM
[...] http://www.mikesmullin.com/2006/04/01/adsense-widget-wordpress-sidebar/ [...]
September 15th, 2006 at 16:58 PM
[...] AdSense Widget for WordPress Sidebar - Google AdSense widget I designed for the new WordPress Sidebar Widgets plug-in. [...]
September 15th, 2006 at 21:07 PM
[...] AdSense Widget for WordPress Sidebar - Google AdSense widget I designed for the new WordPress Sidebar Widgets plug-in. [...]
September 20th, 2006 at 05:44 AM
i’m getting this error when i put the adsense widget into the sidebar Warning: array_merge() [function.array-merge]: Argument #2 is not an array in /wp-content/plugins/widgets/adsense.php on line 78 Warning: Invalid argument supplied for foreach() in /wp-content/plugins/widgets/adsense.php on line 96 ----------------------------------------------- i'v got the same problem with u
September 27th, 2006 at 12:56 PM
[...] Using Jerome’s keywords, creates tag cloud 2-level subscription plugin AdSense Widget For WordPress Sidebar [...]
September 29th, 2006 at 19:34 PM
At my site: www.casarodante.org, I had a problem of Adsense showing ads in Italian. In researching it, it appears that you can override Adsense's detection with: google_language = "en"; I simply added: 'google_language' => "en", to the end of the array in this widget and it appears to be working great! FYI
October 1st, 2006 at 20:02 PM
Hey I am using this on my precharge projectnet blog. I love it! It's nice and easy to use but I have one question is there any way to make the border of the ads blend. Say put it inside a sticknote or something of that nature. Thank You
October 4th, 2006 at 21:51 PM
[...] AdSense Widget for WordPress Sidebar - Google AdSense widget I designed for the new WordPress Sidebar Widgets plug-in. [...]
October 5th, 2006 at 08:19 AM
[...] AdSense Widget for WordPress Sidebar - Google AdSense widget I designed for the new WordPress Sidebar Widgets plug-in. [...]
October 12th, 2006 at 04:00 AM
this looks interesting. love to implement it on my blog.
October 20th, 2006 at 01:33 AM
[...] Download the wp-widgets-AdSense from http://www.mikesmullin.com/2006/04/01/adsense-widget-wordpress-sidebar/. The zip file will contain one php file in it. Simply upload this (adsense.php) file to /wp-content/plugins/ directory. Then Activate it from “plugins” in your ap-admin panel. Now you should see the the AdSense widget in the list of “Available widgets“. Just drag and drop the widget as we did earlier. [...]
October 20th, 2006 at 01:34 AM
[...] Download the wp-widgets-AdSense from http://www.mikesmullin.com/2006/04/01/adsense-widget-wordpress-sidebar/. The zip file will contain one php file in it. Simply upload this (adsense.php) file to /wp-content/plugins/ directory. Then Activate it from “plugins” in your ap-admin panel. Now you should see the the AdSense widget in the list of “Available widgets“. Just drag and drop the widget as we did earlier. [...]
November 6th, 2006 at 16:53 PM
[...] AdSense Widget for WordPress Sidebar - Google AdSense widget I designed for the new WordPress Sidebar Widgets plug-in. [...]
November 13th, 2006 at 12:13 PM
[...] AdSense Widget for WordPress Sidebar - Google AdSense widget designed for the new WordPress Sidebar Widgets plug-in. [...]
November 13th, 2006 at 17:01 PM
[...] Adsense Widget, per tutti coloro che amano utilizzare le widgets di Wordpress [...]
November 13th, 2006 at 17:38 PM
[...] AdSense Widget for WordPress Sidebar - Google AdSense widget designed for the new WordPress Sidebar Widgets plug-in. [...]
November 14th, 2006 at 20:32 PM
[...] AdSense Widget for Wordpress Sidebar - damit lässt sich AdSense einfach in die Sidebar des Blogs integrieren. [...]
Post new comment