From fbf3a7824c0d1d4b0a0eaf33b19073869d823c7d Mon Sep 17 00:00:00 2001 From: John Bintz Date: Wed, 1 Jul 2009 21:21:28 -0400 Subject: [PATCH] allow for default ad to be selected on widget --- classes/PluginWonderful.php | 1 + test/PluginWonderfulTest.php | 32 +++++++++++++++++--------------- 2 files changed, 18 insertions(+), 15 deletions(-) diff --git a/classes/PluginWonderful.php b/classes/PluginWonderful.php index 5c63a8d..3ec8354 100644 --- a/classes/PluginWonderful.php +++ b/classes/PluginWonderful.php @@ -365,6 +365,7 @@ class PluginWonderful { echo '

'; echo 'Select an adbox:
'; foreach ($this->publisher_info->adboxes as $box) { + if (empty($instance['adboxid'])) { $instance['adboxid'] = $box->adboxid; } echo '