diff options
author | donncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36> | 2006-06-22 18:31:50 +0000 |
---|---|---|
committer | donncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36> | 2006-06-22 18:31:50 +0000 |
commit | d48e85e0ac5e675ca33fac173f30c75403d1033f (patch) | |
tree | 1164430fa3b83a4d9283961b09c1576f2885e6b2 /wp-admin/dbx-admin-key-js.php | |
parent | 086dcde66603301531efc6d8087bd06d0546f148 (diff) | |
download | wordpress-mu-d48e85e0ac5e675ca33fac173f30c75403d1033f.tar.gz wordpress-mu-d48e85e0ac5e675ca33fac173f30c75403d1033f.tar.xz wordpress-mu-d48e85e0ac5e675ca33fac173f30c75403d1033f.zip |
Moved everything in wp-inst down a directory.
Uses's Ryan Boren's htaccess rules and mods
If you're upgrading, try this on a test server first!
git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@591 7be80a69-a1ef-0310-a953-fb0f7c49ff36
Diffstat (limited to 'wp-admin/dbx-admin-key-js.php')
-rw-r--r-- | wp-admin/dbx-admin-key-js.php | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/wp-admin/dbx-admin-key-js.php b/wp-admin/dbx-admin-key-js.php new file mode 100644 index 0000000..bca04ce --- /dev/null +++ b/wp-admin/dbx-admin-key-js.php @@ -0,0 +1,68 @@ +<?php +require_once('admin.php'); +header('Content-type: text/javascript; charset=' . get_settings('blog_charset'), true); + +switch ( $_GET['pagenow'] ) : + case 'post.php' : + case 'post-new.php' : + $man = 'postmeta'; + break; + case 'page.php' : + case 'page-new.php' : + $man = 'pagemeta'; + break; + case 'link.php' : + $man = 'linkmeta'; + break; + default: + exit; + break; +endswitch; +?> +addLoadEvent( function() {var manager = new dbxManager('<?php echo $man; ?>');} ); + +addLoadEvent( function() +{ + //create new docking boxes group + var meta = new dbxGroup( + 'grabit', // container ID [/-_a-zA-Z0-9/] + 'vertical', // orientation ['vertical'|'horizontal'] + '10', // drag threshold ['n' pixels] + 'no', // restrict drag movement to container axis ['yes'|'no'] + '10', // animate re-ordering [frames per transition, or '0' for no effect] + 'yes', // include open/close toggle buttons ['yes'|'no'] + 'closed', // default state ['open'|'closed'] + 'open', // word for "open", as in "open this box" + 'close', // word for "close", as in "close this box" + 'click-down and drag to move this box', // sentence for "move this box" by mouse + 'click to %toggle% this box', // pattern-match sentence for "(open|close) this box" by mouse + 'use the arrow keys to move this box', // sentence for "move this box" by keyboard + ', or press the enter key to %toggle% it', // pattern-match sentence-fragment for "(open|close) this box" by keyboard + '%mytitle% [%dbxtitle%]' // pattern-match syntax for title-attribute conflicts + ); + + // Boxes are closed by default. Open the Category box if the cookie isn't already set. + var catdiv = document.getElementById('categorydiv'); + if ( catdiv ) { + var button = catdiv.getElementsByTagName('A')[0]; + if ( dbx.cookiestate == null && /dbx\-toggle\-closed/.test(button.className) ) + meta.toggleBoxState(button, true); + } + + var advanced = new dbxGroup( + 'advancedstuff', // container ID [/-_a-zA-Z0-9/] + 'vertical', // orientation ['vertical'|'horizontal'] + '10', // drag threshold ['n' pixels] + 'yes', // restrict drag movement to container axis ['yes'|'no'] + '10', // animate re-ordering [frames per transition, or '0' for no effect] + 'yes', // include open/close toggle buttons ['yes'|'no'] + 'closed', // default state ['open'|'closed'] + 'open', // word for "open", as in "open this box" + 'close', // word for "close", as in "close this box" + 'click-down and drag to move this box', // sentence for "move this box" by mouse + 'click to %toggle% this box', // pattern-match sentence for "(open|close) this box" by mouse + 'use the arrow keys to move this box', // sentence for "move this box" by keyboard + ', or press the enter key to %toggle% it', // pattern-match sentence-fragment for "(open|close) this box" by keyboard + '%mytitle% [%dbxtitle%]' // pattern-match syntax for title-attribute conflicts + ); +}); |