diff options
-rwxr-xr-x | bin/send-alerts | 4 | ||||
-rwxr-xr-x | bin/send-questionnaires | 4 | ||||
-rw-r--r-- | conf/crontab.ugly | 4 | ||||
-rw-r--r-- | conf/general-example | 5 | ||||
-rw-r--r-- | db/alert_types.sql | 6 | ||||
-rw-r--r-- | db/schema.sql | 4 | ||||
-rw-r--r-- | perllib/Page.pm | 30 | ||||
-rw-r--r-- | templates/emails/alert-confirm | 6 | ||||
-rw-r--r-- | templates/emails/alert-problem | 4 | ||||
-rw-r--r-- | templates/emails/alert-update | 2 | ||||
-rw-r--r-- | templates/emails/problem-confirm | 6 | ||||
-rw-r--r-- | templates/emails/questionnaire | 6 | ||||
-rw-r--r-- | templates/emails/submit-council | 16 | ||||
-rw-r--r-- | templates/emails/update-confirm | 4 | ||||
-rwxr-xr-x | web-admin/index.cgi | 18 | ||||
-rwxr-xr-x | web/about.cgi | 4 | ||||
-rwxr-xr-x | web/alert.cgi | 4 | ||||
-rwxr-xr-x | web/confirm.cgi | 105 | ||||
-rwxr-xr-x | web/contact.cgi | 10 | ||||
-rw-r--r-- | web/css.css | 26 | ||||
-rwxr-xr-x | web/faq.cgi | 19 | ||||
-rwxr-xr-x | web/index.cgi | 80 | ||||
-rw-r--r-- | web/js.js | 2 | ||||
-rwxr-xr-x | web/photo.cgi | 4 | ||||
-rwxr-xr-x | web/report.cgi | 12 | ||||
-rwxr-xr-x | web/rss.cgi | 4 | ||||
-rw-r--r-- | web/xsl.xsl | 4 |
27 files changed, 206 insertions, 187 deletions
diff --git a/bin/send-alerts b/bin/send-alerts index a9ccb8dba..ef272ae6f 100755 --- a/bin/send-alerts +++ b/bin/send-alerts @@ -1,12 +1,12 @@ #!/usr/bin/perl -w # send-alerts: -# Email alerts for Neighbourhood Fix-It +# Email alerts for FixMyStreet # # Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved. # Email: matthew@mysociety.org. WWW: http://www.mysociety.org # -# $Id: send-alerts,v 1.1 2007-01-26 01:01:22 matthew Exp $ +# $Id: send-alerts,v 1.2 2007-06-15 14:57:51 matthew Exp $ use strict; require 5.8.0; diff --git a/bin/send-questionnaires b/bin/send-questionnaires index a13ab4faa..8bfde81d8 100755 --- a/bin/send-questionnaires +++ b/bin/send-questionnaires @@ -6,7 +6,7 @@ # Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved. # Email: matthew@mysociety.org. WWW: http://www.mysociety.org # -# $Id: send-questionnaires,v 1.4 2007-05-08 18:16:34 matthew Exp $ +# $Id: send-questionnaires,v 1.5 2007-06-15 14:57:51 matthew Exp $ use strict; require 5.8.0; @@ -80,7 +80,7 @@ foreach my $row (@$unsent) { _template_ => $template, _parameters_ => \%h, To => [ [ $row->{email}, $row->{name} ] ], - From => [ mySociety::Config::get('CONTACT_EMAIL'), 'Neighbourhood Fix-It' ], + From => [ mySociety::Config::get('CONTACT_EMAIL'), 'FixMyStreet' ], }); print "Sending questionnaire $id, problem $row->{id}, token $token to $row->{email}\n" if $verbose; diff --git a/conf/crontab.ugly b/conf/crontab.ugly index f6776cdb8..06911dd30 100644 --- a/conf/crontab.ugly +++ b/conf/crontab.ugly @@ -4,13 +4,13 @@ # Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved. # Email: matthew@mysociety.org. WWW: http://www.mysociety.org/ # -# $Id: crontab.ugly,v 1.8 2007-05-08 18:16:35 matthew Exp $ +# $Id: crontab.ugly,v 1.9 2007-06-15 14:57:51 matthew Exp $ PATH=/usr/local/bin:/usr/bin:/bin !!(* if ($vhost eq "matthew.bci.mysociety.org") { *)!! MAILTO=matthew@mysociety.org !!(* } else {*)!! -MAILTO=team@neighbourhoodfixit.com +MAILTO=team@fixmystreet.com !!(* } *)!! */5 * * * * !!(*= $user *)!! run-with-lockfile -n /data/vhost/!!(*= $vhost *)!!/send-reports.lock /data/vhost/!!(*= $vhost *)!!/mysociety/bci/bin/send-reports || echo "stalled?" diff --git a/conf/general-example b/conf/general-example index 5f1ed729b..2fe7d66f4 100644 --- a/conf/general-example +++ b/conf/general-example @@ -14,7 +14,7 @@ * Copyright (c) 2006 UK Citizens Online Democracy. All rights reserved. * Email: francis@mysociety.org; WWW: http://www.mysociety.org * - * $Id: general-example,v 1.10 2007-04-11 10:34:48 matthew Exp $ + * $Id: general-example,v 1.11 2007-06-15 14:57:51 matthew Exp $ * */ @@ -33,7 +33,7 @@ define('OPTION_DRESS_DB_PASS', ''); define('OPTION_BASE_URL', 'http://www.example.org'); define('OPTION_CONTACT_EMAIL', 'team@example.org'); -define('OPTION_CONTACT_NAME', 'Neighbourhood Fix-It'); +define('OPTION_CONTACT_NAME', 'FixMyStreet'); define('OPTION_STAGING_SITE', 1); define('OPTION_GEO_CACHE', '/cache/'); @@ -41,6 +41,7 @@ define('OPTION_GEO_CACHE', '/cache/'); define('OPTION_MAPIT_URL', 'http://services.mysociety.org/mapit'); define('OPTION_TILES_URL', 'http://tilma.mysociety.org/tileserver/10k-full-london'); define('OPTION_EVEL_URL', 'http://services.mysociety.org/evel'); +define('OPTION_GAZE_URL', 'http://gaze.mysociety.org/gaze'); define('OPTION_SMTP_SMARTHOST', 'localhost'); diff --git a/db/alert_types.sql b/db/alert_types.sql index 63322f986..7f157c453 100644 --- a/db/alert_types.sql +++ b/db/alert_types.sql @@ -14,7 +14,7 @@ insert into alert_type item_table, item_where, item_order, item_title, item_link, item_description, template) values ('new_problems', '', '', - 'New problems on Neighbourhood Fix-It', '/', 'The latest problems reported by users', + 'New problems on FixMyStreet', '/', 'The latest problems reported by users', 'problem', 'problem.state in (\'confirmed\', \'fixed\')', 'created desc', '{{title}}', '/?id={{id}}', '{{detail}}', 'alert-problem'); @@ -24,7 +24,7 @@ insert into alert_type item_table, item_where, item_order, item_title, item_link, item_description, template) values ('local_problems', '', '', - 'New local problems on Neighbourhood Fix-It', '/', 'The latest local problems reported by users', + 'New local problems on FixMyStreet', '/', 'The latest local problems reported by users', 'problem_find_nearby(?, ?, ?) as nearby,problem', 'nearby.problem_id = problem.id and problem.state in (\'confirmed\', \'fixed\')', 'created desc', '{{title}}', '/?id={{id}}', '{{detail}}', 'alert-problem'); @@ -34,7 +34,7 @@ insert into alert_type item_table, item_where, item_order, item_title, item_link, item_description, template) values ('council_problems', '', '', - 'New local problems on Neighbourhood Fix-It', '/report', 'The latest local problems reported by users', + 'New local problems on FixMyStreet', '/report', 'The latest local problems reported by users', 'problem', 'problem.state in (\'confirmed\', \'fixed\') and council like \'%\'||?||\'%\'', 'created desc', '{{title}}', '/?id={{id}}', '{{detail}}', 'alert-problem' ); diff --git a/db/schema.sql b/db/schema.sql index 0b8169b79..38b0a61e0 100644 --- a/db/schema.sql +++ b/db/schema.sql @@ -1,10 +1,10 @@ -- schema.sql: --- Schema for Neighbourhood Fix-It database. +-- Schema for FixMyStreet database. -- -- Copyright (c) 2006 UK Citizens Online Democracy. All rights reserved. -- Email: matthew@mysociety.org; WWW: http://www.mysociety.org/ -- --- $Id: schema.sql,v 1.31 2007-05-15 13:43:20 matthew Exp $ +-- $Id: schema.sql,v 1.32 2007-06-15 14:57:51 matthew Exp $ -- -- secret diff --git a/perllib/Page.pm b/perllib/Page.pm index 4afcbc854..3b4e9b0f6 100644 --- a/perllib/Page.pm +++ b/perllib/Page.pm @@ -6,7 +6,7 @@ # Copyright (c) 2006 UK Citizens Online Democracy. All rights reserved. # Email: matthew@mysociety.org; WWW: http://www.mysociety.org/ # -# $Id: Page.pm,v 1.56 2007-06-01 14:29:32 matthew Exp $ +# $Id: Page.pm,v 1.57 2007-06-15 14:57:52 matthew Exp $ # package Page; @@ -46,7 +46,7 @@ sub do_fastcgi { q(<html><head><title>Sorry! Something's gone wrong.</title></head></html>), q(<body>), q(<h1>Sorry! Something's gone wrong.</h1>), - q(<p>Please try again later, or <a href="mailto:team@neighbourhoodfixit.com">email us</a> to let us know.</p>), + q(<p>Please try again later, or <a href="mailto:team@fixmystreet.com">email us</a> to let us know.</p>), q(<hr>), q(<p>The text of the error was:</p>), qq(<blockquote class="errortext">$msg</blockquote>), @@ -84,7 +84,7 @@ EOF $html .= <<EOF; <script type="text/javascript" src="/yui/utilities.js"></script> <script type="text/javascript" src="/js.js"></script> - <title>${title}Neighbourhood Fix-It</title> + <title>${title}FixMyStreet</title> <style type="text/css">\@import url("/css.css");</style> EOF if ($params{rss}) { @@ -97,11 +97,11 @@ EOF EOF my $home = !$title && $ENV{SCRIPT_NAME} eq '/index.cgi' && !$ENV{QUERY_STRING}; $html .= $home ? '<h1 id="header">' : '<div id="header"><a href="/">'; - $html .= 'Neighbourhood Fix-It <span id="beta">' . _('Beta') . '</span>'; + $html .= 'Fix<span id="my">My</span>Street <span id="beta">' . _('Beta') . '</span>'; $html .= $home ? '</h1>' : '</a></div>'; $html .= '<div id="wrapper"><div id="content">'; if (mySociety::Config::get('STAGING_SITE')) { - $html .= '<p id="error">This is a developer site; things might break at any time, and councils are not sent emails (they\'d get annoyed!).</p>'; + #$html .= '<p id="error">This is a developer site; things might break at any time, and councils are not sent emails (they\'d get annoyed!).</p>'; } return $html; } @@ -122,7 +122,7 @@ sub footer { <p id="footer">Built by <a href="http://www.mysociety.org/">mySociety</a>, using some <a href="https://secure.mysociety.org/cvstrac/dir?d=mysociety/bci">clever</a> <a -href="https://secure.mysociety.org/cvstrac/dir?d=mysociety/services/TilMa">code</a>.</p> +href="https://secure.mysociety.org/cvstrac/dir?d=mysociety/services/TilMa">code</a>. Formerly <a href="/faq#nfi">Neighbourhood Fix-It</a>.</p> </body> </html> @@ -307,7 +307,7 @@ sub send_email { mySociety::EvEl::send({ _template_ => $template, _parameters_ => \%h, - From => [mySociety::Config::get('CONTACT_EMAIL'), 'Neighbourhood Fix-It'], + From => [mySociety::Config::get('CONTACT_EMAIL'), 'FixMyStreet'], To => $to, }, $email); my $out; @@ -390,7 +390,7 @@ sub display_problem_text { $problem->{council} =~ s/\|.*//g; my @councils = split /,/, $problem->{council}; my $areas_info = mySociety::MaPit::get_voting_areas_info(\@councils); - my $council = join(' and ', map { canonicalise_council($areas_info->{$_}->{name}) } @councils); + my $council = join(' and ', map { $areas_info->{$_}->{name} } @councils); $out .= $q->br() . $q->small('Sent to ' . $council . ' ' . prettify_duration($problem->{whensent}, 'minute') . ' later'); } @@ -437,18 +437,4 @@ sub display_problem_updates { return $out; } -sub canonicalise_council { - my $c = shift; - if ($c =~ /City of London/) { - $c = "the $c"; - } else { - $c =~ s/City of //; - } - $c =~ s/N\. /North /; - $c =~ s/E\. /East /; - $c =~ s/W\. /West /; - $c =~ s/S\. /South /; - return $c; -} - 1; diff --git a/templates/emails/alert-confirm b/templates/emails/alert-confirm index ea07d147c..8cf3d5e40 100644 --- a/templates/emails/alert-confirm +++ b/templates/emails/alert-confirm @@ -1,9 +1,9 @@ -Subject: Confirm your alert on Neighbourhood Fix-It +Subject: Confirm your alert on FixMyStreet Hi, Please click on the link below to confirm the alert you just -asked to subscribe to on Neighbourhood Fix-It: +asked to subscribe to on FixMyStreet: <?=$values['url']?> @@ -11,4 +11,4 @@ If you can't click the link, please copy and paste it to the address bar of your web browser. -- -The Neighbourhood Fix-It team +The FixMyStreet team diff --git a/templates/emails/alert-problem b/templates/emails/alert-problem index 16dd77e5b..9cae68232 100644 --- a/templates/emails/alert-problem +++ b/templates/emails/alert-problem @@ -1,11 +1,11 @@ -Subject: New problems on Neighbourhood Fix-It +Subject: New problems on FixMyStreet The following new problems have been added: <?=$values['data']?> -- -The Neighbourhood Fix-It team +The FixMyStreet team To stop receiving emails when there are new comments on this problem, please follow this link: <?=$values['unsubscribe_url']?> diff --git a/templates/emails/alert-update b/templates/emails/alert-update index c029b3720..1f8c45665 100644 --- a/templates/emails/alert-update +++ b/templates/emails/alert-update @@ -7,7 +7,7 @@ The following updates have been left on this problem: View or reply to these updates: <?=$values['problem_url']?> -- -The Neighbourhood Fix-It team +The FixMyStreet team To stop receiving emails when there are new comments on this problem, please follow this link: <?=$values['unsubscribe_url']?> diff --git a/templates/emails/problem-confirm b/templates/emails/problem-confirm index 2bc9e80e5..bec176226 100644 --- a/templates/emails/problem-confirm +++ b/templates/emails/problem-confirm @@ -1,9 +1,9 @@ -Subject: Confirm your problem on Neighbourhood Fix-It +Subject: Confirm your problem on FixMyStreet Hi <?=$values['name']?>, Please click on the link below to confirm the problem you just -added to Neighbourhood Fix-It: +added to FixMyStreet: <?=$values['url']?> @@ -14,4 +14,4 @@ And details: <?=$values['detail']?> -- -The Neighbourhood Fix-It team +The FixMyStreet team diff --git a/templates/emails/questionnaire b/templates/emails/questionnaire index c73f2552a..eae609fb8 100644 --- a/templates/emails/questionnaire +++ b/templates/emails/questionnaire @@ -1,8 +1,8 @@ -Subject: Questionnaire about your problem on Neighbourhood Fix-It +Subject: Questionnaire about your problem on FixMyStreet Hi <?=$values['name']?>, -<?=$values['created']?> ago, you left a problem on Neighbourhood Fix-It +<?=$values['created']?> ago, you left a problem on FixMyStreet with the details provided at the end of this email. To keep our site up to date and relevant, we'd appreciate it if you could fill in this short questionnaire updating the status of your problem: @@ -10,7 +10,7 @@ this short questionnaire updating the status of your problem: <?=$values['url']?> Yours, -The Neighbourhood Fix-It team +The FixMyStreet team Your problem was as follows: diff --git a/templates/emails/submit-council b/templates/emails/submit-council index 61ab07a2f..46ebe8798 100644 --- a/templates/emails/submit-council +++ b/templates/emails/submit-council @@ -3,7 +3,7 @@ Subject: Problem Report: <?=$values['title']?> Dear <?=$values['councils_name']?>, <?=$values['missing']?><?=$values['multiple']?>A user of -Neighbourhood Fix-It has submitted the following report +FixMyStreet has submitted the following report of a local problem that they believe might require your attention. <?=$values['fuzzy']?>, or to provide an update on the problem, @@ -25,12 +25,12 @@ Details: <?=$values['detail']?> Replies to this email will go to the user who submitted the problem. -Yours, The Neighbourhood Fix-It team +Yours, The FixMyStreet team -[ This message was sent via NeighbourhoodFixIt.com, a project of -UKCOD, registered charity number 1076346. If there is a more -appropriate email address for messages about <?=$values['category_footer']?>, -please let us know by sending an email to <team@neighbourhoodfixit.com>. -This will help improve the service for local people. We also welcome -any other feedback you may have. ] +[ This message was sent via FixMyStreet (the new name for Neighbourhood +Fix-It), a project of UKCOD, registered charity number 1076346. If there +is a more appropriate email address for messages about +<?=$values['category_footer']?>, please let us know by sending an email +to <team@fixmystreet.com>. This will help improve the service for local +people. We also welcome any other feedback you may have. ] diff --git a/templates/emails/update-confirm b/templates/emails/update-confirm index d5d7c5138..c7a36019e 100644 --- a/templates/emails/update-confirm +++ b/templates/emails/update-confirm @@ -1,4 +1,4 @@ -Subject: Confirm your update on Neighbourhood Fix-It +Subject: Confirm your update on FixMyStreet Hi <?=$values['name']?>, @@ -11,4 +11,4 @@ Your update reads: <?=$values['update']?> -- -The Neighbourhood Fix-It team +The FixMyStreet team diff --git a/web-admin/index.cgi b/web-admin/index.cgi index e902dc216..aaf575ec4 100755 --- a/web-admin/index.cgi +++ b/web-admin/index.cgi @@ -2,15 +2,15 @@ # # index.cgi # -# Administration interface for Neighbourhood Fix-It +# Administration interface for FixMyStreet # # Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved. # Email: francis@mysociety.org; WWW: http://www.mysociety.org/ # -# $Id: index.cgi,v 1.42 2007-06-15 10:03:35 francis Exp $ +# $Id: index.cgi,v 1.43 2007-06-15 14:57:53 matthew Exp $ # -my $rcsid = ''; $rcsid .= '$Id: index.cgi,v 1.42 2007-06-15 10:03:35 francis Exp $'; +my $rcsid = ''; $rcsid .= '$Id: index.cgi,v 1.43 2007-06-15 14:57:53 matthew Exp $'; use strict; @@ -49,7 +49,7 @@ sub html_head($$) { $ret .= <<END; <html> <head> -<title>$title - Neighbourhood Fix-it administration</title> +<title>$title - FixMyStreet administration</title> <style type="text/css"><!-- input { font-size: 9pt; margin: 0px; padding: 0px } table { margin: 0px; padding: 0px } @@ -65,7 +65,7 @@ END 'councilslist' => 'Council contacts' }; $ret .= $q->p( - $q->strong("Neighbourhood Fix-it admin:"), + $q->strong("FixMyStreet admin:"), map { $q->a( {href=>build_url($q, $q->url('relative'=>1), { page => $_ })}, $pages->{$_}) } keys %$pages ); @@ -172,7 +172,7 @@ sub do_councils_list ($) { } my $councils = mySociety::MaPit::get_voting_areas_info(\@councils); my @councils_ids = keys %$councils; - @councils_ids = sort { Page::canonicalise_council($councils->{$a}->{name}) cmp Page::canonicalise_council($councils->{$b}->{name}) } @councils_ids; + @councils_ids = sort { $councils->{$a}->{name} cmp $councils->{$b}->{name} } @councils_ids; my $bci_info = dbh()->selectall_hashref(" select area_id, count(*) as c, count(case when deleted then 1 else null end) as deleted, count(case when confirmed then 1 else null end) as confirmed @@ -191,7 +191,7 @@ sub do_councils_list ($) { map { $q->a({href=>build_url($q, $q->url('relative'=>1), {'area_id' => $_, 'page' => 'councilcontacts',})}, - Page::canonicalise_council($councils->{$_}->{name})) . " " . + $councils->{$_}->{name}) . " " . ($bci_info->{$_} ? $bci_info->{$_}->{c} . ' addresses' : '') @@ -352,8 +352,8 @@ sub do_council_edit ($$$) { # Example postcode my $example_postcode = mySociety::MaPit::get_example_postcode($area_id); if ($example_postcode) { - print $q->p("Example postcode to test on NeighbourHoodFixit.com: ", - $q->a({href => build_url($q, "http://www.neighbourhoodfixit.com/", + print $q->p("Example postcode to test on FixMyStreet.com: ", + $q->a({href => build_url($q, "http://www.fixmystreet.com/", { 'pc' => $example_postcode}) }, $example_postcode)); } diff --git a/web/about.cgi b/web/about.cgi index a302eb3f0..82e6a234e 100755 --- a/web/about.cgi +++ b/web/about.cgi @@ -1,12 +1,12 @@ #!/usr/bin/perl -w # about.cgi: -# About page for Neighbourhood Fix-It +# About page for FixMyStreet # # Copyright (c) 2006 UK Citizens Online Democracy. All rights reserved. # Email: matthew@mysociety.org. WWW: http://www.mysociety.org # -# $Id: about.cgi,v 1.3 2007-06-01 14:24:41 matthew Exp $ +# $Id: about.cgi,v 1.4 2007-06-15 14:57:52 matthew Exp $ use strict; require 5.8.0; diff --git a/web/alert.cgi b/web/alert.cgi index 050f3cf9b..d482d3513 100755 --- a/web/alert.cgi +++ b/web/alert.cgi @@ -1,12 +1,12 @@ #!/usr/bin/perl -w # alert.cgi: -# Alert code for Neighbourhood Fix-It +# Alert code for FixMyStreet # # Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved. # Email: matthew@mysociety.org. WWW: http://www.mysociety.org # -# $Id: alert.cgi,v 1.6 2007-06-01 14:24:41 matthew Exp $ +# $Id: alert.cgi,v 1.7 2007-06-15 14:57:52 matthew Exp $ use strict; require 5.8.0; diff --git a/web/confirm.cgi b/web/confirm.cgi index 9c18726c7..cdc59236a 100755 --- a/web/confirm.cgi +++ b/web/confirm.cgi @@ -1,12 +1,12 @@ #!/usr/bin/perl -w # confirm.cgi: -# Confirmation code for Neighbourhood Fix-It +# Confirmation code for FixMyStreet # # Copyright (c) 2006 UK Citizens Online Democracy. All rights reserved. # Email: matthew@mysociety.org. WWW: http://www.mysociety.org # -# $Id: confirm.cgi,v 1.19 2007-06-01 14:24:41 matthew Exp $ +# $Id: confirm.cgi,v 1.20 2007-06-15 14:57:52 matthew Exp $ use strict; require 5.8.0; @@ -43,53 +43,14 @@ sub main { my $id = mySociety::AuthToken::retrieve($type, $token); if ($id) { if ($type eq 'update') { - dbh()->do("update comment set state='confirmed' where id=? and state='unconfirmed'", {}, $id); - my ($email) = dbh()->selectrow_array("select email from comment where id=?", {}, $id); - my ($problem_id, $fixed) = dbh()->selectrow_array("select problem_id,mark_fixed from comment where id=?", {}, $id); - if ($fixed) { - dbh()->do("update problem set state='fixed', lastupdate = ms_current_timestamp() - where id=? and state='confirmed'", {}, $problem_id); - } else { - # Only want to refresh problem if not already fixed - dbh()->do("update problem set lastupdate = ms_current_timestamp() - where id=? and state='confirmed'", {}, $problem_id); - } - my $salt = unpack('h*', random_bytes(8)); - my $secret = scalar(dbh()->selectrow_array('select secret from secret')); - my $signed_email = sha1_hex("$problem_id-$email-$salt-$secret"); - $out = '<form action="/alert" method="post">'; - $out .= $q->p(sprintf(_('You have successfully confirmed your update and you can now <a href="%s">view it on the site</a>.'), "/?id=$problem_id#update_$id")); - my $signup = <<EOF; -<input type="hidden" name="signed_email" value="$salt,$signed_email"> -<input type="hidden" name="email" value="$email"> -<input type="hidden" name="id" value="$problem_id"> -<input type="hidden" name="type" value="updates"> -EOF - $signup .= '<input type="submit" value="' . _('sign up') . '">'; - $out .= $q->p(sprintf(_('You could also <a href="%s">subscribe to the RSS feed</a> of updates by other local people on this problem, or %s if you wish to receive updates by email.'), "/rss/$problem_id", $signup)); - $out .= '</form>'; + my $problem_id; + ($out, $problem_id) = confirm_update($q, $id); + my $email = dbh()->selectrow_array("select email from comment where id=?", {}, $id); + $out .= advertise_updates($q, $problem_id, $email); } elsif ($type eq 'problem') { - dbh()->do("update problem set state='confirmed', confirmed=ms_current_timestamp(), lastupdate=ms_current_timestamp() - where id=? and state='unconfirmed'", {}, $id); - my ($email, $council) = dbh()->selectrow_array("select email, council from problem where id=?", {}, $id); - my $salt = unpack('h*', random_bytes(8)); - my $secret = scalar(dbh()->selectrow_array('select secret from secret')); - my $signed_email = sha1_hex("$id-$email-$salt-$secret"); - $out = '<form action="/alert" method="post">'; - $out .= $q->p( - _('You have successfully confirmed your problem') - . ($council ? _(' and <strong>we will now send it to the council</strong>') : '') - . sprintf(_('. You can <a href="%s">view the problem on this site</a>.'), "/?id=$id") - ); - my $signup = <<EOF; -<input type="hidden" name="signed_email" value="$salt,$signed_email"> -<input type="hidden" name="email" value="$email"> -<input type="hidden" name="id" value="$id"> -<input type="hidden" name="type" value="updates"> -EOF - $signup .= '<input type="submit" value="' . _('sign up') . '">'; - $out .= $q->p(sprintf(_('You could also <a href="%s">subscribe to the RSS feed</a> of updates by other local people on this problem, or %s if you wish to receive updates by email.'), "/rss/$id", $signup)); - $out .= '</form>'; + $out = confirm_problem($q, $id); + my $email = dbh()->selectrow_array("select email from problem where id=?", {}, $id); + $out .= advertise_updates($q, $id, $email); } dbh()->commit(); } else { @@ -107,3 +68,51 @@ EOF } Page::do_fastcgi(\&main); +sub confirm_update { + my ($q, $id) = @_; + dbh()->do("update comment set state='confirmed' where id=? and state='unconfirmed'", {}, $id); + my ($problem_id, $fixed) = dbh()->selectrow_array("select problem_id,mark_fixed from comment where id=?", {}, $id); + if ($fixed) { + dbh()->do("update problem set state='fixed', lastupdate = ms_current_timestamp() + where id=? and state='confirmed'", {}, $problem_id); + } else { + # Only want to refresh problem if not already fixed + dbh()->do("update problem set lastupdate = ms_current_timestamp() + where id=? and state='confirmed'", {}, $problem_id); + } + my $out = '<form action="/alert" method="post">'; + $out .= $q->p(sprintf(_('You have successfully confirmed your update and you can now <a href="%s">view it on the site</a>.'), "/?id=$problem_id#update_$id")); + return ($problem_id, $out); +} + +sub confirm_problem { + my ($q, $id) = @_; + dbh()->do("update problem set state='confirmed', confirmed=ms_current_timestamp(), lastupdate=ms_current_timestamp() + where id=? and state='unconfirmed'", {}, $id); + my $council = dbh()->selectrow_array("select council from problem where id=?", {}, $id); + my $out = '<form action="/alert" method="post">'; + $out .= $q->p( + _('You have successfully confirmed your problem') + . ($council ? _(' and <strong>we will now send it to the council</strong>') : '') + . sprintf(_('. You can <a href="%s">view the problem on this site</a>.'), "/?id=$id") + ); + return $out; +} + +sub advertise_updates { + my ($q, $problem_id, $email) = @_; + my $salt = unpack('h*', random_bytes(8)); + my $secret = scalar(dbh()->selectrow_array('select secret from secret')); + my $signed_email = sha1_hex("$problem_id-$email-$salt-$secret"); + my $signup = <<EOF; +<input type="hidden" name="signed_email" value="$salt,$signed_email"> +<input type="hidden" name="email" value="$email"> +<input type="hidden" name="id" value="$problem_id"> +<input type="hidden" name="type" value="updates"> +EOF + $signup .= '<input type="submit" value="' . _('sign up') . '">'; + my $out = $q->p(sprintf(_('You could also <a href="%s">subscribe to the RSS feed</a> of updates by other local people on this problem, or %s if you wish to receive updates by email.'), "/rss/$problem_id", $signup)); + $out .= '</form>'; + return $out; +} + diff --git a/web/contact.cgi b/web/contact.cgi index 971b9793a..eaaadcf91 100755 --- a/web/contact.cgi +++ b/web/contact.cgi @@ -1,12 +1,12 @@ #!/usr/bin/perl -w # contact.cgi: -# Contact page for Neighbourhood Fix-It +# Contact page for FixMyStreet # # Copyright (c) 2006 UK Citizens Online Democracy. All rights reserved. # Email: matthew@mysociety.org. WWW: http://www.mysociety.org # -# $Id: contact.cgi,v 1.19 2007-06-01 14:24:41 matthew Exp $ +# $Id: contact.cgi,v 1.20 2007-06-15 14:57:52 matthew Exp $ use strict; require 5.8.0; @@ -78,8 +78,8 @@ sub contact_submit { my $email = mySociety::Email::construct_email({ _body_ => "$message\n\n$postfix", From => [$input{email}, $input{name}], - To => [[mySociety::Config::get('CONTACT_EMAIL'), 'Neighbourhood Fix-It']], - Subject => 'NFI message: ' . $subject + To => [[mySociety::Config::get('CONTACT_EMAIL'), 'FixMyStreet']], + Subject => 'FMS message: ' . $subject }); my $result = mySociety::Util::send_email($email, $input{email}, mySociety::Config::get('CONTACT_EMAIL')); if ($result == mySociety::Util::EMAIL_SUCCESS) { @@ -128,7 +128,7 @@ sub contact_page { } else { $out .= <<EOF; <p>Please do <strong>not</strong> report problems through this form; messages go to -the team behind Neighbourhood Fix-It, not a council. To report a problem, +the team behind FixMyStreet, not a council. To report a problem, please <a href="/">go to the front page</a> and follow the instructions.</p> <p>We'd love to hear what you think about this site. Just fill in the form:</p> diff --git a/web/css.css b/web/css.css index 4fe06bf4b..5e4bf32c3 100644 --- a/web/css.css +++ b/web/css.css @@ -100,7 +100,13 @@ ul#error { color: #5e552b; } +#my { + color: #4e451b; + background-color: #e3d595; +} #beta { + color: #6e653b; + background-color: #e3d595; font-size: 50%; font-style: italic; } @@ -159,7 +165,7 @@ ul#error { font-size: 83%; border-top: solid 1px #5e552b; display: table; - margin: 1em 0 1em auto; + margin: 2em 0 1em auto; padding: 2px 4px; } @@ -169,7 +175,6 @@ ul#error { text-align: center; font-size: 150%; margin: 0 2em; - font-weight: bolder; } #postcodeForm { @@ -203,11 +208,6 @@ ul#error { margin-top: 0; } -#front_stats { - margin: 0.5em auto 0; - width: 20em; -} - #front_stats div { text-align: center; width: 5.5em; @@ -215,7 +215,7 @@ ul#error { -moz-border-radius: 0.5em; border-radius: 0.5em; float: left; - margin: 0 0.5em 1em; + margin: 0 1em 1em; } #front_stats div big { @@ -231,7 +231,7 @@ ul#error { margin-right: 0.25em; margin-bottom: 0.25em; } -#front_recent > h2:first-child { +#front_recent > h2:first-child, #front_intro > h2:first-child { margin-top: 0; } @@ -322,6 +322,14 @@ p#copyright { border: 0; } +#text_map { + margin-top: 0.5em; + margin-bottom: 0.5em; +} +#text_no_map { + margin-top: 0; +} + /* ol#current img { position: absolute; diff --git a/web/faq.cgi b/web/faq.cgi index 859a6d6ab..09884a549 100755 --- a/web/faq.cgi +++ b/web/faq.cgi @@ -1,12 +1,12 @@ #!/usr/bin/perl -w # faq.cgi: -# FAQ page for Neighbourhood Fix-It +# FAQ page for FixMyStreet # # Copyright (c) 2006 UK Citizens Online Democracy. All rights reserved. # Email: matthew@mysociety.org. WWW: http://www.mysociety.org # -# $Id: faq.cgi,v 1.20 2007-06-01 14:24:41 matthew Exp $ +# $Id: faq.cgi,v 1.21 2007-06-15 14:57:52 matthew Exp $ use strict; require 5.8.0; @@ -30,8 +30,8 @@ sub faq { my $q = shift; my $out = $q->h1(_('Frequently Asked Questions')); $out .= $q->dl( - $q->dt(_('What is Neighbourhood Fix-It for?')), - $q->dd(_('Neighbourhood Fix-It is a site to help people report, view, + $q->dt(_('What is FixMyStreet for?')), + $q->dd(_('FixMyStreet is a site to help people report, view, or discuss local problems they’ve found to their local council by simply locating them on a map. It launched in beta early February 2007.')), @@ -50,7 +50,7 @@ council can then resolve the problem the way they normally would. Alternatively, you can discuss the problem on the website with others, and then together lobby the council to fix it, or fix it directly yourselves.')), $q->dt(_('Is it free?')), - $q->dd(_('The site is free to use, yes. Neighbourhood Fix-It is run + $q->dd(_('The site is free to use, yes. FixMyStreet is run by a registered charity, though, so if you want to make a contribution, <a href="https://secure.mysociety.org/donate/">please do</a>.')), ); @@ -87,17 +87,20 @@ about updates to a particular problem.')) ); $out .= $q->h2(_('Organisation Questions')); $out .= $q->dl( - $q->dt(_('Who built Neighbourhood Fix-It?')), + $q->dt(_('Who built FixMyStreet?')), $q->dd(_('This site was built by <a href="http://www.mysociety.org">mySociety</a>. mySociety is the project of a registered charity which has grown out of the community of volunteers who built sites like <a href="http://www.theyworkforyou.com/">TheyWorkForYou.com</a>. mySociety’s primary mission is to build Internet projects which give people simple, tangible benefits in the civic and community aspects of their lives. Our first project -was <a href="http://www.writetothem.com/">WriteToThem.com</a>, where you can write to any of your +was <a href="http://www.writetothem.com/">WriteToThem</a>, where you can write to any of your elected representatives, for free.')), $q->dt(_('Who pays for it?')), - $q->dd(_('Neighbourhood Fix-It was paid for via the Department for + $q->dd(_('FixMyStreet was paid for via the Department for Constitutional Affairs Innovations Fund.')), + $q->dt(_('<a name="nfi"></a>Wasn\'t this site called Neighbourhood Fix-It?')), + $q->dd(_('Yes, we changed the name mid June 2007. We decided +Neighbourhood Fix-It was a bit of a mouthful, hard to spell, and hard to publicise (does the URL have a dash in it or not?). The domain FixMyStreet became available recently, and everyone liked the name.')), $q->dt(_('Do you need any help with the project?')), $q->dd(_('Yes, we can use help in all sorts of ways, technical or non-technical. Please see our <a diff --git a/web/index.cgi b/web/index.cgi index 9f90dd334..eb45ffaeb 100755 --- a/web/index.cgi +++ b/web/index.cgi @@ -1,12 +1,12 @@ #!/usr/bin/perl -w # index.cgi: -# Main code for Neighbourhood Fix-It +# Main code for FixMyStreet # # Copyright (c) 2006 UK Citizens Online Democracy. All rights reserved. # Email: matthew@mysociety.org. WWW: http://www.mysociety.org # -# $Id: index.cgi,v 1.138 2007-06-13 14:56:19 matthew Exp $ +# $Id: index.cgi,v 1.139 2007-06-15 14:57:52 matthew Exp $ use strict; require 5.8.0; @@ -28,6 +28,7 @@ use Page; use mySociety::AuthToken; use mySociety::Config; use mySociety::DBHandle qw(dbh select_all); +use mySociety::Gaze; use mySociety::GeoUtil; use mySociety::Util; use mySociety::MaPit; @@ -87,8 +88,8 @@ sub front_page { my ($q, $error) = @_; my $pc_h = ent($q->param('pc') || ''); my $out = <<EOF; -<p id="expl">Report, view, or discuss local problems -like graffiti, fly tipping, broken paving slabs, or street lighting</p> +<p id="expl"><strong>Report, view, or discuss local problems</strong> +<br><small>(like graffiti, fly tipping, broken paving slabs, or street lighting)</small></p> EOF $out .= '<p id="error">' . $error . '</p>' if ($error); my $fixed = dbh()->selectrow_array("select count(*) from problem where state='fixed' and lastupdate>ms_current_timestamp()-'1 month'::interval"); @@ -103,22 +104,23 @@ EOF <div id="front_intro"> +<h2>How to report a problem</h2> + +<ol> +<li>Enter a nearby postcode, or street name and area +<li>Locate the problem on a map of the area +<li>Enter details of the problem +<li>We send it to the council on your behalf +</ol> + +<h2>FixMyStreet updates</h2> + <div id="front_stats"> <div><big>$new</big> reports in past week</div> <div><big>$fixed</big> fixed in past month</div> <div><big>$updates</big> problem updates</div> </div> -<p>Reports are sent directly to the local council. -Reporting a problem is very simple:</p> - -<ol> -<li>Enter a postcode or street name and area above; -<li>Locate the problem on a high-scale map; -<li>Enter details of the problem; -<li>Submit to the council. -</ol> - </div> <div id="front_recent"> @@ -403,7 +405,7 @@ If this is not the correct location, simply click on the map again. '; if ($details eq 'all') { $out .= '<li>All the details you provide here will be sent to <strong>' - . join('</strong> or <strong>', map { Page::canonicalise_council($areas_info->{$_}->{name}) } @$all_councils) + . join('</strong> or <strong>', map { $areas_info->{$_}->{name} } @$all_councils) . '</strong>. We show the subject and details of the problem on the site, along with your name if you give us permission.'; $out .= '<input type="hidden" name="council" value="' . join(',',@$all_councils) . '">'; @@ -415,9 +417,9 @@ If this is not the correct location, simply click on the map again. '; push @missing, $_ unless $councils{$_}; } my $n = @missing; - my $list = join(' or ', map { Page::canonicalise_council($areas_info->{$_}->{name}) } @missing); + my $list = join(' or ', map { $areas_info->{$_}->{name} } @missing); $out .= '<li>All the details you provide here will be sent to <strong>' - . join('</strong> or <strong>', map { Page::canonicalise_council($areas_info->{$_}->{name}) } @councils) + . join('</strong> or <strong>', map { $areas_info->{$_}->{name} } @councils) . '</strong>. We show the subject and details of the problem on the site, along with your name if you give us permission.'; $out .= ' We do <strong>not</strong> yet have details for the other council'; @@ -428,7 +430,7 @@ problems for $list and emailing it to us at <a href='mailto:$e'>$e</a>."; . '|' . join(',', @missing) . '">'; } else { my $e = mySociety::Config::get('CONTACT_EMAIL'); - my $list = join(' or ', map { Page::canonicalise_council($areas_info->{$_}->{name}) } @$all_councils); + my $list = join(' or ', map { $areas_info->{$_}->{name} } @$all_councils); my $n = @$all_councils; $out .= '<li>We do not yet have details for the council'; $out .= ($n>1) ? 's that cover' : ' that covers'; @@ -481,7 +483,7 @@ $category <li>Please do not be abusive — abusing your council devalues the service for all users. <li>Writing your message entirely in block capitals makes it hard to read, as does a lack of punctuation. -<li>Remember that Neighbourhood Fix-It is primarily for reporting physical +<li>Remember that FixMyStreet is primarily for reporting physical problems that can be fixed. If your problem is not appropriate for submission via this site remember that you can contact your council directly using their own website. @@ -515,15 +517,17 @@ sub display_location { return geocode_choice($error) if (ref($error) eq 'ARRAY'); return front_page($q, $error) if ($error); - my ($pins, $current_map, $current, $fixed) = map_pins($q, $x, $y); + my ($pins, $current_map, $current, $fixed, $dist) = map_pins($q, $x, $y); my $out = Page::display_map($q, x => $x, y => $y, type => 1, pins => $pins ); - $out .= '<h1>Click on the map to report a problem</h1>'; + $out .= '<h1>Problems in this area</h1>'; if (@errors) { $out .= '<ul id="error"><li>' . join('</li><li>', @errors) . '</li></ul>'; } my $skipurl = NewURL($q, 'submit_map'=>1, skipped=>1); $out .= <<EOF; -<p><small>If you cannot see a map – if you have images turned off, +<p id="text_map">To report a problem, simply <strong>click on the map</strong> at the correct location.</p> + +<p id="text_no_map"><small>If you cannot see a map – if you have images turned off, or are using a text only browser, for example – and you wish to report a problem, please <a href="$skipurl">skip this step</a> and we will ask you @@ -531,7 +535,7 @@ to describe the location of your problem instead.</small></p> EOF $out .= <<EOF; <div> -<h2>Recent problems reported on this map</h2> +<h2>Recent problems reported near here</h2> EOF my $list = ''; foreach (@$current_map) { @@ -545,7 +549,7 @@ EOF $out .= '<p>No problems have been reported yet.</p>'; } $out .= <<EOF; - <h2>Closest problems within 10km</h2> + <h2>Closest problems within ${dist}km</h2> <p><a href="/rss/$x,$y"><img align="right" src="/i/feed.png" width="16" height="16" title="RSS feed of recent local problems" alt="RSS feed" border="0"></a></p> EOF $list = ''; @@ -561,7 +565,7 @@ EOF $out .= '<p>No problems have been reported yet.</p>'; } $out .= <<EOF; - <h2>Recently fixed problems within 10km</h2> + <h2>Recently fixed problems within ${dist}km</h2> EOF $list = ''; foreach (@$fixed) { @@ -578,7 +582,7 @@ EOF $out .= Page::display_map_end(1); my %params = ( - rss => [ 'Recent local problems, Neighbourhood Fix-It', "/rss/$x,$y" ] + rss => [ 'Recent local problems, FixMyStreet', "/rss/$x,$y" ] ); return ($out, %params); @@ -623,6 +627,10 @@ sub display_problem { $out .= $q->p({align=>'right'}, $q->small($q->a({href => '/contact?id=' . $input{id}}, 'Offensive? Unsuitable? Tell us')) ); + + # Try and have pin near centre of map + $x_tile -= 1 if $x - $x_tile < 0.5; + $y_tile -= 1 if $y - $y_tile < 0.5; my $back = NewURL($q, id=>undef, x=>$x_tile, y=>$y_tile); $out .= '<p style="padding-bottom: 0.5em; border-bottom: dotted 1px #999999;" align="right"><a href="' . $back . '">More problems nearby</a></p>'; @@ -670,7 +678,7 @@ EOF $out .= Page::display_map_end(0); my %params = ( - rss => [ 'Updates to this problem, Neighbourhood Fix-It', "/rss/$input_h{id}" ], + rss => [ 'Updates to this problem, FixMyStreet', "/rss/$input_h{id}" ], title => $problem->{title} ); return ($out, %params); @@ -680,12 +688,12 @@ sub map_pins { my ($q, $x, $y) = @_; my $pins = ''; - my $min_e = Page::tile_to_os($x); - my $min_n = Page::tile_to_os($y); + my $min_e = Page::tile_to_os($x-1); + my $min_n = Page::tile_to_os($y-1); my $mid_e = Page::tile_to_os($x+1); my $mid_n = Page::tile_to_os($y+1); - my $max_e = Page::tile_to_os($x+2); - my $max_n = Page::tile_to_os($y+2); + my $max_e = Page::tile_to_os($x+3); + my $max_n = Page::tile_to_os($y+3); my $current_map = select_all( "select id,title,easting,northing from problem where state='confirmed' @@ -701,6 +709,10 @@ sub map_pins { $pins .= Page::display_pin($q, $px, $py, 'red', $count_prob++); } + my ($lat, $lon) = mySociety::GeoUtil::national_grid_to_wgs84($mid_e, $mid_n, 'G'); + my $dist = mySociety::Gaze::get_radius_containing_population($lat, $lon, 200000); + $dist = int($dist*10+0.5)/10; + # XXX: Change to only show problems with extract(epoch from ms_current_timestamp()-lastupdate) < 8 weeks # And somehow display/link to old problems somewhere else... my $current = []; @@ -708,7 +720,7 @@ sub map_pins { my $limit = 9 - @$current_map; $current = select_all( "select id, title, easting, northing, distance - from problem_find_nearby(?, ?, 10) as nearby, problem + from problem_find_nearby(?, ?, $dist) as nearby, problem where nearby.problem_id = problem.id and state = 'confirmed'" . (@ids ? ' and id not in (' . join(',' , @ids) . ')' : '') . " order by distance, created desc limit $limit", $mid_e, $mid_n); @@ -720,7 +732,7 @@ sub map_pins { } my $fixed = select_all( "select id, title, easting, northing, distance - from problem_find_nearby(?, ?, 10) as nearby, problem + from problem_find_nearby(?, ?, $dist) as nearby, problem where nearby.problem_id = problem.id and state='fixed' order by created desc limit 9", $mid_e, $mid_n); foreach (@$fixed) { @@ -728,7 +740,7 @@ sub map_pins { my $py = Page::os_to_px($_->{northing}, $y); $pins .= Page::display_pin($q, $px, $py, 'green', $count_fixed++); } - return ($pins, $current_map, $current, $fixed); + return ($pins, $current_map, $current, $fixed, $dist); } sub geocode_choice { @@ -1,6 +1,6 @@ /* * js.js - * Neighbourhood Fix-It JavaScript + * FixMyStreet JavaScript * * TODO * Investigate jQuery diff --git a/web/photo.cgi b/web/photo.cgi index afcfa4751..41e9221ef 100755 --- a/web/photo.cgi +++ b/web/photo.cgi @@ -1,12 +1,12 @@ #!/usr/bin/perl -w # photo.cgi: -# Display a photo for Neighbourhood Fix-It +# Display a photo for FixMyStreet # # Copyright (c) 2006 UK Citizens Online Democracy. All rights reserved. # Email: matthew@mysociety.org. WWW: http://www.mysociety.org # -# $Id: photo.cgi,v 1.4 2007-06-13 14:56:19 matthew Exp $ +# $Id: photo.cgi,v 1.5 2007-06-15 14:57:52 matthew Exp $ use strict; require 5.8.0; diff --git a/web/report.cgi b/web/report.cgi index 947c1b105..753364745 100755 --- a/web/report.cgi +++ b/web/report.cgi @@ -1,12 +1,12 @@ #!/usr/bin/perl -w # report.cgi: -# Display summary reports for Neighbourhood Fix-It +# Display summary reports for FixMyStreet # # Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved. # Email: matthew@mysociety.org. WWW: http://www.mysociety.org # -# $Id: report.cgi,v 1.37 2007-06-15 09:34:45 francis Exp $ +# $Id: report.cgi,v 1.38 2007-06-15 14:57:52 matthew Exp $ use strict; require 5.8.0; @@ -82,11 +82,11 @@ sub main { print '<table cellpadding="3" cellspacing="1" border="0">'; print '<tr><th>Name</th><th>New problems</th><th>Older problems</th> <th>Old problems,<br>state unknown</th><th>Recently fixed</th><th>Old fixed</th></tr>'; - foreach (sort { Page::canonicalise_council($areas_info->{$a}->{name}) cmp Page::canonicalise_council($areas_info->{$b}->{name}) } keys %councils) { + foreach (sort { $areas_info->{$a}->{name} cmp $areas_info->{$b}->{name} } keys %councils) { print '<tr align="center"'; print ' class="a"' if (++$c%2); print '><td align="left"><a href="report?council=' . $_ . '">' . - Page::canonicalise_council($areas_info->{$_}->{name}) . '</a></td>'; + $areas_info->{$_}->{name} . '</a></td>'; summary_cell(\@{$open{$_}{new}}); summary_cell(\@{$open{$_}{older}}); summary_cell(\@{$open{$_}{unknown}}); @@ -96,14 +96,14 @@ sub main { } print '</table>'; } else { - my $name = Page::canonicalise_council($areas_info->{$one_council}->{name}); + my $name = $areas_info->{$one_council}->{name}; if (!$name) { print Page::header($q, title=>"Summary reports"); print "Council with identifier " . ent($one_council). " not found. "; print $q->a({href => NewURL($q, all=>undef, council=>undef) }, 'Show all councils'); print "."; } else { - print Page::header($q, title=>"$name - Summary reports", rss => [ "Problems within $name, Neighbourhood Fix-It", "/rss/council/$one_council" ]); + print Page::header($q, title=>"$name - Summary reports", rss => [ "Problems within $name, FixMyStreet", "/rss/council/$one_council" ]); print $q->p( $q->a({href => "/rss/council/$one_council"}, '<img align="right" src="/i/feed.png" width="16" height="16" title="RSS feed" alt="RSS feed of problems in this council" border="0" hspace="4">'), 'This is a summary of all reports for one council. You can ' . diff --git a/web/rss.cgi b/web/rss.cgi index 804e69faf..46f669dff 100755 --- a/web/rss.cgi +++ b/web/rss.cgi @@ -1,12 +1,12 @@ #!/usr/bin/perl -w # rss.cgi: -# RSS for Neighbourhood Fix-It +# RSS for FixMyStreet # # Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved. # Email: matthew@mysociety.org. WWW: http://www.mysociety.org # -# $Id: rss.cgi,v 1.7 2007-05-16 17:51:21 matthew Exp $ +# $Id: rss.cgi,v 1.8 2007-06-15 14:57:52 matthew Exp $ use strict; require 5.8.0; diff --git a/web/xsl.xsl b/web/xsl.xsl index 19e16c4a7..95eeb0a33 100644 --- a/web/xsl.xsl +++ b/web/xsl.xsl @@ -10,7 +10,7 @@ <link rel="stylesheet" href="/css.css"/> </head> <body> - <div id="header"><a href="/">Neighbourhood Fix-It</a></div> + <div id="header"><a href="/">FixMyStreet</a></div> <div id="wrapper"><div id="content"> <xsl:apply-templates select="rss/channel"/> </div></div> @@ -34,7 +34,7 @@ href="https://secure.mysociety.org/cvstrac/dir?d=mysociety/services/TilMa">code< <xsl:template match="channel"> <div id="rss_box"> <h1>What is this page?</h1> - <p>This is an RSS feed from the Neighbourhood Fix-It website. RSS feeds allow you to stay up to date with the latest changes and additions to the site. + <p>This is an RSS feed from the FixMyStreet website. RSS feeds allow you to stay up to date with the latest changes and additions to the site. To subscribe to it, you will need a News Reader or other similar device. <br/> <a href="http://news.bbc.co.uk/1/hi/help/3223484.stm#whatisrss"><strong>Help</strong>, I don't know what a news reader is and still don't know what this is about (from the BBC).</a></p> |