Who Moved My Letters
11 Aug 2019
Years ago I saw this website called WhoMovedMyLetters.com, an obvious take on the question "Who Moved My Cheese". This website doesn't exist anymore, but it presented a canvas filled with letters that could by moved. Moving letters across the canvas would move the letter for everyone else who was on the website.

I don't remember looking at the source code so don't really know how it worked. However I thought it would be great to implement this using Javascript and PHP WebSockets. Okay so it turns out that I can't serve unsecure WebSockets over HTTPS, which makes sense because browsers don't want to downgrade security. Secure WebSockets will work but that will take time for me to implement because
  1. PHP does not really support secure WebSockets yet and I'll have to do this with Python.
  2. I'll need time to work out the SSL certificates with my hosting provider.
For now I'll do this using regular WebService calls. This will result in several more calls than I had originally planned, but I'd like to see this work.

There are 86 letters on canvas; the numbers of each letter is spread according to the frequency table that I found here.

The source code is available for download below and is also updated to my GitHub account.
Why'd you click that? Told you it doesn't work.

1. whomovedmyletters.js - Download, index.html
//Code goes here
2. pollsrv.txt - Download, index.html
//Code goes here
3. updpos.txt - Download, index.html
//Code goes here

Javascript Demos

Here's a bunch of javascript... things I wrote over the years whenever time permitted.