diff options
| author | donncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36> | 2005-07-12 11:27:54 +0000 |
|---|---|---|
| committer | donncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36> | 2005-07-12 11:27:54 +0000 |
| commit | 4f3bce79bfb5851cef9e7bc655c91bb3093cc401 (patch) | |
| tree | 10a0991fddeb0e075d7fa46e2b40e5dbc64d1e88 /wp-inst/wp-admin/admin-header.php | |
| download | wordpress-mu-4f3bce79bfb5851cef9e7bc655c91bb3093cc401.tar.gz wordpress-mu-4f3bce79bfb5851cef9e7bc655c91bb3093cc401.tar.xz wordpress-mu-4f3bce79bfb5851cef9e7bc655c91bb3093cc401.zip | |
Initial Import
git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@1 7be80a69-a1ef-0310-a953-fb0f7c49ff36
Diffstat (limited to 'wp-inst/wp-admin/admin-header.php')
| -rw-r--r-- | wp-inst/wp-admin/admin-header.php | 104 |
1 files changed, 104 insertions, 0 deletions
diff --git a/wp-inst/wp-admin/admin-header.php b/wp-inst/wp-admin/admin-header.php new file mode 100644 index 0000000..fb52818 --- /dev/null +++ b/wp-inst/wp-admin/admin-header.php @@ -0,0 +1,104 @@ +<?php +@header('Content-type: ' . get_option('html_type') . '; charset=' . get_option('blog_charset')); +if (!isset($_GET["page"])) require_once('admin.php'); ?> +<?php get_admin_page_title(); ?> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> +<title><?php bloginfo('name') ?> › <?php echo $title; ?> — WordPress</title> +<link rel="stylesheet" href="<?php echo get_settings('siteurl') ?>/wp-admin/wp-admin.css?version=<?php bloginfo('version'); ?>" type="text/css" /> +<meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php echo get_settings('blog_charset'); ?>" /> + +<script type="text/javascript"> +//<![CDATA[ + +function customToggleLink() { + // TODO: Only show link if there's a hidden row + document.write('<small>(<a href="javascript:;" id="customtoggle" onclick="toggleHidden()"><?php _e('Show hidden'); ?></a>)</small>'); + // TODO: Rotate link to say "show" or "hide" + // TODO: Use DOM +} + +function toggleHidden() { + var allElements = document.getElementsByTagName('tr'); + for (i = 0; i < allElements.length; i++) { + if ( allElements[i].className.indexOf('hidden') != -1 ) { + allElements[i].className = allElements[i].className.replace('hidden', ''); + } + } +} + +<?php if ( isset($xfn) ) : ?> + +function GetElementsWithClassName(elementName, className) { + var allElements = document.getElementsByTagName(elementName); + var elemColl = new Array(); + for (i = 0; i < allElements.length; i++) { + if (allElements[i].className == className) { + elemColl[elemColl.length] = allElements[i]; + } + } + return elemColl; +} + +function meChecked() { + var undefined; + var eMe = document.getElementById('me'); + if (eMe == undefined) return false; + else return eMe.checked; +} + +function upit() { + var isMe = meChecked(); //document.getElementById('me').checked; + var inputColl = GetElementsWithClassName('input', 'valinp'); + var results = document.getElementById('rel'); + var linkText, linkUrl, inputs = ''; + for (i = 0; i < inputColl.length; i++) { + inputColl[i].disabled = isMe; + inputColl[i].parentNode.className = isMe ? 'disabled' : ''; + if (!isMe && inputColl[i].checked && inputColl[i].value != '') { + inputs += inputColl[i].value + ' '; + } + } + inputs = inputs.substr(0,inputs.length - 1); + if (isMe) inputs='me'; + results.value = inputs; + } + +function blurry() { + if (!document.getElementById) return; + + var aInputs = document.getElementsByTagName('input'); + + for (var i = 0; i < aInputs.length; i++) { + aInputs[i].onclick = aInputs[i].onkeyup = upit; + } +} + +window.onload = blurry; +<?php endif; ?> + + +//]]> +</script> + +<?php if ( isset( $editing ) ) : ?> +<script type="text/javascript" src="dbx.js"></script> +<script type="text/javascript" src="dbx-key.js"></script> +<?php endif; ?> + +<?php do_action('admin_head', ''); ?> +</head> +<body> + +<div id="wphead"> +<h1><?php echo wptexturize(get_settings(('blogname'))); ?> <span>(<a href="<?php echo get_settings('home') . '/'; ?>"><?php _e('View site') ?> »</a>)</span></h1> +</div> + +<?php +require(ABSPATH . '/wp-admin/menu-header.php'); + +if ( $parent_file == 'options-general.php' ) { + require(ABSPATH . '/wp-admin/options-head.php'); +} +?> |
