Ticket #1441: patch.3.diff
File patch.3.diff, 8.1 KB (added by , 9 years ago) |
---|
-
wordcamp-coming-soon-page/classes/wccsp-settings.php
72 72 public function register_settings_pages() { 73 73 add_submenu_page( 74 74 'options-general.php', 75 'Coming Soon',76 'Coming Soon',75 __( 'Coming Soon', 'wordcamporg'), 76 __( 'Coming Soon', 'wordcamporg'), 77 77 self::REQUIRED_CAPABILITY, 78 78 'wccsp_settings', 79 79 array( $this, 'markup_settings_page' ) … … 87 87 if ( current_user_can( self::REQUIRED_CAPABILITY ) ) { 88 88 require_once( dirname( __DIR__ ) . '/views/settings-screen.php' ); 89 89 } else { 90 wp_die( 'Access denied.');90 wp_die( __( 'Access denied.', 'wordcamporg' ) ); 91 91 } 92 92 } 93 93 … … 105 105 106 106 add_settings_field( 107 107 'wccsp_enabled', 108 'Enabled',108 __( 'Enabled', 'wordcamporg' ), 109 109 array( $this, 'markup_fields' ), 110 110 'wccsp_settings', 111 111 'wccsp_default', … … 114 114 115 115 add_settings_field( 116 116 'wccsp_body_background_color', 117 'Body Background Color',117 __( 'Body Background Color', 'wordcamporg' ), 118 118 array( $this, 'markup_fields' ), 119 119 'wccsp_settings', 120 120 'wccsp_default', … … 123 123 124 124 add_settings_field( 125 125 'wccsp_container_background_color', 126 'Container Background Color',126 __( 'Container Background Color', 'wordcamporg' ), 127 127 array( $this, 'markup_fields' ), 128 128 'wccsp_settings', 129 129 'wccsp_default', … … 132 132 133 133 add_settings_field( 134 134 'wccsp_text_color', 135 'Text Color',135 __( 'Text Color', 'wordcamporg' ), 136 136 array( $this, 'markup_fields' ), 137 137 'wccsp_settings', 138 138 'wccsp_default', … … 141 141 142 142 add_settings_field( 143 143 'wccsp_image_id', 144 'Image',144 __( 'Image', 'wordcamporg' ), 145 145 array( $this, 'markup_fields' ), 146 146 'wccsp_settings', 147 147 'wccsp_default', -
wordcamp-coming-soon-page/views/settings-admin-notices.php
1 1 <div class="error"> 2 2 <ul> 3 3 <?php foreach ( $inactive_required_modules as $module ) : ?> 4 <li>Please activate Jetpack's <?php echo esc_html( $module ); ?> module.</li> 4 <?php $jetpack_module = esc_html( $module ); ?> 5 <li><?php /* translators: %s is the name of the jetpack module */ printf( __( "Please activate Jetpack's %s module." ), $jetpack_module ); ?></li> 5 6 <?php endforeach; ?> 6 7 </ul> 7 8 </div> -
wordcamp-coming-soon-page/views/settings-fields.php
1 1 <?php if ( 'wccsp_enabled_true' == $field['label_for'] ) : ?> 2 2 <input id="wccsp_enabled_true" name="wccsp_settings[enabled]" type="radio" value="on" <?php checked( $this->settings['enabled'], 'on' ); ?> /> 3 <span class="example"> On</span><br />3 <span class="example"> <?php _e( 'On' , 'wordcamporg'); ?></span><br /> 4 4 5 5 <input id="wccsp_enabled_false" name="wccsp_settings[enabled]" type="radio" value="off" <?php checked( $this->settings['enabled'], 'off' ); ?> /> 6 <span class="example"> Off</span>6 <span class="example"> <?php _e( 'Off' , 'wordcamporg'); ?></span> 7 7 <?php endif; ?> 8 8 9 9 … … 25 25 <?php if ( 'wccsp_image_id' == $field['label_for'] ) : ?> 26 26 <p> 27 27 <input type="hidden" id="wccsp_image_id" name="wccsp_settings[image_id]" value="<?php echo esc_attr( $this->settings['image_id'] ); ?>" /> 28 <a href="javascript:;" id="wccsp-select-image" class="button insert-media add_media" title=" Select Image">Select Image</a>28 <a href="javascript:;" id="wccsp-select-image" class="button insert-media add_media" title="<?php esc_attr_e('Select Image', 'wordcamporg' ); ?>"><?php _e( 'Select Image', 'wordcamporg' ); ?></a> 29 29 </p> 30 30 31 31 <?php if( $image ) : ?> 32 32 <p id="wccsp_image_preview"> 33 Current image preview:<br />34 <img src="<?php echo esc_attr( $image[0] ); ?>" alt=" Image Preview" />33 <?php _e( 'Current image preview:', 'wordcamporg' ); ?><br /> 34 <img src="<?php echo esc_attr( $image[0] ); ?>" alt="<?php esc_attr_e('Image Preview', 'wordcamporg' ); ?>" /> 35 35 </p> 36 36 <?php endif; ?> 37 37 <?php endif; ?> -
wordcamp-coming-soon-page/views/settings-screen.php
1 1 <div class="wrap"> 2 2 <div id="icon-options-general" class="icon32"><br /></div> 3 <h1> Coming Soon</h1>3 <h1><?php _e( 'Coming Soon', 'wordcamporg' ); ?></h1> 4 4 5 5 <form method="post" action="options.php"> 6 6 <?php settings_fields( 'wccsp_settings' ); ?> -
wordcamp-coming-soon-page/views/settings-section-headers.php
1 <p> When enabled, the Coming Soon page will be displayed to logged-out users, giving you a chance to setup all of your content before your site is visible to the world. To preview the page, just open your site in an Incognito/Private tab, or log out of your account.</p>1 <p><?php _e( 'When enabled, the Coming Soon page will be displayed to logged-out users, giving you a chance to setup all of your content before your site is visible to the world. To preview the page, just open your site in an Incognito/Private tab, or log out of your account.', 'wordcamporg' ); ?></p> -
wordcamp-coming-soon-page/views/template-coming-soon.php
12 12 <body <?php body_class(); ?>> 13 13 <div id="wccsp-container"> 14 14 15 <h1><?php echo esc_attr( get_bloginfo( 'name' )); ?></h1>15 <h1><?php bloginfo( 'name' ); ?></h1> 16 16 17 17 <?php if ( $image_url ) : ?> 18 18 <img id="wccsp-image" src="<?php echo esc_attr( $image_url ); ?>" alt="<?php echo esc_attr( get_bloginfo( 'name' ) ); ?>" /> … … 19 19 <?php endif; ?> 20 20 21 21 <?php if ( $dates ) : ?> 22 <h2><?php echo esc_html( $dates); ?></h2>22 <h2><?php /* translators: date format, see http:php.net/date */ echo date_i18n( __( 'l, F jS Y' , 'wordcamporg' ) , strtotime ( $dates ) ); ?></h2> 23 23 <?php endif; ?> 24 24 25 25 <p id="wccsp-introduction"> 26 <?php echo esc_attr( get_bloginfo( 'name' ) ); ?> is in the early planning stages. In the meantime, you can subscribe to be notified when the site goes live, or contact the organizers to get involved. 26 <?php $blogname = esc_html( get_bloginfo( 'name' ) ); ?> 27 <?php /* translators: %s is the name of the blog */ printf( __( '%s is in the early planning stages. In the meantime, you can subscribe to be notified when the site goes live, or contact the organizers to get involved.' ), $blogname ); ?> 27 28 </p> 28 29 29 30 <?php if ( in_array( 'subscriptions', $active_modules ) ) : ?> … … 34 35 35 36 <?php if ( in_array( 'contact-form', $active_modules ) && $contact_form_shortcode ) : ?> 36 37 <div class="wccsp-box"> 37 <h2> Contact the Organizers</h2>38 <h2><?php _e( 'Contact the Organizers' , 'wordcamporg'); ?></h2> 38 39 39 40 <?php echo $contact_form_shortcode; // intentionally not escaping because it's the output of do_shortcode() ?> 40 41 </div> -
.