Plugin Directory

Changeset 634102


Ignore:
Timestamp:
12/04/2012 05:26:10 PM (13 years ago)
Author:
fd
Message:

Do not redirect author feeds

Location:
feedburner-plugin/trunk
Files:
3 added
3 edited

Legend:

Unmodified
Added
Removed
  • feedburner-plugin/trunk/fdfeedburner.php

    r412735 r634102  
    11<?php
    22/*
    3 Plugin Name: FD Feedburner Plugin
     3 Plugin Name: FD Feedburner Plugin
    44Plugin URI: http://flagrantdisregard.com/feedburner/
    55Description: Redirects all feeds to a Feedburner feed
    66Author: John Watson
    77Author URI: http://flagrantdisregard.com/
    8 Version: 1.45
     8Version: 1.46
    99
    1010Copyright (C) Sat Feb 18 2006 John Watson
     
    2727along with this program; if not, write to the Free Software
    2828Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
    29 */ 
     29*/
    3030
    3131define('FDFEEDBURNER_TEXTDOMAIN', 'fdfeedburner');
     
    4141    if ( function_exists('add_submenu_page') )
    4242        add_submenu_page('options-general.php',
    43             __('Feedburner', FDFEEDBURNER_TEXTDOMAIN),
    44             __('Feedburner', FDFEEDBURNER_TEXTDOMAIN),
    45             'manage_options', __FILE__, 'feedburner_conf');
     43                __('Feedburner', FDFEEDBURNER_TEXTDOMAIN),
     44                __('Feedburner', FDFEEDBURNER_TEXTDOMAIN),
     45                'manage_options', __FILE__, 'feedburner_conf');
    4646}
    4747
     
    6161    if (!isset($options['feedburner_no_cats'])) $options['feedburner_no_cats'] = 0;
    6262    if (!isset($options['feedburner_no_search'])) $options['feedburner_no_search'] = 0;
    63    
     63    if (!isset($options['feedburner_no_author'])) $options['feedburner_no_author'] = 0;
     64
    6465    $updated = false;
    6566    if ( isset($_POST['submit']) ) {
    6667        check_admin_referer('fdfeedburner', 'fdfeedburner-admin');
    67        
     68
    6869        if (isset($_POST['feedburner_url'])) {
    6970            $feedburner_url = $_POST['feedburner_url'];
     
    7273            $feedburner_url = null;
    7374        }
    74        
     75
    7576        if (isset($_POST['feedburner_comment_url'])) {
    7677            $feedburner_comment_url = $_POST['feedburner_comment_url'];
     
    7980            $feedburner_comment_url = null;
    8081        }
    81        
     82
    8283        if (isset($_POST['feedburner_append_cats'])) {
    8384            $feedburner_append_cats = $_POST['feedburner_append_cats'];
     
    8586            $feedburner_append_cats = 0;
    8687        }
    87        
     88
    8889        if (isset($_POST['feedburner_no_cats'])) {
    8990            $feedburner_no_cats = $_POST['feedburner_no_cats'];
     
    9192            $feedburner_no_cats = 0;
    9293        }
    93        
     94
    9495        if (isset($_POST['feedburner_no_search'])) {
    9596            $feedburner_no_search = $_POST['feedburner_no_search'];
     
    9798            $feedburner_no_search = 0;
    9899        }
    99        
     100
     101        if (isset($_POST['feedburner_no_author'])) {
     102            $feedburner_no_author = $_POST['feedburner_no_author'];
     103        } else {
     104            $feedburner_no_author = 0;
     105        }
     106
    100107        $options['feedburner_url'] = $feedburner_url;
    101108        $options['feedburner_comment_url'] = $feedburner_comment_url;
     
    103110        $options['feedburner_no_cats'] = $feedburner_no_cats;
    104111        $options['feedburner_no_search'] = $feedburner_no_search;
    105        
     112        $options['feedburner_no_author'] = $feedburner_no_author;
     113
    106114        update_option('fd_feedburner', $options);
    107        
     115
    108116        $updated = true;
    109117    }
    110 ?>
     118    ?>
    111119
    112120<div class="wrap">
     
    146154</p>
    147155
     156<p>
     157    <input id="feedburner_no_author" name="feedburner_no_author" type="checkbox" value="1"<?php if ($options['feedburner_no_author']==1) echo ' checked'; ?> />
     158    <label for="feedburner_no_author"><?php _e('Do not redirect author feeds', FDFEEDBURNER_TEXTDOMAIN); ?></label>
     159</p>
     160
    148161<p class="submit" style="text-align: left"><?php wp_nonce_field('fdfeedburner', 'fdfeedburner-admin'); ?><input type="submit" name="submit" value="<?php _e('Save', FDFEEDBURNER_TEXTDOMAIN); ?> &raquo;" /></p>
    149162</form>
     
    172185    if (!isset($options['feedburner_no_cats'])) $options['feedburner_no_cats'] = 0;
    173186    if (!isset($options['feedburner_no_search'])) $options['feedburner_no_search'] = 0;
     187    if (!isset($options['feedburner_no_author'])) $options['feedburner_no_author'] = 0;
    174188    $feed_url = $options['feedburner_url'];
    175189    $comment_url = $options['feedburner_comment_url'];
    176190    if ($feed_url == null && $comment_url == null) return;
    177    
     191
    178192    // Get category
    179193    $cat = null;
     
    206220    if ($wp->query_vars['s'] != null) {
    207221        $search = $wp->query_vars['s'];
     222    }
     223
     224    // Get author name
     225    $author_name = null;
     226    if ($wp->query_vars['author_name'] != null) {
     227        $author_name = $wp->query_vars['author_name'];
    208228    }
    209229
     
    226246                } else if ($search && $options['feedburner_no_search'] == 1) {
    227247                    // If this is a search result feed and redirect is disabled, do nothing
     248                } else if ($author_name && $options['feedburner_no_author'] == 1) {
     249                    // If this is an author feed and redirect is disabled, do nothing
    228250                } else {
    229251                    if ($feed_url != null) {
     
    243265*/
    244266add_action('template_redirect', 'feedburner_redirect');
    245 ?>
  • feedburner-plugin/trunk/languages/fdfeedburner.pot

    r453504 r634102  
    11# Translation of the WordPress plugin FD Feedburner by .
    2 # Copyright (C) 2010
     2# Copyright (C) 2012
    33# This file is distributed under the same license as the  package.
    44msgid ""
    55msgstr ""
    6 "Project-Id-Version: FD Feedburner Plugin 1.42\n"
     6"Project-Id-Version: FD Feedburner Plugin 1.46\n"
    77"Report-Msgid-Bugs-To: John Watson (john@flagrantdisregard.com)\n"
    8 "POT-Creation-Date: 2010-03-31 12:01-0700\n"
     8"POT-Creation-Date: 2012-12-04 17:19:02+00:00\n"
     9"MIME-Version: 1.0\n"
     10"Content-Type: text/plain; charset=UTF-8\n"
     11"Content-Transfer-Encoding: 8bit\n"
    912"PO-Revision-Date: 2010-MO-DA HO:MI+ZONE\n"
    1013"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
    1114"Language-Team: LANGUAGE <LL@li.org>\n"
    12 "MIME-Version: 1.0\n"
    13 "Content-Type: text/plain; charset=utf-8\n"
    14 "Content-Transfer-Encoding: 8bit\n"
    1515
    1616#: fdfeedburner.php:43 fdfeedburner.php:44
     
    1818msgstr ""
    1919
    20 #: fdfeedburner.php:120
     20#: fdfeedburner.php:124
     21msgid "Configuration updated."
     22msgstr ""
     23
     24#: fdfeedburner.php:128
    2125msgid "Feedburner Configuration"
    2226msgstr ""
    2327
    24 #: fdfeedburner.php:116
    25 msgid "Configuration updated."
    26 msgstr ""
    27 
    28 #: fdfeedburner.php:122
     28#: fdfeedburner.php:130
    2929msgid "How does this work?"
    3030msgstr ""
    3131
    32 #: fdfeedburner.php:123
     32#: fdfeedburner.php:131
    3333msgid ""
    3434"This plugin automatically redirects all of your existing feeds to Feedburner "
     
    3636msgstr ""
    3737
    38 #: fdfeedburner.php:124
     38#: fdfeedburner.php:132
    3939msgid ""
    4040"First go to <a href=\"http://feedburner.com\">Feedburner.com</a> and burn "
     
    4444msgstr ""
    4545
    46 #: fdfeedburner.php:125
     46#: fdfeedburner.php:133
    4747msgid ""
    4848"Once you enter URLs your feeds will be redirected automatically and you do "
     
    5050msgstr ""
    5151
    52 #: fdfeedburner.php:125
     52#: fdfeedburner.php:133
    5353msgid ""
    5454"Note that your feeds may not appear to redirect to Feedburner until you add "
     
    5656msgstr ""
    5757
    58 #: fdfeedburner.php:128
     58#: fdfeedburner.php:136
    5959msgid "Redirect my feeds here:"
    6060msgstr ""
    6161
    62 #: fdfeedburner.php:131
     62#: fdfeedburner.php:139
    6363msgid "Redirect my comments feed here:"
    6464msgstr ""
    6565
    66 #: fdfeedburner.php:134
     66#: fdfeedburner.php:142
    6767msgid "Advanced Options"
    6868msgstr ""
    6969
    70 #: fdfeedburner.php:137
     70#: fdfeedburner.php:145
    7171msgid "Do not redirect category or tag feeds"
    7272msgstr ""
    7373
    74 #: fdfeedburner.php:141
     74#: fdfeedburner.php:149
    7575msgid "Append category/tag to URL for category/tag feeds"
    7676msgstr ""
    7777
    78 #: fdfeedburner.php:145
     78#: fdfeedburner.php:153
    7979msgid "Do not redirect search result feeds"
    8080msgstr ""
    8181
    82 #: fdfeedburner.php:148
     82#: fdfeedburner.php:158
     83msgid "Do not redirect author feeds"
     84msgstr ""
     85
     86#: fdfeedburner.php:161
    8387msgid "Save"
    8488msgstr ""
  • feedburner-plugin/trunk/readme.txt

    r492885 r634102  
    44Tags: feedburner, redirect, rss, feed
    55Requires at least: 2.0
    6 Tested up to: 3.3.1
     6Tested up to: 3.4.2
    77Stable tag: trunk
    88
     
    2828
    29291. Copy the feedburner-plugin folder into wp-content/plugins
    30 1. Activate the plugin through the 'Plugins'
     301. Activate the plugin through the Plugins menu
    31311. Configure your feed from the new Feedburner Settings submenu
    3232
    3333== Changelog ==
     34
     35= 1.46 =
     36* Added "Do not redirect author feeds" option. Patch contributed by Robert McFrazier (lxbn.lexblog.com)
     37* Translators: please update your translations to include the new author feeds message (msgid "Do not redirect author feeds") if you can. Thanks!
     38* Added Russian translation by Pribory Trista (http://vizitti.com)
    3439
    3540= 1.45 =
Note: See TracChangeset for help on using the changeset viewer.