17 ms·
PHP 7 Released
- MrBra 11y agoWhen years ago I started learning Ruby and wanted to use it for the web, my intention was using it like you do with PHP (simply including it in HTML) but I got a bit frustrated because all the resources I kept finding showed the only way of using Ruby in a web context was by using a big framework like Rails or, by choosing a wrong path and playing with stuff which required a lot more in depth knowledge that I did not have (and that I didn't want to be forced to have because I just wanted to focus on app code and experiment). I only recently discovered https://github.com/migrs/rack-server-pages https://github.com/migrs/rack-server-pages which allows to simply shove Ruby in HTML the same way as PHP and as a new Ruby dev could expect to be able to do. I think this approach makes learning projects simpler, and at the same has the added value of making people actually learn a lot about those aspects of HTTP that frameworks keep well hidden under their carpet and that can help you become a good web developer instead of "simply" a framework user. Yes for sure, best practices that frameworks implement are there for a reason, and it's great to have them, but IMHO, this approach has advantages when learning and could also be seen as an essential step to understand what those frameworks you will use next are abstracting and why. IMHO, what still contributes to new generations of devs approaching PHP, is also its immediateness and simplicity with nothing to do except '<?php' code '?>' and with this comment I just wanted to give a bit more exposure to the fact that a similar solution exists for Ruby too, and that it's a bit of a pity that because of the importance of Rails it got a bit overshadowed.
- DigitalSea 11y agoProbably one of the biggest releases since 5 in my opinion. Scalar and return type declarations being added in are a couple of massive additions. For a language that used to cop a lot of flak, PHP sure has grown to become a mature and quite decent language.
- maweki 11y agoby copying all the python features :D
- miseg 11y agoBy learning from Python's best practices :)
- humbertomn 11y agoI would rather see both teams working together for one single language :) I wrote a little about it here http://goo.gl/XFR2Xt http://goo.gl/XFR2Xt
- jacquesm 11y agoThat will never happen.
- humbertomn 11y agoI know, but... "I just think those pointless discussions of languageA vs LanguageB are infinite loops and languageA + LanguageB would make both sides evolve faster and the whole community would gain in the end."
- Moru 11y agoOnce upon a time it was Atari/Amiga and before that it was a bunch of other smaller computers... Now it's languages and the arguments sounds just the same.
- est 11y agoAnd smoke Python in performance.
- ircmaxell 11y agoExcept that in PHP type declaration mismatches are actually errors... They aren't just "documentation" to be used by static analyzers.
- sneak 11y agoNo, PHP isn't "quite decent". It's still a steaming turd, it's just been polished with a whole bunch of features.
- toddan 11y agoPlease explain why.
- rplnt 11y agoHave you ever worked with php? I have only slightly and it was truly horrible. The library is a complete rubbish. You couldn't create worse one if you tried. The language development is bad. Some developers are bad. Many users are bad. Does these points make the language bad? Yes. New features are incoherent and seemingly random, issues pop in and out (and back in) because tests simply fail, there are unexplainable security issues, documentation is bad, and if you look for any help (documentation comments, stackoverflow) you meet the users and their shitty tips. Response to every criticism is "you just need to learn something". Does that make a good language? No. It's precisely what makes it bad. PS: There's a nice subreddit for fun and laughs /r/lolphp - there are continuously new things as the language evolves, so the shittiness is not going away
- marklgr 11y agoPHP is the language many people love to hate; I guess some of them like the idea of being able to point the black sheep of web development, so that they can tell "maybe we have some flaws, but at least we're not one of these PHP shops". https://en.wikipedia.org/wiki/Splitting_%28psychology%29 https://en.wikipedia.org/wiki/Splitting_%28psychology%29
- rplnt 11y ago> PHP is the language many people love to hate Do you think there's a reason for that? Maybe a direct one? That it's a bad language for example? Why would it need to be anything more complicated than that. So I don't think your guess is accurate. It's simply a bad language on its own. No need to compare it to anything. And I don't think anyone can deny that, no one will honestly say that "php is a good language". You can say it has some good features, or that it's good for certain tasks, or perhaps that it's better.. but that's all.
- Flimm 11y agoPHP 7 new features: http://php.net/manual/en/migration70.new-features.php http://php.net/manual/en/migration70.new-features.php
- jafingi 11y agoIt's really a great release! Great work by all the contributors.
- trm42 11y agoPHP 7 makes life a lot better for PHP devs in many ways but one awesome thing is it obsoletes bunch of out-of-date tutorials by finally removing the old Mysql extension \o/ http://php.net/manual/en/migration70.removed-exts-sapis.php http://php.net/manual/en/migration70.removed-exts-sapis.php I actually met a young aspiring web developer who still learned DB-access with mysql_* functions. I urged him to switch to a sane framework like Laravel. Oh boy he was happy in a month and learned bunch of best practices quickly.
- imaginenore 11y agoThe problem with Laravel is, while being a sane framework, it absolutely kills the performance, especially the last version, which is now slower than Symfony. http://blog.a-way-out.net/blog/2015/03/27/php-framework-benchmark/ http://blog.a-way-out.net/blog/2015/03/27/php-framework-benc...
- mintplant 11y agoWow, they finally made good on their promise to remove ereg_*. I remember reading the deprecation notice on those functions (and using them anyway) maybe half a lifetime ago when I was first learning PHP.
- jamesoneill 11y agoI did the exact same thing back when I was first learning web development in 2012. All the PHP tutorials I used were really outdated but since I was new to it I had no way of knowing that. Thankfully I didn't get the chance to do any damage before I was exposed to modern best practices.
- arien 11y agoI think it's great to point new developers to the right resources. Besides sane frameworks, there are some good starting/best practices guides to help (that are regularly updated), such as: http://www.phptherightway.com http://www.phptherightway.com https://phpbestpractices.org https://phpbestpractices.org Also, I would encourage them to look at different frameworks, not just one. It'll help if they later move onto other languages, as they'll be already exposed to different ways of doing things :)
- RohithMeethal 11y agoI wish every PHP developer would reread the docs and start using new features available instead of just continuing with what they know already just because it works. And of course if there was any way to remove all those old tutorials out there.
- venomsnake 11y agoAnd every php developer would wish that suddenly all php in the world upgrades to v7. We are years away from 7 having a big penetration in the ecosystem. And years more till it hits enterprise.
- longwave 11y agoThe performance improvements along with the support policy should hopefully encourage many sites to move to PHP 7 within a year; PHP 5.6 will be unsupported in 8 months (though it will receive security fixes for another year).
- venomsnake 11y agoIf you want to keep your sanity, don't ask the question how much of the web (even worse intraweb) is driven by php 4, 5.1 and 5.2.
- jay-saint 11y agoUnfortunately several of the most popular PHP based platforms will be stuck using PHP 5.9 or older for some time. Magento just recently in version 1.9 added support for PHP 5.6. There are still an allarming number of Drupal 6 based sites out there in large scale production that have trouble supporting PHP > 5.4 The recent releases of Magento 2.0 and Drupal 8.0 should help move more sites to modern versions of PHP, but there is a lot of work still to be done on contrib modules to get full functionality out of M2 and D8
- aikah 11y ago> And every php developer would wish that suddenly all php in the world upgrades to v7. We are years away from 7 having a big penetration in the ecosystem. And years more till it hits enterprise. It will depend on hosting companies for some public websites and sysadmins for internal business apps. Ironically the sysadmins I know will be the hardest people to convince, for some reasons. that's basically why as much as I can , I chose solutions with no dependencies when I'm working on apps for internal use (like Go,Nim,..). It solves a whole lot of issues. I just can't stand having to convince someone else to do his job in order to do mine.
- almsgiver 11y agoA tag is not a release, it should be officially released tomorrow.
- agbonghama 11y agoWhat could go wrong after a tag? To me, a tag is a release.
- TazeTSchnitzel 11y agoThe tag could change.
- razvan_moldovan 11y agoyeeeeh :D great work
- egeozcan 11y agoWhy do they keep adding global functions like "intdiv"? For example in JS, it being another language with a similar compatibility burden, they are moving most of the global functions (like parseInt) to "namespaces" (like Number.parseInt) while keeping global references there. When I open the docs (for example, the array functions page[1]), I get frightened by the global functions which do not seem to share a naming convention on first glance. disclaimer: I haven't written anything significant with PHP since too many years. [1]: http://php.net/manual/en/ref.array.php http://php.net/manual/en/ref.array.php
- debacle 11y agoThe internals list has a weird combination of die hard "PHP is PHP" people who really prefer for things to not change even if they are bad.
- deleted 11y ago[deleted]
- monk_e_boy 11y agoThis is ongoing in the PHP community. For those who like purity there are tons and tons of wrapper classes that hide all that stuff away. Modern IDEs autocomplete all the functions, I'm using PHPStorm and as soon as I type 'arr' it shows me a list of all the array functions with parameters listed. Not perfect, but if I was worried about that kind of thing I'd use Python (which I love) or RoR (which I also love). The ethos of PHP is to just get stuff done: http://axonflux.com/5-quotes-by-the-creator-of-php-rasmus-lerdorf http://axonflux.com/5-quotes-by-the-creator-of-php-rasmus-le...
- wtetzner 11y ago> The ethos of PHP is to just get stuff done I never understood this standpoint. I hear this from the Go community sometimes too. Wouldn't having some sane organization of functions make it easier to "just get stuff done"? Just like in Go, wouldn't generics make it easier to get stuff done?
- 11y ago
- defenestration 11y agoCongratulations to the PHP community with this milestone! I wonder if people who switched to HHVM, will start using PHP again. HHVM has offered much faster performance than previous versions of PHP. The speed of PHP 7 is at par with HHVM.
- mtbcoder 11y agoI may be wrong, but I would assume most teams/individuals who made the decision to implement HHVM did so to use Hack and all of its features.
- castell 11y agoHHVM is still a bit faster than PHP7 in most benchmarks (wordpress, etc.). HHVM has also JIT and consumes less memory per request. Though PHP7 is more backward compatible with real word PHP5 code bases and is easier to install.
- drakonka 11y agoCongratulations and thank you to everybody who has contributed. I've been running PHP 7 for my hobby project for the last couple of months. The update was refreshingly painless and I've had zero compatibility troubles so far.
- longwave 11y agoThe performance improvements in this release will hopefully encourage people to upgrade, even if the new features don't. Common PHP applications run 70%-100% faster on PHP 7 than they did on PHP 5.6, comparable with or better than HHVM.
- Kartificial 11y agoThat sounds amazing, do you have any sources / benchmarks to back this up?
- Jgrubb 11y agoMy own anecdotal evidence - I couldn't believe how fast our Drupal 7 websites were, and they only threw a couple of deprecation notices. They definitely felt 100% faster. We will be upgrading soon.
- monk_e_boy 11y agohttps://kinsta.com/wp-content/uploads/2015/05/hhvm-php7-benchmark.jpg https://kinsta.com/wp-content/uploads/2015/05/hhvm-php7-benc...
- longwave 11y agohttp://www.zend.com/en/resources/php7_infographic http://www.zend.com/en/resources/php7_infographic
- MichaelApproved 11y agoThe performance increase is what I'm looking forward to most with 7. I can't wait to see how several of my code-heavy WordPress installations do with 7. From the benchmarks I've seen, it's going to be incredible. Specifically, I'm hoping the page load times will be cut in half.
- mrmondo 11y agoAs a person with more of an ops background can someone explain to me why / when PHP might be a viable language? My experience with hosting PHP apps has historicity been one of fending off security issues and I think that often in the past PHP was often a language for designers that didn't have experienced programming skills, it feels like designers have now shifted to using Node for this?
- ianhawes 11y agoIt depends on whats being hosted. If you're dealing with legacy apps that were built in the PHP 5.2 or even PHP 4 days, be afraid. Be very afraid. If you're dealing with more mainstream PHP apps like WordPress or Magento, its important to stay up on the core updates but also monitor the plugins and templates being installed. The majority of the attack surface on those apps is in the plugins because they're almost never audited. As for modern customer apps, written in frameworks like Laravel or Symfony, you're usually fine. Those frameworks are on par with Django and Rails in being very hard to shoot yourself with.
- castell 11y ago> legacy apps that were built in the PHP 5.2 or even PHP 4 days, be afraid. Be very afraid BS. Most PHP4 code runs just fine, as do PHP5 code. Almost no one used object oriented code in PHP4 days (it was slow!), so the incompatible changes aren't a problem. And all you need to do is to search and replace some function names like mysql_* to mysqli_*. Most old code bases from PHP4 days also didn't rely on frameworks at all and were completely written from scratch or copy&pasted together - actually an advantage in this case. Upgrading an old Python or Ruby code from 1.x/2.x days is a lot of more work (as it always includes upgrading to a recent framework version) than upgrading from PHP4 or PHP5 to PHP7.
- gkwelding 11y ago"My experience with hosting PHP apps has historicity been one of fending off security issues" Unfortunately PHP seems to have this reputation. It's not so much the language that is the problem but the people using it. PHP typically had such a low bar to entry that literally anyone could pick it up and do anything and everything with it. And quite frankly there were (and still are) a lot of beginner tutorials out there encouraging people to do very stupid insecure stuff. It now seems to be an image that stuck. If you take a look at the OWASP Top 10, and any big data breaches recently, they are all caused by human error. SQL injection being the major culprit.
- allan_s 11y agoThe scalar and return types are really a great improvement IMHO, I can't wait for Doctrine to fully support it for code generation. But one thing which is missing is the nullable types, as currently it's either you always return a string and you can use scalar typing, or you sometimes return null and you can't use it (which I'm okay with) https://wiki.php.net/rfc/nullable_types https://wiki.php.net/rfc/nullable_types https://github.com/php/php-src/pull/1045 https://github.com/php/php-src/pull/1045 With this, it will permit to have even better static analysis "a la" HHVM/hack (i.e detecting that you haven't check for is_null in your code
- jimaek 11y agoCant wait for php-memcache and a few other extensions to support PHP7 to move our projects
- Jgrubb 11y agoI was waiting and waiting for this as well, but checked homebrew during RC6 and there was a PHP70-memcached, so I took that to mean it had finally caught up?
- McGlockenshire 11y agoext/memcache is not the same thing as ext/memcached. Yup, there are two, and they are entirely different. One uses the historic library, the other uses the new library. Why they decided to do it this way is beyond me.
- Jgrubb 11y agoYeah, I know there are two. I was under the impression that the original (memcache) was abandonware. How much difference is there between the two to migrate from php-memcache to php-memcached? edit: never mind, I'm going to figure this out by using the internet!!
- jimaek 11y agoThis symfony bundle https://github.com/LeaseWeb/LswMemcacheBundle https://github.com/LeaseWeb/LswMemcacheBundle uses specifically the php-memcache extension. Thats why we need it
- mei0Iesh 11y agoYay, null coalesce operator! That shortens a lot of common redundancy. When will there be a FreeBSD port?
- datashovel 11y agoThe one thing I'd love to see is a native concurrency story with PHP. I'd put my vote in specifically to have Communicating Sequential Processes. I think that feature alone would take the language to another level. I know they've got stream_select, et al. and I've really enjoyed pecl event, reactphp, and of course there's HackLang's Async / Await if you want to convert, but having some modern / native constructs would be nice to have. Does anyone know if that's on the horizon?
- debacle 11y agoPHP has pthreads which are slowly becoming a real thing. There are a few relatively non-minor stumbling blocks in the way, but I imagine that it'll be only 12-18 months between when it can be a priority and when it'll be part of PHP. I expect you'll be able to do true concurrency in PHP in the next ~3 years.
- datashovel 11y agoAh yes, thanks for reminding me. I do recall coming across this project in the past, but never followed its progress. For some reason I decided against exploring further. I think it may have been disclaimers that stated it was still experimental (even though pecl had it listed as stable).
- dutchbrit 11y agoCool stuff, PHP 7 looks very promising, especially when it comes to speed. In some cases even faster than HHVM.
- cdnsteve 11y agoI'm actually excited for this release! - Type declarations (this is a HUGE move forwards). - Grouped use statements, not sure if I like how that looks - ?? will shorten statements - Anonymous classes seem a bit odd looking to me - Unserialize filter is a nice security bump Anxious to try it out and see the speed improvements I've been hearing about too.
- mjrpes 11y agoAnonymous classes are very cool and have a lot of potential uses, which are mentioned at the bottom of the RFC: https://wiki.php.net/rfc/anonymous_classes https://wiki.php.net/rfc/anonymous_classes
- velmu 11y agoExcellent!
- cdnsteve 11y agoStuff like this hurts: https://www.drupal.org/node/2454439 https://www.drupal.org/node/2454439
- onli 11y agoIt really does. I work partly on a 10 year old PHP software. PHP 7 has apart from some other breakages some changes in the evaluation order that I expect to break everything. Thankfully related to objects, so with a bit of luck it will mostly hit the bundled libs (the project of course does not use objects for its own structure) which can then be exchanged or maybe will get updates. Lots of work.
- geerlingguy 11y agoOf note: that issue has been ongoing for months, and most of the issues that were found were fixed in PHP core within a few days/weeks. Drupal 8's test suite even caught one regression that delayed the PHP 7.0.0 final release a few weeks! Most modern PHP apps will work on PHP 7.0.0 with little or no extra effort, but if you have a large legacy app, and haven't ever turned on error logging, you may need to fix a bunch of deprecated code usage!
- randomname2 11y agoWhy? It says there is a 100% test pass rate on PHP7.
- lsaferite 11y agoI was so excited when I saw this post. Then I realized it's another 'too early' post claiming the tag == release. It's not released until it happens on the PHP site. This is just a tag in the repo. Sure, it likely won't change now, but it could.
- jneal 11y agoCorrect, it's not likely to change at this point. Official release is slated for Dec 3 according to their Twitter[1], so it appears they are getting everything ready to launch. [1] https://twitter.com/official_php/status/669940548128534528 https://twitter.com/official_php/status/669940548128534528
- Practicality 11y agoIndeed, the GA release date is tomorrow: https://wiki.php.net/todo/php70#timetable https://wiki.php.net/todo/php70#timetable
- TazeTSchnitzel 11y agoIt's not uncommon for released to be re-tagged, too.
- feld 11y agoand if you do this you deserve to burn in a fiery pit for being a bad bad bad release manager If you tag a commit you better stick to your guns and never change it. You can't just re-tag or re-roll your releases because you found a bug. Bugs happen. Increment your version number, cut/tag a new release, and move on. You will never have a perfect release. Ever.
- deleted 11y ago[deleted]
- TazeTSchnitzel 11y agoTagging a PHP release doesn't mean finalising it. That's when the tarballs go up and the email goes out.
- deleted 11y ago[deleted]
- captn3m0 11y agoHave been waiting for this anxiously. I've been running a few test builds on it occasionally, but its nice to have the guarantee to shift prod systems to it. New Features list is at https://secure.php.net/manual/en/migration70.new-features.php https://secure.php.net/manual/en/migration70.new-features.ph... My favorite is scalar typehinting by far.
- circa 11y agoI haven't worked with PHP in quite some time now but I am happy to see its still kicking. Although it does bring back some haunting memories from versions 3 and 4.
- sarciszewski 11y agoThe feature I'm most excited about is the availability of a simple, sane, and correct CSPRNG: string random_bytes(int $numBytes); int random_int(int $min, int $max); If you want to use this interface in a project that needs to be compatible with PHP 5, there's always https://github.com/paragonie/random_compat https://github.com/paragonie/random_compat
- motiejus 11y agoOK, great! Clicking the main page[1], see the top of README: "build error". Wait, what? You just released it, it should definitely work! Clicking that icon[2], checking the failed build[3]: ERROR: no certificate subject alternative name matches requested host name `pear.php.net'. To connect to pear.php.net insecurely, use `--no-check-certificate'. Really? See what's in http://pear.php.net/ http://pear.php.net/ > The server running pear.php.net had a fatal hard disk failure and gets replaced by a new machine this week. Until the new machine is setup, this page is up to let you continue installing PEAR packages via the PEAR installer. In 2015? Cool. Connecting to the https website ... % openssl s_client -connect pear.php.net:443 ... Certificate chain 0 s:/CN=mail.cweiske.de So you're using CN=mail.cweiske.de for pear.php.net. I don't even know what to say.. Well, happy hacking! [1]: https://github.com/php/php-src https://github.com/php/php-src [2]: https://travis-ci.org/php/php-src https://travis-ci.org/php/php-src [3]: https://travis-ci.org/php/php-src/jobs/94372493 https://travis-ci.org/php/php-src/jobs/94372493
- untog 11y agoThey didn't release it. They just tagged it in GitHub. The HN title is wrong.
- jhall1468 11y ago> In 2015? Cool. Do you actually think there's a point in time where mechanical hard drives are going to last forever? If so I have a bridge to sell you.
- nkantar 11y agoI'd wager it's commentary on the lack of redundancy that would allow such an important resource to be unavailable. Hard disks fail, but if you're hosting something important on them, you might want more than one (to grossly oversimplify things).
- wtetzner 11y ago> % openssl s_client -connect pear.php.net:443 ... Certificate chain 0 s:/CN=mail.cweiske.de >So you're using CN=mail.cweiske.de for pear.php.net. I don't even know what to say.. Well, happy hacking! Yeah, but it's cool that they used Let's Encrypt.
- sarciszewski 11y agoBy the way, PHP 7 has been tagged but not yet released.
- oblio 11y agoCan anyone closer to the subject provide some info about this: https://www.reddit.com/r/programming/comments/3v4l98/php_7_released/cxkazco https://www.reddit.com/r/programming/comments/3v4l98/php_7_r...? That comment looks a bit scary if it's true :(
- adrianmacneil 11y agoGiven how dependent php is on hosts to upgrade, and how slow php hosts traditionally move, it would seem that php would benefit from a 7-to-5 transpiler, similar to Babel for JS. Does anything like this exist already?
- giaour 11y agoHonestly, bigger PHP sites aren't dependent on hosts but on Linux distributions for staying up to date. Once there's an AMI of Amazon Linux and an Ubuntu LTS shipping with PHP7, there should be a huge upswing in adoption.
- ausjke 11y agoBeen learning php on and off for a while, happy to see this release is out. Most likely I will use PHP for my future projects instead of the alternatives. Languages are learning from each other these days, the new PHP definitely benefited from this trend and is actively evolving itself, which is the major reason I'm to stick with it. Some PHP developers recommended nodejs over PHP for the future to me, after a few experience I feel PHP may be better for long-term maintenance. Renovation is good, it's just that javascript may have too much of it for me to chew on nowadays. Wish there will be a light-weight version of PHP, something like micropython or Lua, so I can use it on low-end systems when needed. PHP is still very demanding on resources comparing to other languages, even nodejs can be used on IoT devices with restricted mem/cpu power.
- debacle 11y agoA very lost opportunity to create a new stdlib and eventually phase out the old, shitty, procedural one.
- samuell 11y agoTo me, PHP is still interesting, because of the ProcessWire CMS/CMF [1], which is basically the next best thing afte sliced bread (A generic hierarchical content structure, with a jquery-inspired PHP template API, giving FULL flexibility to customize your design and presentation to anything you like ... even REST apis are just a few lines of code in a template. Add to that dozens of dozens of extremely nicec features built in, such as automatic thumbnail resize through API methods such as <img src="{$image->size(90,90)->url}"> ... and you have something immensely powerful). [1] http://processwire.com http://processwire.com
- ck2 11y agoPHP 7 literally cuts the load in half for PHP code which means hundreds of thousands of servers can either now save power or serve nearly twice the number of connections. win-win almost as fast as hhvm but much easier to adapt
- jpmw 11y agoI left the PHP community years ago, but...but...where is PHP 6? What was the reason to skip it?
- wnevets 11y agoIIRC this release is so different from the planned 6 release they thought it would be confusing to people who bought/read those PHP6 books.
- Acconut 11y agoFunnily, there is no PHP 6. While work had begun for this version, it was later abandoned due to some major issues regarding Unicode handling, as far as I know. Most of the features already implemented in PHP 6 were shipped in PHP 5.4 and they continued with PHP 7 in order to avoid confusion.
- jjuhl 11y agoWhy, ohh why, won't this freak of nature (language) just die :-(
- jeremiep 11y agoI've recently found this gem: http://eev.ee/blog/2012/04/09/php-a-fractal-of-bad-design/ http://eev.ee/blog/2012/04/09/php-a-fractal-of-bad-design/ I haven't laughed this much in a long while. PHP was my first language and indeed I got far away as soon as I knew any better.
- codewithcheese 11y agoI don't use PHP anymore. However, if you want to web program it really is the easiest to get started. So many of my friends who have no interested in programming but want to do simple web stuff learn how to setup apache with PHP and copy paste what they need.
- MAGZine 11y agoBecause it's actually not bad for anyone who has written PHP 5.4+ with a modern framework. Yes. Good.
- jjuhl 11y agoIt may solve your immediate problem. But it's dangerous - there are too many hidden gotchas and situations where you have to know the actual implementation (which can change) to know what it does. It also breaks a lot of conventions established by most other languages, so you really have to be really careful when assuming that "this probably works like I expect" - you may get nasty surprises). Ohh and it's pretty slow compared to other languages (like C++, Lua & Python - just to name a few). And that's not even mentioning the fact that the people implementing it seem to be a case of the "blind leading the blind". Just search for how they tried to fix an integer overflow by testing if "foo>intmax" etc - that's just the tip of the iceberg (who the hell thought that converting strings to integers before comparing them was a good idea?) etc etc. Those guys should not be allowed near language design. So yeah; it's pretty bad.
- awalGarg 11y agoGreat release! I think the BC breaks are all justified :) And all the shared hosts around still stuck at 5.3 or so, this is your time to move forward. At least start offering a PHP7 version, if not a straightway upgrade. Huge thanks to the internals for their hard work.
- gustavofulton 11y agoIs it the final release now?
- GigabyteCoin 11y agoAre they skipping 6.X releases or something? The latest release according to php.net [0] is 5.6.15 which come out October 29th of 2015. [0] https://secure.php.net/releases/ https://secure.php.net/releases/
- Jemaclus 11y agoFor a long time, there was a PHP6 in the works, but then HHVM and Hack came around and started making PHP6 look bad. There was another fork called PHP-NG, I believe, which went in a different direction. There was a huge pissing match in the internals list, and in the end, I think they threw threw out most of the PHP6 proposals and started fresh. To clear up matters, they skipped PHP6 and called it PHP7. Don't quote me on that, but that's my understanding of it.
- martin_ 11y agoThe primary reasons for skipping PHP6 were that several books had been published on what PHP6 was supposed to be (full unicode support, for example), talks had been given and the original php 6 branch was ultimately ditched. The full list of reasons are at: https://wiki.php.net/rfc/php6 https://wiki.php.net/rfc/php6
- jwdunne 11y agoI've been anticipating this for a while. Some great additions, especially scalar type hinting and type hinting on return types. The ability to enable stricter typing via a directive is also great. It's a shame internals voted down short-hand syntax for anonymous functions, including implicit closure over outer scope variables - a function with closures in PHP can get ugly very fast. Using higher-order functions becomes far more unwieldy.
- timmy_ 11y agoI use PHP for my freelance work mainly because I have no option on hosting. I never got the appeal for PHP (besides being cheap to host). All my personal projects are either done in Python or Node + (Angular, react & now Vue) Python: PURE elegance Node: io breeze PHP: ? Q: is the "module" system still achieved by dumping file content or is there a linking system?
- profmonocle 11y agoJust curious, why do you have no option on hosting? I got into PHP many years ago for this exact reason - it was the easiest language to use on low-cost shared hosting. But these days you can get a decent VPS (where you have root and can use any language) for $10-$15 a month, which is exactly what I used to consider "low-cost hosting".
- timmy_ 11y agoI live in Africa & $10 * 12 = $120/year is way too expensive --- when I say cheap, I'm talking about $3/month (shared, 20GB bandwidth, 1GB storage, MySQL / PgSql) Hostgator, Godaddy...
- profmonocle 11y agoWow! I wasn't aware shared hosting prices had gone down so much as well, but I guess they couldn't compete with VPS services otherwise.
- josu 11y agoWhat effect will this have on Wordrpess?
- geerlingguy 11y agoMy best guess it Wordpress will still use it's PHP4-style architecture for years to come, until it's entirely rewritten in JS at some point.
- darkhorn 11y agoIt has not been released yet.
- sarciszewski 11y agohttps://news.ycombinator.com/item?id=10672307 https://news.ycombinator.com/item?id=10672307