remove ad activation box, fix install SQL, bump up version number

This commit is contained in:
John Bintz 2009-02-17 16:54:13 -05:00
parent 844e0f9fd0
commit 3a381e1d2f
4 changed files with 9 additions and 55 deletions

View File

@ -2,7 +2,7 @@
require_once('PublisherInfo.php'); require_once('PublisherInfo.php');
define("PLUGIN_WONDERFUL_DATABASE_VERSION", 2); define("PLUGIN_WONDERFUL_DATABASE_VERSION", 3);
/** /**
* The interface to the PW database table. * The interface to the PW database table.
@ -31,8 +31,8 @@ class PWAdboxesClient {
adtype char(30) NOT NULL, adtype char(30) NOT NULL,
url char(255) NOT NULL, url char(255) NOT NULL,
dimensions char(10) NOT NULL, dimensions char(10) NOT NULL,
rating char(10) NOT NULL, rating char(30) NOT NULL,
category char(30) NOT NULL, category char(50) NOT NULL,
description text NOT NULL, description text NOT NULL,
tags text NOT NULL, tags text NOT NULL,
standardcode text NOT NULL, standardcode text NOT NULL,

View File

@ -3,7 +3,7 @@
Plugin Name: Plugin Wonderful Plugin Name: Plugin Wonderful
Plugin URI: http://www.coswellproductions.com/wordpress/wordpress-plugins/ Plugin URI: http://www.coswellproductions.com/wordpress/wordpress-plugins/
Description: Easily embed a Project Wonderful publisher's advertisements. Description: Easily embed a Project Wonderful publisher's advertisements.
Version: 0.3 Version: 0.4
Author: John Bintz Author: John Bintz
Author URI: http://www.coswellproductions.org/wordpress/ Author URI: http://www.coswellproductions.org/wordpress/
@ -159,28 +159,6 @@ class PluginWonderful {
if (method_exists($this, $action)) { call_user_func(array($this, $action)); } if (method_exists($this, $action)) { call_user_func(array($this, $action)); }
} }
function handle_action_activate_ad() {
if (isset($_POST['submit'])) {
$original_ad_code = get_option('plugin-wonderful-activate-ad-code');
update_option('plugin-wonderful-activate-ad-code', $_POST['activate-ad-code']);
if (empty($_POST['activate-ad-code'])) {
$this->messages[] = __('Adbox for activation removed.', 'plugin-wonderful');
} else {
$this->messages[] = __('Adbox for activation changed. Return to Project Wonderful to finish activating your ad, then return here and click the Finished button.', 'plugin-wonderful');
}
}
if (isset($_POST['finished'])) {
update_option('plugin-wonderful-activate-ad-code', "");
$this->messages[] = __('Adbox for activation removed and all adboxes redownloaded.', 'plugin-wonderful');
if ($member_id = get_option('plugin-wonderful-memberid')) {
$this->publisher_info = $this->adboxes_client->get_ads($member_id);
}
}
}
function handle_action_change_adbox_settings() { function handle_action_change_adbox_settings() {
if ($member_id = get_option('plugin-wonderful-memberid')) { if ($member_id = get_option('plugin-wonderful-memberid')) {
if (isset($_POST['template_tag_id']) && is_array($_POST['template_tag_id'])) { if (isset($_POST['template_tag_id']) && is_array($_POST['template_tag_id'])) {
@ -293,7 +271,6 @@ $plugin_wonderful = new PluginWonderful();
add_action('admin_menu', array($plugin_wonderful, 'set_up_menu')); add_action('admin_menu', array($plugin_wonderful, 'set_up_menu'));
add_action('init', array($plugin_wonderful, 'set_up_widgets')); add_action('init', array($plugin_wonderful, 'set_up_widgets'));
add_filter('the_excerpt_rss', array($plugin_wonderful, 'insert_rss_feed_ads')); add_filter('the_excerpt_rss', array($plugin_wonderful, 'insert_rss_feed_ads'));
add_filter('wp_footer', array($plugin_wonderful, 'insert_activation_ad'));
register_activation_hook(__FILE__, array($plugin_wonderful, 'handle_activation')); register_activation_hook(__FILE__, array($plugin_wonderful, 'handle_activation'));

View File

@ -3,7 +3,7 @@ Contributors: johncoswell
Tags: ads, sidebar, widget Tags: ads, sidebar, widget
Requires at least: 2.7 Requires at least: 2.7
Tested up to: 2.7.1 Tested up to: 2.7.1
Stable tag: 0.3 Stable tag: 0.4
Donate link: http://www.coswellproductions.com/wordpress/wordpress-plugins/ Donate link: http://www.coswellproductions.com/wordpress/wordpress-plugins/
Plugin Wonderful lets Project Wonderful publishers quickly and easily add their adboxes to thier WordPress site. Plugin Wonderful lets Project Wonderful publishers quickly and easily add their adboxes to thier WordPress site.
@ -14,7 +14,7 @@ Plugin Wonderful downloads your adbox information from Project Wonderful and cre
== Installation == == Installation ==
Copy the plugin-wonderful folder to your wp-content/plugins folder and activate it from Plugins -> Installed. Activating the plugin creates a new database table, {prefix}_pw_adboxes, that you can safely remove if you are no longer using the plugin. Copy the plugin-wonderful folder to your wp-content/plugins folder and activate it from Plugins -> Installed. Activating the plugin creates a new database table, `{prefix}_pw_adboxes`, that you can safely remove if you are no longer using the plugin.
== Frequently Asked Questions == == Frequently Asked Questions ==
@ -28,10 +28,6 @@ If you want to refer to an ad by an arbitrary name, rather than the adbox id, yo
`the_project_wonderful_ad('header')` `the_project_wonderful_ad('header')`
= How does quick ad activation work? =
When you create an adbox on Project Wonderful, before people can bid on the ad you need to activate the adbox, by placing in on your page and letting PW check the ad's existence. Since only activated ads appear in your adbox listing, you can't automatically ad the adbox to your site. Quick activation lets you temporarily place the adbox code from PW into the footer of all pages on your site so that PW can find the ad for activation purposes. After it's activated, it will appear in your adbox list. Follow the instructions given by the plugin to quickly activate new Project Wonderful ads.
= How robust is placing ads in the RSS feed? = = How robust is placing ads in the RSS feed? =
Project Wonderful does support placing ads in the RSS feed. In this case, all of the JavaScript is stripped out, since many RSS feed readers don't support JavaScript in the feed. The ads are placed above any excerpts in the feed. Some readers may not like the markup used. Until further testing is done, there are no good answers on how well PW ads delivered by Plugin Wonderful will perform. Project Wonderful does support placing ads in the RSS feed. In this case, all of the JavaScript is stripped out, since many RSS feed readers don't support JavaScript in the feed. The ads are placed above any excerpts in the feed. Some readers may not like the markup used. Until further testing is done, there are no good answers on how well PW ads delivered by Plugin Wonderful will perform.

View File

@ -85,25 +85,6 @@
</form> </form>
<?php } ?> <?php } ?>
<table class="form-table" cellspacing="0">
<tr>
<td style="padding-left: 0" width="30%">
<h3><?php _e('Quickly Set Up A New Adbox For Activation', 'plugin-wonderful') ?></h3>
<p><?php _e("Copy and paste your new ad's code from Project Wonderful into the textbox on the right and click Submit. Your ad will appear in the footer of all the pages on your site so that Project Wonderful can detect it. Click the Finished button after you've activated your ad and it will appear in the list of available advertisements above.", 'plugin-wonderful') ?></p>
</td>
<td style="padding-right: 0">
<form action="" method="post">
<input type="hidden" name="action" value="activate-ad" />
<textarea name="activate-ad-code" style="width: 100%; height: 100px"><?php echo get_option('plugin-wonderful-activate-ad-code') ?></textarea>
<br />
<input class="button" type="submit" name="submit" value="Submit" />
<input class="button" type="submit" name="finished" value="Finished" />
</form>
</td>
</tr>
</table>
<?php if ($this->publisher_info !== false) { ?> <?php if ($this->publisher_info !== false) { ?>
<h3><?php _e('Using Widgets to Put Ads on Your Site', 'plugin-wonderful') ?></h3> <h3><?php _e('Using Widgets to Put Ads on Your Site', 'plugin-wonderful') ?></h3>
<p> <p>