Earlier quoted context omitted.
It is certainly not still there given that facebook doesn't run PHP any more. They wrote a compiler to translate a subset of PHP to C++, which they then compiled into a massive executable. The compiler is open source and called hiphop, and it does not implement the PHP memory limits.
Facebook still uses PHP bro...
Facebook PHP Source Code from August 2007
111–120 of 154 posts
Re: Facebook PHP Source Code from August 2007
#112Earlier quoted context omitted.
It is certainly not still there given that facebook doesn't run PHP any more. They wrote a compiler to translate a subset of PHP to C++, which they then compiled into a massive executable. The compiler is open source and called hiphop, and it does not implement the PHP memory limits.
They don't do that anymore. Ask your Facebook friends, hphp has changed since then.
Re: Facebook PHP Source Code from August 2007
#113Earlier quoted context omitted.
It is certainly not still there given that facebook doesn't run PHP any more. They wrote a compiler to translate a subset of PHP to C++, which they then compiled into a massive executable. The compiler is open source and called hiphop, and it does not implement the PHP memory limits.
By that logic, no one runs any programming languages, since they all get translated to x64 or other instruction sets.
Re: Facebook PHP Source Code from August 2007
#114Earlier quoted context omitted.
I guess shipping is more important to you than the possibility of losing user details (or worse). Christ, I hope I never give my details to a company you found. Shipping quickly is important but it's also important to write quality code. Small bugs that can easily be fixed are fine but security problems or bugs related to payments, for example, are not.
How many companies have failed because of security flaws in their code?
These are not figures you want to see on your bottom line.
Re: Facebook PHP Source Code from August 2007
#115Earlier quoted context omitted.
It'd be somewhat weird to stumble across comments in that code. // TODO:
I quite often see words (or nearly-words) in protein sequences. The best I've seen are (when reading DNA translated in all frames): EVQLVE LAMARCK ELVISISGAY SALTYSATAN
Re: Facebook PHP Source Code from August 2007
#116Earlier quoted context omitted.
Cool, i remember these days as well. Indeed it very much looked like StudiVZ just used FBs css filed and changed some colors.. It was a typical german clone success story. Dariani did a lot of questionable things but sold in the right time before the downfall of VZ. I didnt really like it, they basically did nothing in terms of innovation that FB did, it had the same features for years. Later they had a half-assed ap…
We had to solve scaling issues most of the time. VZ was running on a multi-tier platform with services written in Java, PHP, Erlang, C++ and Python. 17 million users with around 25 billion requests per month (without static content)... Some numbers from 2010: - 60.000 req/s (without static content) - 2.5 mio. memcache ops/s - 300k queries to the database tier We've built that platform with a team of around 20-30 engi…
Re: Facebook PHP Source Code from August 2007
#117I remeber these days. I worked at this time for studiVZ - a german social network (still exist, but nobody is using it anymore) and this leaked was caused by a misconfiguration in their Apache setup. In 2008 studiVZ was sued by Facebook. They said we theft their PHP, CSS/JS "code". ( http://techcrunch.com/2008/07/18/facebook-sues-german-social... ). Indeed, the first version of studiVZ was inspired by Facebook. Our f…
Re: Facebook PHP Source Code from August 2007
#118Earlier quoted context omitted.
I wonder if it was based on the code Zuckerberg used for the Java friend graph he had on his homepage prior to Facebook. Could you perhaps censor the credentials and release it?
I am not a lawyer, but even with censored credentials this seems like a bad idea. Especially since my profile is not exactly anonymous. Any Facebook employees want to get me a green light? :)
Re: Facebook PHP Source Code from August 2007
#119Re: Facebook PHP Source Code from August 2007
#120Anyhow, not sure if this makes any difference or not but i'm curious as to why true PHP constants are not used, and instead regular variables in all caps like $PARAM_INT are used. Anyone know why this might be?
I ask because one of you PHP-gurus might inform me that there are certain use-cases where a true constant is not wise.
An example below:
param_get_slashed(array(
'feeduser' = > $PARAM_INT, //debug: gets feed for user here
'err' = > $PARAM_STRING, // returning from a failed entry on an orientation form
'error' = > $PARAM_STRING, // an error can also be here because the profile photo upload code is crazy
'ret' = > $PARAM_INT, 'success' = > $PARAM_INT, // successful profile picture upload
'jn' = > $PARAM_INT, // joined a network for orientation
'np' = > $PARAM_INT, // network pending (for work/address network)
'me' = > $PARAM_STRING, // mobile error
'mr' = > $PARAM_EXISTS, // force mobile reg view
'mobile' = > $PARAM_EXISTS, // mobile confirmation code sent
'jif' = > $PARAM_EXISTS, // just imported friends
'ied' = > $PARAM_STRING, // import email domain
'o' = > $PARAM_EXISTS, // first time orientation, passed on confirm
'verified' = > $PARAM_EXISTS)); // verified mobile phone