Don't show diagnostic messages when request is simply local

This fixes the scenario when Alaveteli is behind a proxy in production

Resolves #1039
Make method name clearer
Remove prototype javascript files. We don't seem to be using them, we seem to be using jquery.
Add unobtrusive javascript gem to provide the js side of Rails built-in helpers using the jquery framework rather than prototype.
Include unobtrusive js in the admin layout, where we use the :confirm option of the submit_tag helper. Fixes #1042.
Add the statistics2 gem to the bundle

This is used for the calculation of the confidence
intervals for public body statistics.
Add the flot Javascript graph drawing library version 0.8.1

From the full distribution, this only includes the basic
libary and the component for plotting error bars.
(Flot is MIT licensed.)
Add a Flot extension for drawing axis labels

Suprisingly, there is not support in base Flot for drawing
axis labels - one solution is to use the flot-axislabels
plugin from:

  https://github.com/markrcote/flot-axislabels

This plugin is also MIT-licensed.
Add libxml2-dev and libxslt-dev
They are depended on by nokogiri, depended on in turn by webrat.
Add a page with experimental statistics on public bodies

The statistics on the status of the requests to a particular
public body are too slow to calculate on-the-fly, so this
commit adds:

 * Extra columns on public_bodies to store counts of
   the successful, not held, and overdue request counts
   for each public body.

 * A rake task which should be run periodically to update
   the overdue request count column.

If Javascript is not available, the summary statistics are
shown as tables.  If Javascript is available, graphs are
drawn with Flot.
Make the minimum requests for statistics configurable

This adds the MINIMUM_REQUESTS_FOR_STATISTICS config option.
Add excanvas for support of graph-drawing on IE8 and before

This is as suggested in the Flot documentation.
Add a test for the PublicBodyController statistics action
Improve calculation of PublicBody statistics columns

On PublicBody, we don't need to update info_requests_count
because that's already done with :counter_cache.  On the
other hand, info_requests_successful_count and
info_requests_not_held_count can't be updated easily with
counter_cache (since they need conditions to be attached).
Instead we update them in post_save and post_destroy,
as suggested here:

   http://blog.douglasfshearer.com/post/17495285851/custom-counter-cache-with-conditions

This also adds tests to ensure that the
after_(save|destroy) callbacks are called and that they
modify the counts correctly.
Refer to Javascript object members more idiomatically

Crockford / JSLint suggests using dot notation for referring
to members of objects where possible.
Refactor calculation of statistics

Move the calculation of statistics on public bodies into
the PublicBody model, so that there's less logic in the
controller.
Add a config option to enable the public body statistics page
Reduce the number of public bodies per graph

It seems to be difficult to customize the display of the
tick labels (see the body-statistics-rotated-label branch
for an as-yet-not-working alternative) so for the moment
just reduce the number of public bodies shown per graph
from 10 to 8.
Add some caveats to the experimental statistics page

The statistics we're publishing are potentially subject to
misinterpretation, so add some warnings about their experimental
nature.  Also, add a note crediting Mark Goodge for his useful
work on statistics for WhatDoTheyKnow.
Don't include NULL column values in the statistics

We were already excluding graphs where all the data was NULL
but it's possible by directly manipulating the database to
have some values NULL and some non-NULL, so exclude any NULL
values anyway.