Ticket #7964: 7964.1.diff
File 7964.1.diff, 5.2 KB (added by , 16 years ago) |
---|
-
wp-admin/edit-pages.php
68 68 if ( empty($title) ) 69 69 $title = __('Edit Pages'); 70 70 $parent_file = 'edit.php'; 71 add_thickbox(); 71 72 wp_enqueue_script('admin-forms'); 73 wp_enqueue_script('inline-preview'); 72 74 wp_enqueue_script('inline-edit-post'); 73 75 wp_enqueue_script('pages'); 74 76 -
wp-admin/edit.php
69 69 if ( empty($title) ) 70 70 $title = __('Edit Posts'); 71 71 $parent_file = 'edit.php'; 72 add_thickbox(); 72 73 wp_enqueue_script('admin-forms'); 74 wp_enqueue_script('inline-preview'); 73 75 wp_enqueue_script('inline-edit-post'); 74 76 wp_enqueue_script('posts'); 75 77 -
wp-admin/includes/template.php
1277 1277 $actions['inline hide-if-no-js'] = '<a href="#" class="editinline" title="' . attribute_escape(__('Edit this post inline')) . '">' . __('Quick Edit') . '</a>'; 1278 1278 $actions['delete'] = "<a class='submitdelete' title='" . attribute_escape(__('Delete this post')) . "' href='" . wp_nonce_url("post.php?action=delete&post=$post->ID", 'delete-post_' . $post->ID) . "' onclick=\"if ( confirm('" . js_escape(sprintf( ('draft' == $post->post_status) ? __("You are about to delete this draft '%s'\n 'Cancel' to stop, 'OK' to delete.") : __("You are about to delete this post '%s'\n 'Cancel' to stop, 'OK' to delete."), $post->post_title )) . "') ) { return true;}return false;\">" . __('Delete') . "</a>"; 1279 1279 } 1280 if ( in_array($post->post_status, array('pending', 'draft')) ) 1281 $actions['view'] = '<a href="' . get_permalink($post->ID) . '" title="' . attribute_escape(sprintf(__('Preview "%s"'), $title)) . '" rel="permalink">' . __('Preview') . '</a>'; 1282 else 1280 if ( in_array($post->post_status, array('pending', 'draft')) ) { 1281 $preview_link = htmlspecialchars( add_query_arg( array('preview' => 1, 'template' => get_option('template') , 'stylesheet' => get_option('stylesheet'), 'TB_iframe' => 'true', 'width' => 600, 'height' => 400 ), get_permalink($post->ID) ) ); 1282 $actions['view'] = '<a class="thickbox" href="' . $preview_link . '" title="' . attribute_escape(sprintf(__('Preview "%s"'), $title)) . '" rel="permalink">' . __('Preview') . '</a>'; 1283 } else 1283 1284 $actions['view'] = '<a href="' . get_permalink($post->ID) . '" title="' . attribute_escape(sprintf(__('View "%s"'), $title)) . '" rel="permalink">' . __('View') . '</a>'; 1284 1285 $action_count = count($actions); 1285 1286 $i = 0; … … 1461 1462 $actions['edit'] = '<a href="' . $edit_link . '" title="' . attribute_escape(__('Edit this page')) . '">' . __('Edit') . '</a>'; 1462 1463 $actions['inline'] = '<a href="#" class="editinline">' . __('Quick Edit') . '</a>'; 1463 1464 $actions['delete'] = "<a class='submitdelete' title='" . attribute_escape(__('Delete this page')) . "' href='" . wp_nonce_url("page.php?action=delete&post=$page->ID", 'delete-page_' . $page->ID) . "' onclick=\"if ( confirm('" . js_escape(sprintf( ('draft' == $page->post_status) ? __("You are about to delete this draft '%s'\n 'Cancel' to stop, 'OK' to delete.") : __("You are about to delete this page '%s'\n 'Cancel' to stop, 'OK' to delete."), $page->post_title )) . "') ) { return true;}return false;\">" . __('Delete') . "</a>"; 1464 if ( in_array($post->post_status, array('pending', 'draft')) ) 1465 $actions['view'] = '<a href="' . get_permalink($page->ID) . '" title="' . attribute_escape(sprintf(__('Preview "%s"'), $title)) . '" rel="permalink">' . __('Preview') . '</a>'; 1466 else 1465 if ( in_array($post->post_status, array('pending', 'draft')) ) { 1466 $preview_link = htmlspecialchars( add_query_arg( array('preview' => 1, 'template' => get_option('template') , 'stylesheet' => get_option('stylesheet'), 'TB_iframe' => 'true', 'width' => 600, 'height' => 400 ), get_permalink($page->ID) ) ); 1467 $actions['view'] = '<a class="thickbox" href="' . $preview_link . '" title="' . attribute_escape(sprintf(__('Preview "%s"'), $title)) . '" rel="permalink">' . __('Preview') . '</a>'; 1468 } else 1467 1469 $actions['view'] = '<a href="' . get_permalink($page->ID) . '" title="' . attribute_escape(sprintf(__('View "%s"'), $title)) . '" rel="permalink">' . __('View') . '</a>'; 1468 1470 $action_count = count($actions); 1469 1471 $i = 0; -
wp-includes/script-loader.php
242 242 )); 243 243 244 244 $scripts->add( 'theme-preview', '/wp-admin/js/theme-preview.js', array( 'thickbox', 'jquery' ), '20080625' ); 245 245 $scripts->add( 'inline-preview', '/wp-admin/js/inline-preview.js', array( 'thickbox', 'jquery' ), '20081025' ); 246 246 247 $scripts->add( 'inline-edit-post', '/wp-admin/js/inline-edit-post.js', array( 'jquery', 'jquery-form', 'suggest' ), '20081023' ); 247 248 $scripts->localize( 'inline-edit-post', 'inlineEditL10n', array( 248 249 'error' => __('Error while saving the changes.')