Placing a remote ad snippet using channels results in no ads being served, despite ads being saved in both relevant channels and no channels (with 'Always' selected for channel display settings).
Looking at the ad serving script debugging info, it appears to my untutored eye (my js sucks) that the system is pulling up an ad, but the system is failing to write the image to the page. But judge for yourself:
ad_dir: '/var/www/sanduskyregister.com/r360/sites/r360.sanduskyregister.com/modules/contrib/ad'
debug: '2'
adcache: 'none'
nids: ''
tids: '291'
hostid: '819bb72f06212249de895727c8c5d9d8'
url: 'http://staging.funcoast.com/'
quantity: '1'
aid: '0'
ad_display: 'javascript'
Drupal bootstrap '0'.
Root drupal directory detected as '/var/www/drupal6-staging'.
/var/www/sanduskyregister.com/r360/sites/r360.sanduskyregister.com/modules/contrib/ad/serve.php: // $Id: serve.php,v 1.1.2.2.2.1.2.1 2009/02/23 22:39:02 jeremy Exp $
/var/www/sanduskyregister.com/r360/sites/r360.sanduskyregister.com/modules/contrib/ad/adserve.inc: // $Id: adserve.inc,v 1.1.2.31.2.8.2.1 2009/02/23 22:39:02 jeremy Exp $
/var/www/sanduskyregister.com/r360/sites/r360.sanduskyregister.com/modules/contrib/ad/adcache.inc:
/var/www/sanduskyregister.com/r360/sites/r360.sanduskyregister.com/modules/contrib/ad/ad.module: // $Id: ad.module,v 1.2.2.29.2.83.2.16.2.4 2009/03/03 11:25:59 jeremy Exp $
/var/www/sanduskyregister.com/r360/sites/r360.sanduskyregister.com/modules/contrib/ad/ad.install: // $Id: ad.install,v 1.2.2.4.2.27.2.7.2.1 2009/02/23 22:39:02 jeremy Exp $
adserve_cache function(get_ad_ids)
Cache function 'ad_cache_none_get_ad_ids' does not exist.
Invoking cache function 'adserve_cache_get_ad_ids'.
Entering default adserve_display.
adserve_cache function(open)
Cache function 'ad_cache_none_open' does not exist.
Invoking cache function 'adserve_cache_open'.
Drupal bootstrap '8'.
Hostid: '819bb72f06212249de895727c8c5d9d8'.
adserve_invoke_hook hook(init) action(first)
adserve_cache function(hook)
Cache function 'ad_cache_none_hook' does not exist.
Invoking cache function 'adserve_cache_hook'.
adserve_cache function(get_cache)
Cache function 'ad_cache_none_get_cache' does not exist.
Invoking cache function 'adserve_cache_get_cache'.
adserve_cache function(build_hooks)
Cache function 'ad_cache_none_build_hooks' does not exist.
Invoking cache function 'adserve_cache_build_hooks'.
Did not find hook 'init'.
Function 'adserve_hook_init' does not exist.
adserve_cache function(id)
Cache function 'ad_cache_none_id' does not exist.
Invoking cache function 'adserve_cache_id'.
Unsupported type 'host'.
Searching tids: 291
adserve_cache function(id)
Invoking cache function 'adserve_cache_id'.
Total ads: '9'.
Already displayed: 0
adserve_cache function(validate)
Cache function 'ad_cache_none_validate' does not exist.
Invoking cache function 'adserve_cache_validate'.
Validated ads: '9'.
adserve_invoke_hook hook(filter) action(intersect)
adserve_cache function(hook)
Invoking cache function 'adserve_cache_hook'.
Invoking hook 'filter'.
Including file: '/var/www/drupal6-staging/sites/r360.sanduskyregister.com/modules/contrib/ad/channel/ad_channel.inc'.
Invoking 'ad_channel_cache_filter'.
ad_channel_cache: adserve_cache_filter
adserve_cache function(get_cache)
Invoking cache function 'adserve_cache_get_cache'.
ad_channel_cache: checking aid(22778)
ad_channel_cache: checking aid(22778) against channel(4) path(http://staging.funcoast.com/) regexp(/^(http\:\/\/www\.fandy\.com.*)$/) match(0)
ad_channel_cache: aid(22778) is not valid
ad_channel_cache: checking aid(22789)
ad_channel_cache: checking aid(22789) against channel(3) path(http://staging.funcoast.com/) regexp(/^(http\:\/\/staging\.funcoast\.com.*)$/) match(1)
ad_channel_cache: aid(22789) is valid
ad_channel_cache: checking aid(22792)
ad_channel_cache: checking aid(22792) against channel(4) path(http://staging.funcoast.com/) regexp(/^(http\:\/\/www\.fandy\.com.*)$/) match(0)
ad_channel_cache: aid(22792) is not valid
ad_channel_cache: checking aid(22804)
ad_channel_cache: aid(22804) has no channel info [1]
ad_channel_cache: aid(22804) is valid
ad_channel_cache: checking aid(22821)
ad_channel_cache: checking aid(22821) against channel(6) path(http://staging.funcoast.com/) regexp(/^(http\:\/\/www\.fandy\.com\/st-mary-central-catholic.*)$/) match(0)
ad_channel_cache: aid(22821) is not valid
ad_channel_cache: checking aid(22827)
ad_channel_cache: checking aid(22827) against channel(8) path(http://staging.funcoast.com/) regexp(/^(http\:\/\/www\.fandy\.com\/huron.*)$/) match(0)
ad_channel_cache: aid(22827) is not valid
ad_channel_cache: checking aid(22879)
ad_channel_cache: checking aid(22879) against channel(3) path(http://staging.funcoast.com/) regexp(/^(http\:\/\/staging\.funcoast\.com.*)$/) match(1)
ad_channel_cache: aid(22879) is valid
ad_channel_cache: checking aid(22880)
ad_channel_cache: checking aid(22880) against channel(3) path(http://staging.funcoast.com/) regexp(/^(http\:\/\/staging\.funcoast\.com.*)$/) match(1)
ad_channel_cache: aid(22880) is valid
ad_channel_cache: checking aid(22882)
ad_channel_cache: checking aid(22882) against channel(3) path(http://staging.funcoast.com/) regexp(/^(http\:\/\/staging\.funcoast\.com.*)$/) match(1)
ad_channel_cache: aid(22882) is valid
adserve_cache function(get_cache)
Invoking cache function 'adserve_cache_get_cache'.
ad_channel_cache: aid(22789) is not a premiere advertisement
ad_channel_cache: aid(22804) is not a premiere advertisement
ad_channel_cache: aid(22879) is not a premiere advertisement
ad_channel_cache: aid(22880) is not a premiere advertisement
ad_channel_cache: aid(22882) is not a premiere advertisement
ad_channel_cache: returning non-premiere advertisements
Filtered ads: '5'.
adserve_invoke_hook hook(weight) action(first)
adserve_cache function(hook)
Invoking cache function 'adserve_cache_hook'.
Invoking hook 'weight'.
Including file: '/var/www/drupal6-staging/sites/r360.sanduskyregister.com/modules/contrib/ad/weight/probability/ad_weight_probability.inc'.
Invoking 'ad_weight_probability_cache_filter'.
adserve_cache function(get_cache)
Invoking cache function 'adserve_cache_get_cache'.
ad_weight_probability cache_filter gcd(100)
ad_weight_probability cache_filter aid(22789) weight(1)
ad_weight_probability cache_filter aid(22804) weight(1)
ad_weight_probability cache_filter aid(22879) weight(1)
ad_weight_probability cache_filter aid(22880) weight(1)
ad_weight_probability cache_filter aid(22882) weight(1)
Weighted ads: '5'.
adserve_invoke_hook hook(select) action(first)
adserve_cache function(hook)
Invoking cache function 'adserve_cache_hook'.
Did not find hook 'select'.
Invoking 'adserve_hook_select'.
Randomly selecting ad 1 of 1.
Randomly selected ID: 22880.
adserve_cache function(validate)
Invoking cache function 'adserve_cache_validate'.
Selected ads: '1'.
adserve_cache function(display)
Cache function 'ad_cache_none_display' does not exist.
Invoking cache function 'adserve_cache_display'.
adserve_cache function(display_ad)
Cache function 'ad_cache_none_display_ad' does not exist.
Invoking cache function 'adserve_cache_display_ad'.
Ad type 'image', loading module ''
ad: <div class="image-advertisement" id="ad-22880"></div>
adserve_cache function(increment)
Cache function 'ad_cache_none_increment' does not exist.
Invoking cache function 'adserve_cache_increment'.
adserve_increment action(view) aid(22880) hostid(819bb72f06212249de895727c8c5d9d8)
Drupal bootstrap '8'.
adserve_invoke_hook hook(increment_extra) action(merge)
adserve_cache function(hook)
Invoking cache function 'adserve_cache_hook'.
Did not find hook 'increment_extra'.
Function 'adserve_hook_increment_extra' does not exist.
adserve_increment extra(Array)
adserve_cache function(close)
Cache function 'ad_cache_none_close' does not exist.
Cache function 'adserve_cache_close' does not exist.
adserve_invoke_hook hook(init_text) action(append)
adserve_cache function(hook)
Invoking cache function 'adserve_cache_hook'.
Did not find hook 'init_text'.
Function 'adserve_hook_init_text' does not exist.
adserve_invoke_hook hook(exit_text) action(append)
adserve_cache function(hook)
Invoking cache function 'adserve_cache_hook'.
Did not find hook 'exit_text'.
Function 'adserve_hook_exit_text' does not exist.
document.write('\x3cdiv class=\"image-advertisement\" id=\"ad-22880\"\x3e\x3c/div\x3e');
Comments
Comment #1
jeremy commentedThis appears to be a new bug introduced in -beta2, in which locally hosted images are now broken. This bug was added while implementing support for remotely hosted images (which do work properly, even with the remote snippet).
Comment #2
jeremy commentedFix committed. I was using an isset() inappropriately, causing locally hosted image ads to never be displayed.
Comment #3
nicholas_w commentedYay! I tested the patch and the ads are back -- Huzzah!
Comment #4
jeremy commentedGlad to hear it! Marking fixed, and will be in the next -beta release, probably tomorrow.