New features in PHP7

PHP 7 is coming out soon and is a great improvement on previous versions. There’s been a lot of great movement in the community with plenty of RFCs and the language is definitely moving in the right direction.

Here are some great features that you’ll really want to know about

Support for hats

PHP 7 comes with support for a variety of hats. How? Use this handy method get_hat().

Support for 6

The number 6 is now fully supported in PHP7. Previous uses of the number 6 would result in a T_UNEXPECTED_CHWE error but now they can be inserted into code like any other number. For backwards compatibility two 3 or half a 12 can still be used but these methods will throw a deprecated notice.

get_hat method deprecated

The get_hat method introduced in PHP7 has been deprecated. Use get_hat_real() instead.

new error type E_RETHINK_YOUR_LIFE

A warning for WordPress developers.

Support for line numbers

Following PHP 5.3′s introduction of the goto operator PHP7 now features line numbers. Also available are peek and poke functions, plus the ability to switch into Teletext Mode 7.

Licking your own elbows

PHP7 can lick your own elbows so you no longer need to use the ternary operator.

Reverse execution mode

Add define(“execution_mode”, M_REVERSE); to the top of some files sometimes to set execution mode into reverse. The op-code cache has been completely re-written to allow both forward, reverse and random execution sequences.

Alex Kidd in Miracle World built-in

Hold down A+B+C to play the Sega classic!

get_hat_real() method deprecated

Hats are no longer recommended and will be removed from the next version of PHP. Wearing a hat will result in a E_NOTICE_PROBLEM exception.

facebooktwittergoogle_plusredditpinterestlinkedinmailby feather

3 Realities of Being A Man Nobody Talks About

1) How difficult urinals are to use

Nothing worse about being a man then when you need to go the toilet and all that’s free are urinals! First, there’s the issue of deciding which one to use – do you choose the one next to the man wall? Or do you just pee against the wall? What about the sink? Some of those sinks might be urinals. Yeah why not. What let go of me leave me alone wait this isn’t the mens. Look it wasn’t me last time you must have be thinking of someone else.

2) Having to hold doors open for women

What’s this about! Women have hands too! This is awful. Not to mention the fact that if you hold the door for a man, they might think that you think they’re a woman and that would be embarrassing for everyone.  You can’t have it both ways ladies. Either hold the door open or don’t but don’t expect me to stand there just because I’m there already.

3) The constant pressure of being right about everything all the time

This is probably the worst thing. President Barack Obama, who is president of the americans, is constantly under pressure to be more right than most men and not even he can do it. Imagine what it’s like for men who aren’t as good as him – it’s far worse. Women will never understand this which is why less women are presidents than men.

facebooktwittergoogle_plusredditpinterestlinkedinmailby feather

ALIEN SCRIPT

Here is an excerpt from the new draft of the script by me.

SCENE: The future. We are in space. Then we pan back – we are actually in a garden. We pan back some more. A garden in a space ship! A woman is sat there with a girl of about 10. The woman is our heroine ELLEN RIPLEY.

RIPLEY: I’m so glad I managed to get back in time for your 11th birthday. I had an awful nightmare where I couldn’t because of an alien or something.

AMANDA: That’s OK Mom. You got home after an uneventful mission doing mining or whatever it is you do in space. And now we can live happily ever after and stuff.

RIPLEY: Yes. Wait…

RIPLEY winces. She clutches her stomach. It is as if something is trying to burst out of her!! A passing cat hisses. AMANDA screams as we see a bulge in RIPLEY’S stomach

CUT TO

Another spaceship. RIPLEY is now older. It’s the SULACO! The one they’re in in Aliens. HICKS and NEWT and BISHOP are there too! BISHOP has fixed himself.

RIPLEY: What an awful dream. I dreamt that none of this had happened, and then it had. It didn’t make much sense, but it certainly set the scene.

HICKS: Yes. The vivid one about the prison planet where we all died? Or the more confusing one where you died and there was Winona Ryder? Never mind; it was all a dream and it Never Happened.

RIPLEY: Yes; all that happened was the first 2 traumatic things with the aliens, which is much more tolerable. I sure hope no aliens got on board this ship.

BISHOP: That wouldn’t make any sense. The only thing that would make any sense was that this was all a bad, bad dream.

RIPLEY: Wait a second – this is a dream – I’m in my underwear!

BISHOP: Yes; you’ve just come out of cryosleep.

RIPLEY: And I’m in an exam!

RIPLEY is in an EXAM

The person in front of her turns around. It’s an alien! 

ALIEN: Hisssssssssss

A CAT: Hissssssss

BISHOP: Hisssssssss

RIPLEY wakes up. She is on the set of Alien Vs Predator.

RIPLEY: NO! Noooo!!!!

facebooktwittergoogle_plusredditpinterestlinkedinmailby feather