added useragent for ios5 / mobile safari 5.1
update getRequest for 8644289dad8cc7be26b12b5b4d7d37390b6cbcaa
[issue #132] Rename state/content to page/action
[issue #132] More page-action renaming

- Normalize action=run "user" argument to "item"

- Normalize action=tinder "user" argument to "item"

- More left over renames from state to action in HTML, JS and ./scripts/
 * (3f7e9862f7e920a559c4f4c50cd327055a121d70 did this for directory structure, PHP and .htaccess)
 * This makes inject.js no longer backards compatible, if some folks have copied
   that into their own application for whatever reason, this needs updating on
   their end. I know at least MediaWiki did this at some point as a work-around
   for the TestSwarm install not having a permanent location yet and allowing
   other TestSwarm install. Such cases should make a configuration settings for
   something like "testswarm base url" or even "testswarm inject script url" so
   that installs can provide their own. Anything better than copying inject.js
   into your own application which is bad because it breaks the
   client-host (inject.js / testswarm-install) relationship.

 * This is a breaking change for "addjob" submission scripts.
[issue #132] More page-action renaming

- Normalize action=jobstatus "job_id" argument to "item"
Fix problem with action=runresults, due to a php E_NOTICE message being sent out, the gzip decoder failed since there was php error garbage echo'd before the gzip header and stuff.
Fix problem with action=runresults, due to a php E_NOTICE message being sent out, the gzip decoder failed since there was php error garbage echo'd before the gzip header and stuff.
Fix problem with action=runresults, due to a php E_NOTICE message being sent out, the gzip decoder failed since there was php error garbage echo'd before the gzip header and stuff.
Fix problem with action=runresults, due to a php E_NOTICE message being sent out, the gzip decoder failed since there was php error garbage echo'd before the gzip header and stuff.
Merge branch 'issue132' of github.com:Krinkle/testswarm into issue132
fix problems with auto=saverun

- Since the refactor in 2e05eb2efe89316fbf54f33bab6788c76ff6fc78 done() was no longer a
  global function. This was problematic due to the postMessage fallback implementation
  in inject.js which used window.top.done() to indicate that the POST to action=saverun
  was successful.
  Also, that refactor changed retrySend() to contain `data: "json"`, which meant the
  error callback was fired for action=saverun submissions via AJAX. This wasn't entirely
  breaking because the actual POST went fine and results were saved to the database,
  however the client would think that it failed and show an error message while retrying
  a few times and eventually giving up, refreshing the page and everything is fine.
  Now made action=saverun return valid JSON (even though it's response is ignored
  otherwise) for AJAX requests because the AJAX success handler call runDone(), there is
  no need for that HTML there (would only risk it being evaluated by accident).
  But for non-AJAX request it should still return the HTML, to allow old pre-postMessage
  browsers to invoke the callback.

- Made it publicly assessable again via the SWARM object

- Also changed window.top to window.parent everywhere, makes no different in most
  cases. But assuming the parent TestSwarm window is the top window can make things
  very bad if this isn't the case (we've seen these before such as
  http://bugs.jquery.com/ticket/9555).

- Make debugging inject.js a little prettier
[issue #132] Rename tinder to user, and jobstatus to job
- To make them match their url names
[issue #132] Rename tinder to user, and jobstatus to job
- To make them match their url names
- Also fix several E_NOTICE errors in JobPage and UserPage
adding missing semi-colon in run.js from 5f16c1feb3375fd70143c42f43f3247240ef160a
update view.js comment to match the changes made in 5494d77e3ce0d8523805219f220dcf5aeb3ba1ce
[issue #132] New htaccess for page-action

- Instead of adding trailing slashes, remove them.
  swarm.example.org/login
  swarm.example.org/run/123
  swarm.example.org/job/123
  swarm.example.org/user/foo

- Greatly simplify rewrite rules
 * [a-z] -> action
 * [a-z]* -> action with item
 * Removed the [L] modifier, doesn't seem needed
 * Shortened the skip [S=] for paths that begin with a dot.

- Add comments
Refactor inject.js & status.js and fix MySQL error in action-wiperun

- inject.js is now (except for 2 small things) JSHint passing

  The test framework detections and hooking is now in a nicely
  organized object.

- status.js was previously submitting to ".", which sometimes
  caused weird request where there were query  parameters set
  from the current page (e.g. /run/foo, action=run&item=foo),
  then then the POST parameters for action=wiperun or something.

  Now using the new client side config object we have for this,
  SWARM.web.contextpath

  Also:
  * ("table", html) -> (html).find("table");
  * .live() -> $(document).on(,selector,)

- Made action=wiperun response valid JSON, so that the table cell
  can be visually reset only if the wipe was successful.

  Previously anyone whether logged in as anyone or not at all
  could double click a table cell and it would make a POST request,
  it wouldn't actually wipe the run, but regardless the table cell
  was visually reset, only for it to be restored the next 5-second
  interval when the entire table is refreshed.

  Now it only resets the class name if the wipe was successful.

- Update interval is now configurable from INI (default still 5 seconds)

- ./actions/wiperun.php caused a MySQL error everytime, it was looking for run_id,
  in all other tables it is run_id, but in runs itself it is just "id".
  Not sure if this breakage was noticeable in the past, but at least it's fixed now.
[issue #132] Make the page scripts match their respective page action names
[issue #132] Implement basic AutoLoader, we'll need it once we create classes for each action and page, don't want to require_once all of them all the time
[issue #132] Implement Action and Page class

- Implement Action and Page class

- Convert old actions to Action/Page class:
 * HomePage (from pages/home.php)
 * Loginpage (from pages/login.php)
  - fixed bug, when only entering a username or password (not both),
    no error message was shown (just a blank form), fixed now.q
 * LoginAction (from actions/login.php)

- Added helper function `getPageInstance()` in WebRequest class

- Added helper function `html_tag()` in utilities

- Added CSS for `#footer` and `.errorbox`

Old pages (anything except for Home and Login) don't work right now,
they will be converted soon.