Category Archives: Technology

The technology behind preview photos

Facebook Developers explain how they include ~200 byte preview JPEG images in user profile JSON payload to speed up load times

 

Facebook profiles can be slow to download and display. This is especially true on low-connectivity or mobile networks, which often leave you staring at an empty gray box as you wait for images to download. This is a problem in developing markets such as India, where many people new to Facebook are primarily using 2G networks. Our engineering team took this on as a challenge: What could we design and build that would leave a much better first impression?

How a change in preview photos helped speed up profile and page loads by 30 percent.

Read more from the source: Facebook Code

Logic gates tutorial with functional demo

Schabse Laks created working logic gates with a clever use of checkbox inputs, labels, and CSS sibling selectors

 

Schabse writes:

Logic gates are the basis of all of computing. They take two binary inputs (0/1 or true/false), and result in a binary output whose value depends on the inputs. These gates form the building blocks upon which all computers are built.

Here are the three basic logic gates: AND (true only when both inputs are true), OR (true when either input is true), and XOR (eXclusive or, true only when exactly one input is true, but not both). Click the inputs (square boxes) to see the outputs reflect the values.

Check it out at silon.slaks.net

How To Safely Hash A Password

If you’re not using bcrypt get with it or be vulnerable

 

Coda Hale writes:

Use bcrypt.

Why Not {MD5, SHA1, SHA256, SHA512, SHA-3, etc}?

These are all general purpose hash functions, designed to calculate a digest of huge amounts of data in as short a time as possible. This means that they are fantastic for ensuring the integrity of data and utterly rubbish for storing passwords.

A modern server can calculate the MD5 hash of about 330MB every second. If your users have passwords which are lowercase, alphanumeric, and 6 characters long, you can try every single possible password of that size in around 40 seconds.

For PHP 5.5, use password_hash(). For PHP 5.3.7 through PHP 5.4.x use the password_compat polyfill on GitHub.

Read the full article at codahale.com

Apple Watch Favors Text Version and Breaks Links

The next generation of responsive emails: make the text version easy to read on Apple Watches

 

From the article: “When Apple Watch detects remote or linked images in an email, the plain text version will be displayed–but only after a lengthy warning: “This message contains elements Apple Watch can’t display. You can read a text version below.” This message is reminiscent of the warning that Outlook displays before ALT text on images and takes up a full screen of Watch real estate before displaying the plain text part of the message.”

Read more from the source: litmus.com