Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /**
- * @package Hello_Tempz
- * @version 1.0
- */
- function hello_tempz_get_lyric() {
- /** These are the lyrics to Next Hype */
- $lyrics = "What kind of things that you have
- When I find out don't expect me to stop
- I'll come for the P's that you stack
- And come for all the food that you blot
- Better hand over the bag
- Your boys don't wanna see you shot
- If I kick down the door to your flat
- Dun Know I'll clear out your house on the spot
- (CLEAR!) All the things in your house
- (CLEAR!) All the things in your fridge
- (SMASH!) All your plates from your rack
- (CLEAR!) All of your kids' toys
- (CLEAR!) All of your CD rack
- Won't get none of your CD's back
- Drag off your curtain rail from the wall
- Kick off your HDTV from the stand
- Run up on stairs into rooms
- Flip the mattress and search for the cash
- Make man look down the barrel of a mash
- It's not worth your life, just cough up the scratch
- It's too late to lock up the latch
- I can smell the crow, just pull out the batch
- I'm not here to cotch or relax
- And drink your wine here just pull out the bags
- I have to punch up guys
- Guys try it with me, I don't know why
- Bax! Pax man straight in his eyes
- They floored me, I was looking at the sky
- Par! Now I have to go blind
- That boy there I swear he gonna die
- You're not bad you're a mug don't think you're a guy
- When I slap man you won't be alright
- Catch man on the field flying his kite
- Roll man down on the grass with a knife
- Watch as his friends disperse out of sight from afar
- I can hear screams from his wife
- Run after man let me draw for his life
- Blood's pouring I got stains off the knife
- Leave guys dead in the field over night
- I'm sick, when I dream I won't think of them twice";
- // Here we split it into lines
- $lyrics = explode( "\n", $lyrics );
- // And then randomly choose a line
- return wptexturize( $lyrics[ mt_rand( 0, count( $lyrics ) - 1 ) ] );
- }
- // This just echoes the chosen line, we'll position it later
- function hello_tempz() {
- $chosen = hello_tempz_get_lyric();
- echo "<p id='dolly'>$chosen</p>";
- }
- // Now we set that function up to execute when the admin_notices action is called
- add_action( 'admin_notices', 'hello_tempz' );
- // We need some CSS to position the paragraph
- function tempz_css() {
- // This makes sure that the positioning is also good for right-to-left languages
- $x = is_rtl() ? 'left' : 'right';
- echo "
- <style type='text/css'>
- #dolly {
- float: $x;
- padding-$x: 15px;
- padding-top: 5px;
- margin: 0;
- font-size: 11px;
- }
- </style>
- ";
- }
- add_action( 'admin_head', 'tempz_css' );
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement