Category: BTEC Information Technology

Where do the cables go?

CableMap

When you want to access a web site outside the United Kingdom the bits have to cross water. Either over (via a microwave link or bounced off a satellite) or under (in an under-sea cable). Greg’s Cable Map shows you where those cables go, with information on things like capacity and activation year.

On land, these big data pipes connect to smaller networks. Typically these connections happen at Internet Exchange Points like those on the map below.

DataCenterMap

Each Internet Exchange Point has lots of different network carriers, for example check out this list for one of the exchanges in London.

Andrew Blum wrote a book about all of this. It’s called Tubes: A journey to the center of the Internet and is a half decent read if you like that sort of thing. I’ll see if the library can get a copy…

Using Key:Value pairs in PHP arrays

J was working on the exercise to display personalised greetings and wondered if there was a better way than lots of:


if($user == "J") {
echo ("J, you're awesome");
}

One method is to create an array of users with their personal message and then use the username as the key to extract their personal message.

Here’s an example:


// create the array
$messages = array (
"Charlie" => "Hello Charlie" ,
"Jordan" => "Watcha Mate" ,
"Nathan" => "Hiya Nathan"
);

// decide who the person is
$person = "Jordan";

// write the message
echo ("

A personal message for " . $person . ": " . $messages["Jordan"]);

There’s a full example on GitHub: https://github.com/MrAFord/L3BTEC-Unit27/blob/master/examples/ArrayLookup.php