diff --git a/wp-admin/css/quick-post.css b/wp-admin/css/quick-post.css new file mode 100644 index 0000000000..7ee22329da --- /dev/null +++ b/wp-admin/css/quick-post.css @@ -0,0 +1,342 @@ +/* jquery tabs css */ + +/* Caution! Ensure accessibility in print and other media types... */ +@media projection, screen { /* Use class for showing/hiding tab content, so that visibility can be better controlled in different media types... */ + .ui-tabs-hide { + display: none; + } +} + +/* Hide useless elements in print layouts... */ +@media print { + .ui-tabs-nav { + display: none; + } +} + +/* Skin */ +.ui-tabs-nav, .ui-tabs-panel { + font-family: "Trebuchet MS", Trebuchet, Verdana, Helvetica, Arial, sans-serif; + font-size: 12px; +} +.ui-tabs-nav { + list-style: none; + margin: 0; + padding: 0 0 0 4px; +} +.ui-tabs-nav:after { /* clearing without presentational markup, IE gets extra treatment */ + display: block; + clear: both; + content: " "; +} +.ui-tabs-nav li { + float: left; + margin: 0 0 0 1px; + min-width: 84px; /* be nice to Opera */ +} +.ui-tabs-nav a, .ui-tabs-nav a span { + display: block; + padding: 0 10px; + background: url(../images/tab.png) no-repeat; +} +.ui-tabs-nav a { + margin: 1px 0 0; /* position: relative makes opacity fail for disabled tab in IE */ + padding-left: 0; + color: #27537a; + font-weight: bold; + line-height: 1.2; + text-align: center; + text-decoration: none; + white-space: nowrap; /* required in IE 6 */ + outline: 0; /* prevent dotted border in Firefox */ +} +.ui-tabs-nav .ui-tabs-selected a { + position: relative; + top: 1px; + z-index: 2; + margin-top: 0; + color: #000; +} +.ui-tabs-nav a span { + width: 64px; /* IE 6 treats width as min-width */ + min-width: 64px; + height: 18px; /* IE 6 treats height as min-height */ + min-height: 18px; + padding-top: 6px; + padding-right: 0; +} +*>.ui-tabs-nav a span { /* hide from IE 6 */ + width: auto; + height: auto; +} +.ui-tabs-nav .ui-tabs-selected a span { + padding-bottom: 1px; +} +.ui-tabs-nav .ui-tabs-selected a, .ui-tabs-nav a:hover, .ui-tabs-nav a:focus, .ui-tabs-nav a:active { + background-position: 100% -150px; +} +.ui-tabs-nav a, .ui-tabs-nav .ui-tabs-disabled a:hover, .ui-tabs-nav .ui-tabs-disabled a:focus, .ui-tabs-nav .ui-tabs-disabled a:active { + background-position: 100% -100px; +} +.ui-tabs-nav .ui-tabs-selected a span, .ui-tabs-nav a:hover span, .ui-tabs-nav a:focus span, .ui-tabs-nav a:active span { + background-position: 0 -50px; +} +.ui-tabs-nav a span, .ui-tabs-nav .ui-tabs-disabled a:hover span, .ui-tabs-nav .ui-tabs-disabled a:focus span, .ui-tabs-nav .ui-tabs-disabled a:active span { + background-position: 0 0; +} +.ui-tabs-nav .ui-tabs-selected a:link, .ui-tabs-nav .ui-tabs-selected a:visited, .ui-tabs-nav .ui-tabs-disabled a:link, .ui-tabs-nav .ui-tabs-disabled a:visited { /* @ Opera, use pseudo classes otherwise it confuses cursor... */ + cursor: text; +} +.ui-tabs-nav a:hover, .ui-tabs-nav a:focus, .ui-tabs-nav a:active, +.ui-tabs-nav .ui-tabs-unselect a:hover, .ui-tabs-nav .ui-tabs-unselect a:focus, .ui-tabs-nav .ui-tabs-unselect a:active { /* @ Opera, we need to be explicit again here now... */ + cursor: pointer; +} +.ui-tabs-disabled { + opacity: .4; + filter: alpha(opacity=40); +} +.ui-tabs-panel { + border-top: 1px solid #97a5b0; + padding: 1em 8px; + background: #fff; /* declare background color for container to avoid distorted fonts in IE while fading */ +} +.ui-tabs-loading em { + padding: 0 0 0 20px; + background: url(loading.gif) no-repeat 0 50%; +} + +/* Additional IE specific bug fixes... */ +* html .ui-tabs-nav { /* auto clear, @ IE 6 & IE 7 Quirks Mode */ + display: inline-block; +} +*:first-child+html .ui-tabs-nav { /* @ IE 7 Standards Mode - do not group selectors, otherwise IE 6 will ignore complete rule (because of the unknown + combinator)... */ + display: inline-block; +} + +/* end jquery tabs css */ +/* jquery thickbox css */ +/* ----------------------------------------------------------------------------------------------------------------*/ +/* ---------->>> global settings needed for thickbox <<<-----------------------------------------------------------*/ +/* ----------------------------------------------------------------------------------------------------------------*/ +*{padding: 0; margin: 0;} + +/* ----------------------------------------------------------------------------------------------------------------*/ +/* ---------->>> thickbox specific link and font settings <<<------------------------------------------------------*/ +/* ----------------------------------------------------------------------------------------------------------------*/ +#TB_window { + font: 12px Arial, Helvetica, sans-serif; + color: #333333; +} + +#TB_secondLine { + font: 10px Arial, Helvetica, sans-serif; + color:#666666; +} + +#TB_window a:link {color: #666666;} +#TB_window a:visited {color: #666666;} +#TB_window a:hover {color: #000;} +#TB_window a:active {color: #666666;} +#TB_window a:focus{color: #666666;} + +/* ----------------------------------------------------------------------------------------------------------------*/ +/* ---------->>> thickbox settings <<<-----------------------------------------------------------------------------*/ +/* ----------------------------------------------------------------------------------------------------------------*/ +#TB_overlay { + position: fixed; + z-index:100; + top: 0px; + left: 0px; + background-color:#000; + filter:alpha(opacity=75); + -moz-opacity: 0.75; + opacity: 0.75; + height:100%; + width:100%; +} + +* html #TB_overlay { /* ie6 hack */ + position: absolute; + height: expression(document.body.scrollHeight > document.body.offsetHeight ? document.body.scrollHeight : document.body.offsetHeight + 'px'); +} + +#TB_window { + position: fixed; + background: #ffffff; + z-index: 102; + color:#000000; + display:none; + border: 4px solid #525252; + text-align:left; + top:50%; + left:50%; +} + +* html #TB_window { /* ie6 hack */ +position: absolute; +margin-top: expression(0 - parseInt(this.offsetHeight / 2) + (TBWindowMargin = document.documentElement && document.documentElement.scrollTop || document.body.scrollTop) + 'px'); +} + +#TB_window img#TB_Image { + display:block; + margin: 15px 0 0 15px; + border-right: 1px solid #ccc; + border-bottom: 1px solid #ccc; + border-top: 1px solid #666; + border-left: 1px solid #666; +} + +#TB_caption{ + height:25px; + padding:7px 30px 10px 25px; + float:left; +} + +#TB_closeWindow{ + height:25px; + padding:11px 25px 10px 0; + float:right; +} + +#TB_closeAjaxWindow{ + padding:7px 10px 5px 0; + margin-bottom:1px; + text-align:right; + float:right; +} + +#TB_ajaxWindowTitle{ + float:left; + padding:7px 0 5px 10px; + margin-bottom:1px; +} + +#TB_title{ + background-color:#e8e8e8; + height:27px; +} + +#TB_ajaxContent{ + clear:both; + padding:2px 15px 15px 15px; + overflow:auto; + text-align:left; + line-height:1.4em; +} + +#TB_ajaxContent.TB_modal{ + padding:15px; +} + +#TB_ajaxContent p{ + padding:5px 0px 5px 0px; +} + +#TB_load{ + position: fixed; + display:none; + height:13px; + width:208px; + z-index:103; + top: 50%; + left: 50%; + margin: -6px 0 0 -104px; /* -height/2 0 0 -width/2 */ +} + +* html #TB_load { /* ie6 hack */ +position: absolute; +margin-top: expression(0 - parseInt(this.offsetHeight / 2) + (TBWindowMargin = document.documentElement && document.documentElement.scrollTop || document.body.scrollTop) + 'px'); +} + +#TB_HideSelect{ + z-index:99; + position:fixed; + top: 0; + left: 0; + background-color:#fff; + border:none; + filter:alpha(opacity=0); + -moz-opacity: 0; + opacity: 0; + height:100%; + width:100%; +} + +* html #TB_HideSelect { /* ie6 hack */ + position: absolute; + height: expression(document.body.scrollHeight > document.body.offsetHeight ? document.body.scrollHeight : document.body.offsetHeight + 'px'); +} + +#TB_iframeContent{ + clear:both; + border:none; + margin-bottom:-1px; + margin-top:1px; + _margin-bottom:1px; +} +/* end jquery thickbox css */ + +/* quickpost css */ +div#container { + background-color: #fff; + padding: 0px 15px 0px 15px; + +} + +div#container h2 { + margin: 15px 0px 0px 0px; + font-size: 15px; +} + +div#container h2 span.optional { + font-size: 10px; + color: #bbb; + font-style: italic; + font-weight: normal; +} + +div#container form { + margin: 0px; + padding: 0px; +} + +div#categories { + float:right; + width:30%; + padding: 0px 5px 0px 5px; +} + +div#posting { + float:left; + width:65%; + padding: 0px 5px 0px 5px; +} + +textarea, input.text { + font: Normal 12px 'Lucida Grande', Verdana, Helvetica, sans-serif; + border: solid 1px #ccc; + background-color: #f4f4f4; +} + +input.text { + width: 100%; +} + +body { + background-color: #fff; + margin: 0px; + padding: 5px; + font: Normal 13px 'Lucida Grande', Verdana, Helvetica, sans-serif; +} + +a { + color: #007BFF; +} + +#categories ul { + list-style: none; + padding: 0; + margin: 0; +} + +/* end quickpost css */ \ No newline at end of file diff --git a/wp-admin/edit-form-advanced.php b/wp-admin/edit-form-advanced.php index 188b95135f..c623225ef7 100644 --- a/wp-admin/edit-form-advanced.php +++ b/wp-admin/edit-form-advanced.php @@ -189,6 +189,9 @@ if ( ( 'edit' == $action) && current_user_can('delete_post', $post_ID) )
' . $_REQUEST['content']; + if ($_REQUEST['content2']) { + $content = $content . ''; + $content = $content . '
' . $_REQUEST['content2'];
+ }
+ break;
+
+ case 'photo':
+ if ($_REQUEST['photo_link'])
+ $content = '';
+
+ $content .= '';
+
+ if ($_REQUEST['photo_link'])
+ $content .= '';
+
+ if ($_REQUEST['content'])
+ $content = $content . "
" . $_REQUEST['content'];
+
+ break;
+ case "video":
+ list($garbage,$video_id) = split("v=", $_REQUEST['content']);
+ $content = "";
+ if ($_REQUEST['content2'])
+ $content = $content ."
" .$_REQUEST['content2'] ."
"; + break; + } + + $quick['post_content'] = $content; + + $post_ID = wp_insert_post($quick, true); + + if ( is_wp_error($post_ID) ) + wp_die($wp_error); + + return $post_ID; +} + +function tag_input() { + $s = '