There is no default float precision qualifier for fragment shaders in OpenGL ES. A precision qualifier is required to use any floating pointer variable - it doesn't matter if it's a uniform, varying, or just a local variable. There is a default precision for vertex shaders, so you don't need to add any qualifiers there.
In OpenGL the precision qualifier is not required, which is why the example you're pointing to does not include them.
Try adding this to the top of your shader and you should be fine:
precision mediump float;