Is BlogCatalog Paying for Ads On Its Own Site?

Posted on September 4th, 2008 in Ads by mcnicholl

I recently got one of many emails from blogcatalog.com to tell me that I had a message waiting for me - so off I went to see what it said.

Surprise, surprise it was yet another “Hey I have added you to my friends list. Hope you add me to” message - so I simply do what I always do and ignore it.

My eye was then caught by a banner ad on the site. “Bloggers Unite” and “Blogging for hope.”  it said triumphantly.

I am always eager to know how the big sites handle their adverts - i.e how they serve them. Some have internal systems - either custom made or OpenX - while other outsource this to ad agencies.

This is only for adverts that are displayed on their own sites. Of course, they also use ad agencies like Adsense and DoubleClick etc to advertise on other peoples/companies websites.

So I hovered over the banner ad to see if I could determine how it was served. To my amazement, I saw that it was coming from DoubleClick and that it was an ad for BLOGCATALOG.

See here :

So - does that mean that Blogcatalog have an Ad campaign running with DoubleClick, and Doubleclick are serving those ads on BlogCatalogs own site ?

Weird.

Wordpress 2.6: register_activation_hook Cannot See Global Variables

Posted on September 3rd, 2008 in ALM, Programming, Wordpress by mcnicholl

I have recently been trying to update an old plugin I created for Wordpress 2.3.2 so that it would be compatible with the latest version : 2.6.

I am currently having an issue where the register_activation_hook function (and this may not be limited to this one function) where it refuses to reference the global variables that I define in the plugin.

Take the below as an example (proper code attached at the bottom):

require ‘mcn_constants.php’;

$mcn_test_blabla    =   “Well ??????”;

register_activation_hook(__FILE__,’mcn_test_install’);
register_deactivation_hook(__FILE__, ‘mcn_test_uninstall’ ) ;

add_action(’parse_query’, ‘mcn_test_check’);

function mcn_test_install() {
    global $this_is_broke, $mcn_test_blabla;

    add_option(”mcn_test_value”, “The value is: $this_is_broke And :: $mcn_test_blabla “);
}

function mcn_test_uninstall() {
    delete_option(”mcn_test_value”);
}

function mcn_test_check() {
    global $this_is_broke;

    echo get_option(”mcn_test_value”);
    echo “Proper value : $this_is_broke”;
}

When you load the front page of your blog with the above plugin code activated you should see :

The value is: YES I AM BROKE!!!!!
And ::Well ??????

Proper value : YES I AM BROKE!!!!!

… but instead you see:

The value is:
And ::

Proper value : YES I AM BROKE!!!!!

As you can see - the $this_is_broke and $mcn_test_blabla variables are not being set in the Option “mcn_test_value”.

Yet calling the global variable in the function “mcn_test_check”, which is called as part of the “parse query” action, will show the global variable - as it should.

So - is this a bug or am I missing something fundamentally different in Wordpress 2.6? Using global variables in Wordpress 2.3.2 worked just fine.

I have attached a sample plugin that will replicate this issue.

Any ideas?

mcn_test.rar