PluginProbe
FeedWordPress / 2013.0503
FeedWordPress v2013.0503
trunk 0.8 0.9 0.91 0.95 0.96 0.97 0.98 0.981 0.99 0.991 0.992 0.993 2008.1030 2008.1101 2008.1105 2008.1214 2009.0612 2009.0613 2009.0618 2009.0707 2009.1111 2009.1112 2010.0127 2010.0528 All 65 releases
← All changes | updatedpostscontrol.class.php +8 -12 trunk2013.0503 View file →
@@ -1,15 +1,11 @@
1 1 <?php
2 2 class UpdatedPostsControl {
3 3 var $page;
4 - function __construct( &$page ) {
4 + function UpdatedPostsControl (&$page) {
5 5 $this->page =& $page;
6 6 } /* UpdatedPostsControl constructor */
7 7
8 - function UpdatedPostsControl( &$page ) {
9 - self::__construct( $page );
10 - }
11 -
12 8 function display () {
13 9 $settings = array(
14 10 // This is all bass-ackwards because the actual yes/no
15 11 // setting is whether to *freeze* posts out of being
@@ -32,10 +28,10 @@
32 28 $aFeed = 'a syndicated feed';
33 29 endif;
34 30 ?>
35 31 <tr>
36 - <th scope="row"><?php esc_html_e('Updated posts:') ?></th>
37 - <td><p>When <?php print esc_html( $aFeed ); ?> includes updated content for
32 + <th scope="row"><?php _e('Updated posts:') ?></th>
33 + <td><p>When <?php print $aFeed; ?> includes updated content for
38 34 a post that was already syndicated, should the syndicated copy
39 35 of the post be updated to match the revised version?</p>
40 36
41 37 <?php
@@ -48,17 +44,17 @@
48 44 </td></tr>
49 45 <?php
50 46 } /* UpdatedPostsControl::display() */
51 47
52 - function accept_POST () {
48 + function accept_POST ($post) {
53 49 if ($this->page->for_feed_settings()) :
54 - if ( ! is_null( FeedWordPress::post( 'freeze_updates' ) ) ) :
55 - $this->page->link->settings['freeze updates'] = FeedWordPress::post( 'freeze_updates' );
50 + if (isset($post['freeze_updates'])) :
51 + $this->page->link->settings['freeze updates'] = $post['freeze_updates'];
56 52 endif;
57 53 else :
58 54 // Updated posts
59 - if ( ! is_null( FeedWordPress::post( 'freeze_updates' ) ) ) :
60 - update_option('feedwordpress_freeze_updates', FeedWordPress::post( 'freeze_updates' ));
55 + if (isset($post['freeze_updates'])) :
56 + update_option('feedwordpress_freeze_updates', $post['freeze_updates']);
61 57 endif;
62 58 endif;
63 59 } /* UpdatedPostsControl::accept_POST() */
64 60 } /* class UpdatedPostsControl */