Changeset 1340
- Timestamp:
- 05/22/2004 08:45:36 AM (21 years ago)
- Location:
- trunk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/admin-footer.php
r1144 r1340 5 5 ?> 6 6 </p> 7 7 <?php do_action('admin_footer', ''); ?> 8 8 </body> 9 9 </html> -
trunk/wp-admin/admin-functions.php
r1324 r1340 1 1 <?php 2 3 function wp_admin_head() {4 do_action('wp_head', '');5 }6 2 7 3 function url_shorten ($url) { -
trunk/wp-admin/admin-header.php
r1236 r1340 131 131 <?php endif; ?> 132 132 133 <?php wp_admin_head(); ?>133 <?php do_action('admin_head', ''); ?> 134 134 </head> 135 135 <body> -
trunk/wp-content/plugins/hello.php
r1108 r1340 3 3 Plugin Name: Hello Dolly 4 4 Plugin URI: http://wordpress.org/# 5 Description: This is not just a plugin, it symbolizes the hope and enthusiasm of an entire generation summed up in two words sung most famously by Louis Armstrong. Hello, Dolly. This is, by the way, the world's first official WordPress plugin. When enabled you will randomly see a lyric from <cite>Hello, Dolly</cite> in the upper right of your admin screen .5 Description: This is not just a plugin, it symbolizes the hope and enthusiasm of an entire generation summed up in two words sung most famously by Louis Armstrong. Hello, Dolly. This is, by the way, the world's first official WordPress plugin. When enabled you will randomly see a lyric from <cite>Hello, Dolly</cite> in the upper right of your admin screen on every page but the plugins page. 6 6 Author: Matt Mullenweg 7 7 Author URI: http://photomatt.net/ 8 8 */ 9 9 10 // These are the lyrics to Hello Dolly 11 $lyrics = "Hello, Dolly 12 Well, hello, Dolly 13 It's so nice to have you back where you belong 14 You're lookin' swell, Dolly 15 I can tell, Dolly 16 You're still glowin', you're still crowin' 17 You're still goin' strong 18 We feel the room swayin' 19 While the band's playin' 20 One of your old favourite songs from way back when 21 So, take her wrap, fellas 22 Find her an empty lap, fellas 23 Dolly'll never go away again 24 Hello, Dolly 25 Well, hello, Dolly 26 It's so nice to have you back where you belong 27 You're lookin' swell, Dolly 28 I can tell, Dolly 29 You're still glowin', you're still crowin' 30 You're still goin' strong 31 We feel the room swayin' 32 While the band's playin' 33 One of your old favourite songs from way back when 34 Golly, gee, fellas 35 Find her a vacant knee, fellas 36 Dolly'll never go away 37 Dolly'll never go away 38 Dolly'll never go away again"; 39 40 // Here we split it into lines 41 $lyrics = explode("\n", $lyrics); 42 // And then randomly choose a line 43 $chosen = wptexturize( $lyrics[ mt_rand(0, count($lyrics) ) ] ); 44 45 // This just echoes the chosen line, we'll position it later 10 46 function hello_dolly() { 11 echo "It's me, Dolly."; 47 global $chosen; 48 echo "<p id='dolly'>$chosen</p>"; 12 49 } 50 51 // Now we set that function up to execute when the admin_footer action is called 52 add_action('admin_footer', 'hello_dolly'); 53 54 // We need some CSS to position the paragraph 55 function dolly_css() { 56 echo " 57 <style type='text/css'> 58 #dolly { 59 position: absolute; 60 top: 5px; 61 margin: 0; padding: 0; 62 right: 3em; 63 font-size: 20px; 64 color: #666; 65 } 66 </style> 67 "; 68 } 69 70 add_action('admin_head', 'dolly_css'); 71 13 72 ?>
Note: See TracChangeset
for help on using the changeset viewer.