Fix flash upload button, right sidebar on write pages in IE6
git-svn-id: http://svn.automattic.com/wordpress/trunk@10865 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
93c512ded4
commit
8c7f6cb6ee
|
@ -112,7 +112,6 @@ table {
|
|||
}
|
||||
|
||||
/* inner 2 column liquid layout */
|
||||
|
||||
.inner-sidebar {
|
||||
float: right;
|
||||
clear: right;
|
||||
|
@ -130,6 +129,13 @@ table {
|
|||
}
|
||||
|
||||
.has-right-sidebar #post-body {
|
||||
float: left;
|
||||
clear: left;
|
||||
width: 100%;
|
||||
margin-right: -340px;
|
||||
}
|
||||
|
||||
.has-right-sidebar #post-body-content {
|
||||
margin-right: 300px;
|
||||
}
|
||||
|
||||
|
|
|
@ -592,6 +592,7 @@ else
|
|||
</div>
|
||||
|
||||
<div id="post-body">
|
||||
<div id="post-body-content">
|
||||
<div id="titlediv">
|
||||
<div id="titlewrap">
|
||||
<input type="text" name="post_title" size="30" tabindex="1" value="<?php echo attribute_escape( htmlspecialchars( $post->post_title ) ); ?>" id="title" autocomplete="off" />
|
||||
|
@ -651,6 +652,7 @@ do_action('dbx_post_sidebar');
|
|||
|
||||
?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<br class="clear" />
|
||||
</div><!-- /poststuff -->
|
||||
|
|
|
@ -82,6 +82,7 @@ $date = date_i18n( $datef, strtotime( $comment->comment_date ) );
|
|||
</div>
|
||||
|
||||
<div id="post-body">
|
||||
<div id="post-body-content">
|
||||
<div id="namediv" class="stuffbox">
|
||||
<h3><label for="name"><?php _e( 'Author' ) ?></label></h3>
|
||||
<div class="inside">
|
||||
|
@ -136,6 +137,7 @@ $date = date_i18n( $datef, strtotime( $comment->comment_date ) );
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
<script type="text/javascript">
|
||||
|
|
|
@ -370,6 +370,7 @@ $side_meta_boxes = do_meta_boxes( 'link', 'side', $link );
|
|||
</div>
|
||||
|
||||
<div id="post-body">
|
||||
<div id="post-body-content">
|
||||
<div id="namediv" class="stuffbox">
|
||||
<h3><label for="link_name"><?php _e('Name') ?></label></h3>
|
||||
<div class="inside">
|
||||
|
@ -409,6 +410,7 @@ if ( $link_id ) : ?>
|
|||
<input type="hidden" name="action" value="add" />
|
||||
<?php endif; ?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
|
|
@ -439,6 +439,7 @@ $side_meta_boxes = do_meta_boxes('page', 'side', $post);
|
|||
</div>
|
||||
|
||||
<div id="post-body">
|
||||
<div id="post-body-content">
|
||||
<div id="titlediv">
|
||||
<div id="titlewrap">
|
||||
<input type="text" name="post_title" size="30" tabindex="1" value="<?php echo attribute_escape( htmlspecialchars( $post->post_title ) ); ?>" id="title" autocomplete="off" />
|
||||
|
@ -489,6 +490,7 @@ do_meta_boxes('page', 'advanced', $post);
|
|||
|
||||
?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
|
|
@ -303,11 +303,11 @@ wp_enqueue_style( 'wp-admin' );
|
|||
wp_enqueue_style( 'colors' );
|
||||
if ( 0 === strpos( $content_func, 'media' ) )
|
||||
wp_enqueue_style( 'media' );
|
||||
|
||||
wp_enqueue_style( 'ie' );
|
||||
?>
|
||||
<script type="text/javascript">
|
||||
//<![CDATA[
|
||||
function addLoadEvent(func) {if ( typeof wpOnload!='function'){wpOnload=func;}else{ var oldonload=wpOnload;wpOnload=function(){oldonload();func();}}}
|
||||
addLoadEvent = function(func){if(typeof jQuery!="undefined")jQuery(document).ready(func);else if(typeof wpOnload!='function'){wpOnload=func;}else{var oldonload=wpOnload;wpOnload=function(){oldonload();func();}}};
|
||||
var userSettings = {'url':'<?php echo SITECOOKIEPATH; ?>','uid':'<?php if ( ! isset($current_user) ) $current_user = wp_get_current_user(); echo $current_user->ID; ?>','time':'<?php echo time() ?>'};
|
||||
//]]>
|
||||
</script>
|
||||
|
@ -325,6 +325,7 @@ if ( is_string($content_func) )
|
|||
$args = array_slice($args, 1);
|
||||
call_user_func_array($content_func, $args);
|
||||
?>
|
||||
<script type="text/javascript">if(typeof wpOnload=='function')wpOnload();</script>
|
||||
</body>
|
||||
</html>
|
||||
<?php
|
||||
|
@ -1268,12 +1269,14 @@ function media_upload_form( $errors = null ) {
|
|||
|
||||
?>
|
||||
<script type="text/javascript">
|
||||
//<!--
|
||||
//<![CDATA[
|
||||
var uploaderMode = 0;
|
||||
jQuery(document).ready(function($){
|
||||
$('.upload-html-bypass a').click(function(){deleteUserSetting('uploader');swfuploadPreLoad(0);return false;});
|
||||
$('.upload-flash-bypass a').click(function(){setUserSetting('uploader', '1');swfuploadPreLoad(1);return false;});
|
||||
uploaderMode = getUserSetting('uploader');
|
||||
$('.upload-html-bypass a').click(function(){deleteUserSetting('uploader');uploaderMode=0;swfuploadPreLoad();return false;});
|
||||
$('.upload-flash-bypass a').click(function(){setUserSetting('uploader', '1');uploaderMode=1;swfuploadPreLoad();return false;});
|
||||
});
|
||||
//-->
|
||||
//]]>
|
||||
</script>
|
||||
<div id="media-upload-notice">
|
||||
<?php if (isset($errors['upload_notice']) ) { ?>
|
||||
|
@ -1290,7 +1293,7 @@ jQuery(document).ready(function($){
|
|||
|
||||
<?php if ( $flash ) : ?>
|
||||
<script type="text/javascript">
|
||||
<!--
|
||||
//<![CDATA[
|
||||
SWFUpload.onload = function() {
|
||||
swfu = new SWFUpload({
|
||||
button_text: '<span class="button"><?php _e('Select Files'); ?></span>',
|
||||
|
@ -1330,7 +1333,7 @@ SWFUpload.onload = function() {
|
|||
debug: false
|
||||
});
|
||||
};
|
||||
//-->
|
||||
//]]>
|
||||
</script>
|
||||
|
||||
<div id="flash-upload-ui">
|
||||
|
|
|
@ -1411,7 +1411,6 @@ table.form-table td .updated {
|
|||
}
|
||||
|
||||
#post-status-info {
|
||||
font-size: 12px;
|
||||
line-height: 2;
|
||||
border-width: 0 1px 1px;
|
||||
border-style: none solid solid;
|
||||
|
@ -1425,6 +1424,10 @@ table.form-table td .updated {
|
|||
border-bottom-right-radius: 6px;
|
||||
}
|
||||
|
||||
#post-status-info td {
|
||||
font-size: 11px;
|
||||
}
|
||||
|
||||
.autosave-info {
|
||||
padding: 2px 15px 2px 2px;
|
||||
text-align: right;
|
||||
|
@ -1444,7 +1447,7 @@ table.form-table td .updated {
|
|||
margin: 0 2px;
|
||||
position: relative;
|
||||
right: 0;
|
||||
top: 31px;
|
||||
top: 29px;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -206,20 +206,28 @@ function fileDialogComplete(num_files_queued) {
|
|||
}
|
||||
}
|
||||
|
||||
function swfuploadPreLoad(a) {
|
||||
if ( typeof(a) == 'undefined' && typeof(getUserSetting) == 'function' )
|
||||
a = getUserSetting('uploader');
|
||||
function switchUploader(s) {
|
||||
var f = document.getElementById(swfu.customSettings.swfupload_element_id), h = document.getElementById(swfu.customSettings.degraded_element_id);
|
||||
if ( s ) {
|
||||
f.style.display = 'block';
|
||||
h.style.display = 'none';
|
||||
} else {
|
||||
f.style.display = 'none';
|
||||
h.style.display = 'block';
|
||||
}
|
||||
}
|
||||
|
||||
if ( !a ) {
|
||||
jQuery('#' + swfu.customSettings.swfupload_element_id).show();
|
||||
jQuery('#' + swfu.customSettings.degraded_element_id).hide();
|
||||
} else
|
||||
swfuploadLoadFailed();
|
||||
function swfuploadPreLoad() {
|
||||
if ( !uploaderMode ) {
|
||||
switchUploader(1);
|
||||
} else {
|
||||
switchUploader(0);
|
||||
}
|
||||
}
|
||||
|
||||
function swfuploadLoadFailed() {
|
||||
jQuery('#' + swfu.customSettings.swfupload_element_id).hide();
|
||||
jQuery('#' + swfu.customSettings.degraded_element_id).show();
|
||||
switchUploader(0);
|
||||
jQuery('.upload-html-bypass').hide();
|
||||
}
|
||||
|
||||
function uploadError(fileObj, error_code, message) {
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -179,7 +179,7 @@ function wp_default_scripts( &$scripts ) {
|
|||
$scripts->add( 'swfupload-queue', false, array('swfupload') );
|
||||
}
|
||||
|
||||
$scripts->add( 'swfupload-handlers', "/wp-includes/js/swfupload/handlers$suffix.js", array('swfupload'), '2.2.0-20090327');
|
||||
$scripts->add( 'swfupload-handlers', "/wp-includes/js/swfupload/handlers$suffix.js", array('swfupload'), '2.2.0-20090403');
|
||||
// these error messages came from the sample swfupload js, they might need changing.
|
||||
$scripts->localize( 'swfupload-handlers', 'swfuploadL10n', array(
|
||||
'queue_limit_exceeded' => __('You have attempted to queue too many files.'),
|
||||
|
@ -425,7 +425,7 @@ function wp_default_styles( &$styles ) {
|
|||
|
||||
$rtl_styles = array( 'global', 'colors', 'dashboard', 'ie', 'install', 'login', 'media', 'theme-editor', 'upload', 'widgets', 'press-this', 'plugin-install', 'farbtastic' );
|
||||
|
||||
$styles->add( 'wp-admin', '/wp-admin/wp-admin.css', array(), '20081210' );
|
||||
$styles->add( 'wp-admin', '/wp-admin/wp-admin.css', array(), '20090403' );
|
||||
$styles->add_data( 'wp-admin', 'rtl', '/wp-admin/rtl.css' );
|
||||
|
||||
$styles->add( 'ie', '/wp-admin/css/ie.css', array(), '20081210' );
|
||||
|
@ -437,7 +437,7 @@ function wp_default_styles( &$styles ) {
|
|||
$styles->add( 'colors-classic', '/wp-admin/css/colors-classic.css', array(), '20081210');
|
||||
$styles->add_data( 'colors-classic', 'rtl', true );
|
||||
|
||||
$styles->add( 'global', '/wp-admin/css/global.css', array(), '20081226' );
|
||||
$styles->add( 'global', '/wp-admin/css/global.css', array(), '20090403' );
|
||||
$styles->add( 'media', '/wp-admin/css/media.css', array(), '20090325' );
|
||||
$styles->add( 'widgets', '/wp-admin/css/widgets.css', array(), '20081210' );
|
||||
$styles->add( 'dashboard', '/wp-admin/css/dashboard.css', array(), '20090305' );
|
||||
|
|
Loading…
Reference in New Issue