| Conditions | 1 |
| Paths | 1 |
| Total Lines | 74 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
Small methods make your code easier to understand, in particular if combined with a good name. Besides, if your method is small, finding a good name is usually much easier.
For example, if you find yourself adding comments to a method's body, this is usually a good sign to extract the commented part to a new method, and use the comment as a starting point when coming up with a good name for this new method.
Commonly applied refactorings include:
If many parameters/temporary variables are present:
| 1 | <?php |
||
| 136 | public function about_screen() { |
||
| 137 | list( $display_version ) = explode( '-', PPP_VERSION ); |
||
| 138 | ?> |
||
| 139 | <div class="wrap about-wrap"> |
||
| 140 | <h1><?php printf( __( 'Post Promoter Pro %s', 'ppp-txt' ), $display_version ); ?></h1> |
||
| 141 | <div class="about-text"><?php printf( __( 'The most effective way to promote your WordPress content.', 'ppp-txt' ), $display_version ); ?></div> |
||
| 142 | <div class="ppp-badge"><?php printf( __( 'Version %s', 'ppp-txt' ), $display_version ); ?></div> |
||
| 143 | |||
| 144 | <?php $this->tabs(); ?> |
||
| 145 | |||
| 146 | <div class="changelog"> |
||
| 147 | <h3><?php _e( 'Free Form Tweet Scheduling', 'ppp-txt' );?></h3> |
||
| 148 | |||
| 149 | <div class="feature-section"> |
||
| 150 | |||
| 151 | <img src="<?php echo PPP_URL . '/includes/images/screenshots/free-form-tweets.jpg'; ?>" class="ppp-welcome-screenshots"/> |
||
| 152 | |||
| 153 | <h4><?php _e( 'More effective, and user friendly.', 'ppp-txt' );?></h4> |
||
| 154 | <p><?php _e( 'No longer do you have to figure out what "Day 1" means. With free form scheduling, you can now create Tweets, days, weeks, or months in the future. Even multiples a day.', 'ppp-txt' );?></p> |
||
| 155 | <p><?php _e( 'Have an old post that you want to promote again? No problem, just go back and add another Scheduled Tweet to the list!', 'ppp-txt' );?></p> |
||
| 156 | |||
| 157 | </div> |
||
| 158 | </div> |
||
| 159 | |||
| 160 | <div class="changelog"> |
||
| 161 | <h3><?php _e( 'Twitter Cards Support', 'ppp-txt' );?></h3> |
||
| 162 | |||
| 163 | <div class="feature-section"> |
||
| 164 | |||
| 165 | <img src="<?php echo PPP_URL . '/includes/images/screenshots/twitter-cards.jpg'; ?>" class="ppp-welcome-screenshots"/> |
||
| 166 | |||
| 167 | <h4><?php _e( 'Increased visibility on Twitter','ppp-txt' );?></h4> |
||
| 168 | <p><?php _e( 'Enable this feature if you want your Tweets to look the best they can.', 'ppp-txt' );?></p> |
||
| 169 | <p><?php _e( 'This is an opt-in setting, so if you have a plugin that already does this, no conflicts will arise upon upgrade.', 'ppp-txt' );?></p> |
||
| 170 | |||
| 171 | </div> |
||
| 172 | </div> |
||
| 173 | |||
| 174 | <div class="changelog"> |
||
| 175 | <h3><?php _e( 'Variable Twitter Images', 'ppp-txt' );?></h3> |
||
| 176 | |||
| 177 | <div class="feature-section"> |
||
| 178 | |||
| 179 | <h4><?php _e( 'Change the image attached to each Tweet','ppp-txt' );?></h4> |
||
| 180 | <p><?php _e( 'Have a few rotating images you want to use for your scheduled Tweets? No problem, Version 2.2 supports changing this for every scheduled Tweet.', 'ppp-txt' );?></p> |
||
| 181 | |||
| 182 | </div> |
||
| 183 | </div> |
||
| 184 | |||
| 185 | <div class="changelog"> |
||
| 186 | <h3><?php _e( 'Additional Updates', 'ppp-txt' );?></h3> |
||
| 187 | |||
| 188 | <div class="feature-section col three-col"> |
||
| 189 | <div> |
||
| 190 | <h4><?php _e( 'Updated image sizes', 'ppp-txt' );?></h4> |
||
| 191 | <p><?php _e( 'Changed the optimal thumbnail image sizes to meet the 2015 network standards.', 'ppp-txt' );?></p> |
||
| 192 | |||
| 193 | <h4><?php _e( 'CSS Updates', 'ppp-txt' );?></h4> |
||
| 194 | <p><?php _e( 'Fixed a conflict in the media library CSS.', 'ppp-txt' );?></p> |
||
| 195 | </div> |
||
| 196 | |||
| 197 | <div class="last-feature"> |
||
| 198 | <h4><?php _e( 'Improved Facebook Token Refresh', 'ppp-txt' );?></h4> |
||
| 199 | <p><?php _e( 'Fixed a bug with the Facebook token refresh resetting the "Post As", dropdown.', 'ppp-txt' );?></p> |
||
| 200 | </div> |
||
| 201 | </div> |
||
| 202 | </div> |
||
| 203 | |||
| 204 | <div class="return-to-dashboard"> |
||
| 205 | <a href="<?php echo esc_url( admin_url( 'admin.php?page=ppp-options' ) ); ?>"><?php _e( 'Start Using Post Promoter Pro!', 'ppp-txt' ); ?></a> |
||
| 206 | </div> |
||
| 207 | </div> |
||
| 208 | <?php |
||
| 209 | } |
||
| 210 | |||
| 266 |