]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-admin/custom-background.php
Wordpress 3.1.3
[autoinstalls/wordpress.git] / wp-admin / custom-background.php
index 413c564fd02acdd2cee1c7e2be5786b5bafa1085..530cb9e4a567ca13f70c4761c706b9ed89e36176 100644 (file)
@@ -19,7 +19,7 @@ class Custom_Background {
         * Callback for administration header.
         *
         * @var callback
-        * @since unknown
+        * @since 3.0.0
         * @access private
         */
        var $admin_header_callback;
@@ -210,7 +210,7 @@ if ( get_background_image() ) {
 <td>
 <form method="post" action="">
 <?php wp_nonce_field('custom-background-remove', '_wpnonce-custom-background-remove'); ?>
-<input type="submit" class="button" name="remove-background" value="<?php esc_attr_e('Remove Background Image'); ?>" /><br/>
+<?php submit_button( __( 'Remove Background Image' ), 'button', 'remove-background', false ); ?><br/>
 <?php _e('This will remove the background image. You will not be able to restore any customizations.') ?>
 </form>
 </td>
@@ -223,7 +223,7 @@ if ( get_background_image() ) {
 <td>
 <form method="post" action="">
 <?php wp_nonce_field('custom-background-reset', '_wpnonce-custom-background-reset'); ?>
-<input type="submit" class="button" name="reset-background" value="<?php esc_attr_e('Restore Original Image'); ?>" /><br/>
+<?php submit_button( __( 'Restore Original Image' ), 'button', 'reset-background', false ); ?><br/>
 <?php _e('This will restore the original background image. You will not be able to restore any customizations.') ?>
 </form>
 </td>
@@ -236,7 +236,7 @@ if ( get_background_image() ) {
 <label for="upload"><?php _e('Choose an image from your computer:'); ?></label><br /><input type="file" id="upload" name="import" />
 <input type="hidden" name="action" value="save" />
 <?php wp_nonce_field('custom-background-upload', '_wpnonce-custom-background-upload') ?>
-<input type="submit" class="button" value="<?php esc_attr_e('Upload'); ?>" />
+<?php submit_button( __( 'Upload' ), 'button', 'submit', false ); ?>
 </p>
 </form>
 </td>
@@ -303,7 +303,7 @@ if ( get_background_image() ) {
 </table>
 
 <?php wp_nonce_field('custom-background'); ?>
-<p class="submit"><input type="submit" class="button-primary" name="save-background-options" value="<?php esc_attr_e('Save Changes'); ?>" /></p>
+<?php submit_button( null, 'primary', 'save-background-options' ); ?>
 </form>
 
 </div>
@@ -311,7 +311,7 @@ if ( get_background_image() ) {
        }
 
        /**
-        * Handle a Image upload for the background image.
+        * Handle an Image upload for the background image.
         *
         * @since 3.0.0
         */
@@ -337,7 +337,8 @@ if ( get_background_image() ) {
                        'post_title' => $filename,
                        'post_content' => $url,
                        'post_mime_type' => $type,
-                       'guid' => $url
+                       'guid' => $url,
+                       'context' => 'custom-background'
                );
 
                // Save the data