Implementing origin checks feature (and required refactoring)...

* Adding origin checking command line flags and help
* Adding functionality of checking in handshake stage
* Moving some code around, creating "remote host information" abstraction
* Now there are tests for origin checking function
Added tests for origin checking functionality

(also fixed bug thanks to testing)
This aggressive refactoring tries to split server and handler funcs...

* Separated high-level server and "handler" elements
* Changed websocket server and handler functions to ones that return closures
* Renamed test since GetURLInfo is now part of handler.go
* Refactored endpoints pipe to be more abstract, make test for it....
* Moved some functionality to start/terminate endpoint into pipe function (this should help with implementation of multiplexing)
* Removed console template and license from showing in godoc.
Patching things back to improve backwards compatibility.
Make Makefile more hermetic.

make would fail if calling did not have gofmt in path.

Set PATH in the ./go wrapper. Upgrade to go 1.2.1
Make example html portable.

This doesn't force localhost instead using location.

This enables eg tunneling to work correctly.
Merge pull request #65 from pnasrat/portable-example

Make example html portable.
Merge pull request #64 from pnasrat/hermetic-makefile

Make Makefile more hermetic.
After-fix for file:// urls in #65
Merge pull request #61 from asergeyev/originchecks

Originchecks per #20, closes #58 too...

--origin and --sameorigin flags added, code refactored to separate some logical parts