Added online lookup, fixed a few bugs.