Replace IDs with classes for more flexibility.
Cleaned up API ajax calls and var naming.
Merge remote-tracking branch 'upstream/master'

Conflicts:
	index.html
Removed extra page api methods, changed how API classes are loaded, tweaked API error reporting.