Fix all PHPCS issues
Compare changes
- Erick Hitter authored
+ 133
− 124
Description: Allows users to point WordPress objects (posts, pages, custom post types) to a URL of your choosing. Inspired by and backwards-compatible with <a href="http://txfx.net/wordpress-plugins/page-links-to/">Page Links To</a> by Mark Jaquith. Written for use on WordPress.com VIP.
add_action( 'init', array( $this, 'action_init' ), 0 ); // other init actions may rely on permalinks so filter early
@@ -63,17 +85,15 @@ class external_permalinks_redux {
@@ -63,17 +85,15 @@ class external_permalinks_redux {
@@ -81,25 +101,21 @@ class external_permalinks_redux {
@@ -81,25 +101,21 @@ class external_permalinks_redux {
add_meta_box( 'external-permalinks-redux', $title, array( $this, 'meta_box' ), $post_type, 'normal' );
@@ -109,146 +125,139 @@ class external_permalinks_redux {
@@ -109,146 +125,139 @@ class external_permalinks_redux {
<label for="epr-url"><?php _e( 'Destination Address:', 'external-permalinks-redux' ); ?></label><br />
<input name="<?php echo esc_attr( $this->meta_key_target ); ?>_url" class="large-text code" id="epr-url" type="text" value="<?php echo esc_url( get_post_meta( $post->ID, $this->meta_key_target, true ) ); ?>" />
<p class="description"><?php _e( 'To restore the original permalink, remove the link entered above.', 'external-permalinks-redux' ); ?></p>
if ( isset( $_POST[ $this->meta_key_target . '_nonce' ] ) && wp_verify_nonce( $_POST[ $this->meta_key_target . '_nonce' ], 'external-permalinks-redux' ) ) {
* Can be used as an alternative to the epr_post_types filter found in the plugin classes's action_admin_init function.