aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--templates/website/emptyhomes-header2
-rwxr-xr-xweb/alert.cgi109
-rwxr-xr-xweb/confirm.cgi6
-rwxr-xr-xweb/contact.cgi48
-rw-r--r--web/css/cache-eha2.css493
-rwxr-xr-xweb/index.cgi8
6 files changed, 576 insertions, 90 deletions
diff --git a/templates/website/emptyhomes-header b/templates/website/emptyhomes-header
index e0d86bca5..d2bc3dd57 100644
--- a/templates/website/emptyhomes-header
+++ b/templates/website/emptyhomes-header
@@ -5,7 +5,7 @@
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<script type="text/javascript" src="/yui/utilities.js"></script>
<script type="text/javascript" src="/js.js"></script>
-<link href="http://www.emptyhomes.com/eha2.css" rel="stylesheet" type="text/css">
+<link href="/css/cache-eha2.css" rel="stylesheet" type="text/css">
<style type="text/css" media="screen, projection">
@import "/css/core.css";
@import "/css/emptyhomes.css";
diff --git a/web/alert.cgi b/web/alert.cgi
index 3f721e971..e41164334 100755
--- a/web/alert.cgi
+++ b/web/alert.cgi
@@ -6,7 +6,7 @@
# Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved.
# Email: matthew@mysociety.org. WWW: http://www.mysociety.org
#
-# $Id: alert.cgi,v 1.24 2008-01-30 18:27:48 matthew Exp $
+# $Id: alert.cgi,v 1.25 2008-05-13 16:00:14 matthew Exp $
use strict;
use Standard;
@@ -25,7 +25,7 @@ use mySociety::Web qw(ent);
sub main {
my $q = shift;
my $out = '';
- my $title = 'Confirmation';
+ my $title = _('Confirmation');
if ($q->param('signed_email')) {
$out = alert_signed_input($q);
} elsif (my $token = $q->param('token')) {
@@ -46,10 +46,10 @@ EOF
} elsif ($q->param('id')) {
$out = alert_updates_form($q);
} elsif ($q->param('pc')) {
- $title = 'Local RSS feeds and email alerts';
+ $title = _('Local RSS feeds and email alerts');
$out = alert_list($q);
} else {
- $title = 'Local RSS feeds and email alerts';
+ $title = _('Local RSS feeds and email alerts');
$out = alert_front_page($q);
}
@@ -76,7 +76,7 @@ sub alert_list {
my $areas = mySociety::MaPit::get_voting_areas_by_location({easting=>$e, northing=>$n}, 'polygon', \@types);
$areas = mySociety::MaPit::get_voting_areas_info([ keys %$areas ]);
- return alert_front_page($q, 'That location does not appear to be covered by a council, perhaps it is offshore - please try somewhere more specific.') if keys %$areas == 0;
+ return alert_front_page($q, _('That location does not appear to be covered by a council, perhaps it is offshore - please try somewhere more specific.')) if keys %$areas == 0;
my ($options);
if (keys %$areas == 2) {
@@ -91,9 +91,9 @@ sub alert_list {
}
}
push @options, [ 'council', $council->{area_id}, Page::short_name($council->{name}),
- "Problems within $council->{name}" ];
+ sprintf(_("Problems within %s"), $council->{name}) ];
push @options, [ 'ward', $council->{area_id}.':'.$ward->{area_id}, Page::short_name($council->{name}) . '/'
- . Page::short_name($ward->{name}), "Problems within $ward->{name} ward" ];
+ . Page::short_name($ward->{name}), sprintf(_("Problems within %s ward"), $ward->{name}) ];
$options = '<div>' . $q->ul({id=>'rss_feed'},
alert_list_options($q, @options)
@@ -122,7 +122,7 @@ sub alert_list {
[ 'area', $county->{area_id}.':'.$c_ward->{area_id}, Page::short_name($county->{name}) . '/'
. Page::short_name($c_ward->{name}), "$c_ward->{name} ward, $county->{name}" ];
$options = '<div id="rss_list">';
- $options .= $q->p($q->strong('Problems within the boundary of:')) .
+ $options .= $q->p($q->strong(_('Problems within the boundary of:'))) .
$q->ul(alert_list_options($q, @options));
@options = ();
push @options,
@@ -132,13 +132,13 @@ sub alert_list {
[ 'council', $county->{area_id}, Page::short_name($county->{name}), $county->{name} ],
[ 'ward', $county->{area_id}.':'.$c_ward->{area_id}, Page::short_name($county->{name}) . '/'
. Page::short_name($c_ward->{name}), "$county->{name}, within $c_ward->{name} ward" ];
- $options .= $q->p($q->strong('Or problems reported to:')) .
+ $options .= $q->p($q->strong(_('Or problems reported to:'))) .
$q->ul(alert_list_options($q, @options));
- $options .= $q->p($q->small('FixMyStreet sends different categories of problem
+ $options .= $q->p($q->small(_('FixMyStreet sends different categories of problem
to the appropriate council, so problems within the boundary of a particular council
might not match the problems sent to that council. For example, a graffiti report
will be sent to the district council, so will appear in both that council\'s alerts,
-but will only appear in the "Within the boundary" alert for the county council.'));
+but will only appear in the "Within the boundary" alert for the county council.')));
$options .= '</div>
<div id="rss_buttons">
';
@@ -156,50 +156,46 @@ but will only appear in the "Within the boundary" alert for the county council.'
$checked = ' checked' if $q->param('feed') && $q->param('feed') eq "local:$x:$y";
my $pics = Page::recent_photos(5, $e, $n, $dist);
- $pics = '<div id="alert_photos"><h2>Photos of recent nearby reports</h2>' . $pics . '</div>' if $pics;
-
- <<EOF;
-<h1>Local RSS feeds and email alerts for &lsquo;$input_h{pc}&rsquo;</h1>
+ $pics = '<div id="alert_photos">' . $q->h2(_('Photos of recent nearby reports')) . $pics . '</div>' if $pics;
+ my $out = $q->h1(sprintf(_('Local RSS feeds and email alerts for &lsquo;%s&rsquo;'), $input_h{pc}));
+ $out .= <<EOF;
<form id="alerts" method="post" action="/alert">
<input type="hidden" name="type" value="local">
<input type="hidden" name="pc" value="$input_h{pc}">
$pics
-<p>Here are the types of local problem alerts for &lsquo;$input_h{pc}&rsquo;.
+EOF
+ $out .= $q->p(sprintf(_('Here are the types of local problem alerts for &lsquo;%s&rsquo;.
Select which type of alert you&rsquo;d like and click the button for an RSS
-feed, or enter your email address to subscribe to an email alert.</p>
-
-$errors
-
-<p>The simplest alert is our geographic one:</p>
-
+feed, or enter your email address to subscribe to an email alert.'), $input_h{pc}));
+ $out .= $errors;
+ $out .= $q->p(_('The simplest alert is our geographic one:'));
+ my $label = sprintf(_('Problems within %skm of this location'), $dist);
+ $out .= <<EOF;
<p id="rss_local">
<input type="radio" name="feed" id="local:$x:$y" value="local:$x:$y"$checked>
-<label for="local:$x:$y">Problems within ${dist}km of this location</label> (a default
-distance which covers roughly 200,000 people)
-<a href="/rss/$x,$y"><img src="/i/feed.png" width="16" height="16" title="RSS feed of nearby problems" alt="RSS feed" border="0"></a>
-</p>
-<p id="rss_local_alt">
-(alternatively the RSS feed can be customised, within <a href="/rss/$x,$y/2">2km</a> / <a href="/rss/$x,$y/5">5km</a>
+<label for="local:$x:$y">$label</label>
+EOF
+ $out .= _('(a default distance which covers roughly 200,000 people)');
+ $out .= " <a href='/rss/$x,$y'><img src='/i/feed.png' width='16' height='16' title='"
+ . _('RSS feed of nearby problems') . "' alt='" . _('RSS feed') . "' border='0'></a>";
+ $out .= '</p> <p id="rss_local_alt">' . _('(alternatively the RSS feed can be customised, within');
+ $out .= <<EOF;
+ <a href="/rss/$x,$y/2">2km</a> / <a href="/rss/$x,$y/5">5km</a>
/ <a href="/rss/$x,$y/10">10km</a> / <a href="/rss/$x,$y/20">20km</a>)
</p>
-
-<p>Or you can subscribe to an alert based upon what ward or council you&rsquo;re in:</p>
-
-$options
-
-<p><input type="submit" name="rss" value="Give me an RSS feed"></p>
-
-<p id="alert_or">or</p>
-
-<p>Your email: <input type="text" id="email" name="email" value="$input_h{email}" size="30"></p>
-<p><input type="submit" name="alert" value="Subscribe me to an email alert"></p>
-
-</div>
-</form>
EOF
+ $out .= $q->p(_('Or you can subscribe to an alert based upon what ward or council you&rsquo;re in:'));
+ $out .= $options;
+ $out .= $q->p('<input type="submit" name="rss" value="' . _('Give me an RSS feed') . '">');
+ $out .= $q->p({-id=>'alert_or'}, _('or'));
+ $out .= '<p>' . _('Your email:') . ' <input type="text" id="email" name="email" value="' . $input_h{email} . '" size="30"></p>
+<p><input type="submit" name="alert" value="' . _('Subscribe me to an email alert') . '"></p>
+</div>
+</form>';
+ return $out;
}
sub alert_list_options {
@@ -216,7 +212,7 @@ sub alert_list_options {
. '</label> <a href="/rss/';
$out .= $type eq 'area' ? 'area' : 'reports';
$out .= '/' . $rss . '"><img src="/i/feed.png" width="16" height="16"
-title="RSS feed of local problems at ' . $text . '" alt="RSS feed" border="0"></a>';
+title="' . sprintf(_('RSS feed of local problems at %s'), $text) . '" alt="' . _('RSS feed') . '" border="0"></a>';
}
return $out;
}
@@ -228,32 +224,27 @@ sub alert_front_page {
$errors = '<ul id="error"><li>' . $error . '</li></ul>' if $error;
my %input_h = map { $_ => $q->param($_) ? ent($q->param($_)) : '' } qw(pc);
- my $out = <<EOF;
-<h1>Local RSS feeds and email alerts</h1>
-<p>FixMyStreet has a variety of RSS feeds and email alerts for local problems, including
+ my $out = $q->h1(_('Local RSS feeds and email alerts'));
+ $out .= $q->p(_('FixMyStreet has a variety of RSS feeds and email alerts for local problems, including
alerts for all problems within a particular ward or council, or all problems
-within a certain distance of a particular location.</p>
-
-$errors
-<form method="get" action="/alert">
-<p>To find out what local alerts we have for you, please enter your UK
-postcode or street name and area:
-<input type="text" name="pc" value="$input_h{pc}">
-<input type="submit" value="Look up">
-</form>
-EOF
+within a certain distance of a particular location.'));
+ $out .= $errors . '<form method="get" action="/alert">';
+ $out .= $q->p(_('To find out what local alerts we have for you, please enter your UK
+postcode or street name and area:'), '<input type="text" name="pc" value="' . $input_h{pc} . '">
+<input type="submit" value="Look up">');
+ $out .= '</form>';
return $out if $q->referer() && $q->referer() =~ /fixmystreet\.com/;
my $recent_photos = Page::recent_photos(10);
- $out .= "<div id='alert_recent'><h2>Some photos of recent reports</h2>$recent_photos</div>" if $recent_photos;
+ $out .= '<div id="alert_recent">' . $q->h2(_('Some photos of recent reports')) . $recent_photos . '</div>' if $recent_photos;
return $out;
}
sub alert_rss {
my $q = shift;
my $feed = $q->param('feed');
- return alert_list($q, 'Please select the feed you want') unless $feed;
+ return alert_list($q, _('Please select the feed you want')) unless $feed;
if ($feed =~ /^area:(?:\d+:)+(.*)$/) {
(my $id = $1) =~ tr{:_}{/+};
print $q->redirect('/rss/area/' . $id);
@@ -266,7 +257,7 @@ sub alert_rss {
print $q->redirect('/rss/' . $1 . ',' . $2);
return;
} else {
- return alert_list($q, 'Illegal feed selection');
+ return alert_list($q, _('Illegal feed selection'));
}
}
diff --git a/web/confirm.cgi b/web/confirm.cgi
index 6205d0605..39e91f5af 100755
--- a/web/confirm.cgi
+++ b/web/confirm.cgi
@@ -6,7 +6,7 @@
# Copyright (c) 2006 UK Citizens Online Democracy. All rights reserved.
# Email: matthew@mysociety.org. WWW: http://www.mysociety.org
#
-# $Id: confirm.cgi,v 1.38 2008-04-03 16:18:37 matthew Exp $
+# $Id: confirm.cgi,v 1.39 2008-05-13 16:00:14 matthew Exp $
use strict;
use Standard;
@@ -71,7 +71,7 @@ sub confirm_update {
where id=? and state='confirmed'", {}, $problem_id);
}
my $out = '';
- if ($creator_fixed > 0) {
+ if ($creator_fixed > 0 && $q->{site} ne 'emptyhomes') {
$out = ask_questionnaire($q->param('token'));
} else {
$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"));
@@ -93,7 +93,7 @@ sub confirm_problem {
(my $domain = $email) =~ s/^.*\@//;
if (dbh()->selectrow_array('select email from abuse where lower(email)=? or lower(email)=?', {}, lc($email), lc($domain))) {
dbh()->do("update problem set state='hidden', lastupdate=ms_current_timestamp() where id=?", {}, $id);
- return $q->p('Sorry, there has been an error confirming your problem.');
+ return $q->p(_('Sorry, there has been an error confirming your problem.'));
} else {
dbh()->do("update problem set state='confirmed', confirmed=ms_current_timestamp(), lastupdate=ms_current_timestamp()
where id=? and state='unconfirmed'", {}, $id);
diff --git a/web/contact.cgi b/web/contact.cgi
index 4979f7344..5c217c7e7 100755
--- a/web/contact.cgi
+++ b/web/contact.cgi
@@ -6,7 +6,7 @@
# Copyright (c) 2006 UK Citizens Online Democracy. All rights reserved.
# Email: matthew@mysociety.org. WWW: http://www.mysociety.org
#
-# $Id: contact.cgi,v 1.27 2008-01-30 18:27:48 matthew Exp $
+# $Id: contact.cgi,v 1.28 2008-05-13 16:00:14 matthew Exp $
use strict;
use Standard;
@@ -19,7 +19,7 @@ use mySociety::Random qw(random_bytes);
# Main code for index.cgi
sub main {
my $q = shift;
- print Page::header($q, title=>'Contact Us');
+ print Page::header($q, title=>_('Contact Us'));
my $out = '';
if ($q->param('submit_form')) {
$out = contact_submit($q);
@@ -36,15 +36,15 @@ sub contact_submit {
my @vars = qw(name em subject message id);
my %input = map { $_ => $q->param($_) || '' } @vars;
my @errors;
- push(@errors, 'Please give your name') unless $input{name} =~ /\S/;
+ push(@errors, _('Please give your name')) unless $input{name} =~ /\S/;
if ($input{em} !~ /\S/) {
- push(@errors, 'Please give your email');
+ push(@errors, _('Please give your email'));
} elsif (!mySociety::EmailUtil::is_valid_email($input{em})) {
- push(@errors, 'Please give a valid email address');
+ push(@errors, _('Please give a valid email address'));
}
- push(@errors, 'Please give a subject') unless $input{subject} =~ /\S/;
- push(@errors, 'Please write a message') unless $input{message} =~ /\S/;
- push(@errors, 'Illegal ID') if $input{id} && $input{id} !~ /^[1-9]\d*$/;
+ push(@errors, _('Please give a subject')) unless $input{subject} =~ /\S/;
+ push(@errors, _('Please write a message')) unless $input{message} =~ /\S/;
+ push(@errors, _('Illegal ID')) if $input{id} && $input{id} !~ /^[1-9]\d*$/;
return contact_page($q, @errors) if @errors;
(my $message = $input{message}) =~ s/\r\n/\n/g;
@@ -60,13 +60,13 @@ sub contact_submit {
my $email = mySociety::Email::construct_email({
_body_ => "$message\n\n$postfix",
From => [$input{em}, $input{name}],
- To => [[mySociety::Config::get('CONTACT_EMAIL'), 'FixMyStreet']],
+ To => [[mySociety::Config::get('CONTACT_EMAIL'), _('FixMyStreet')]],
Subject => 'FMS message: ' . $subject,
'Message-ID' => sprintf('<contact-%s-%s@mysociety.org>', time(), unpack('h*', random_bytes(5))),
});
my $result = mySociety::EmailUtil::send_email($email, $input{em}, mySociety::Config::get('CONTACT_EMAIL'));
if ($result == mySociety::EmailUtil::EMAIL_SUCCESS) {
- my $out = $q->p("Thanks for your feedback. We'll get back to you as soon as we can!");
+ my $out = $q->p(_("Thanks for your feedback. We'll get back to you as soon as we can!"));
$out .= CrossSell::display_advert($q, $input{em}, $input{name});
return $out;
} else {
@@ -80,7 +80,7 @@ sub contact_page {
my %input = map { $_ => $q->param($_) || '' } @vars;
my %input_h = map { $_ => $q->param($_) ? ent($q->param($_)) : '' } @vars;
- my $out = $q->h1('Contact the team');
+ my $out = $q->h1(_('Contact the team'));
if (@errors) {
$out .= '<ul id="error"><li>' . join('</li><li>', @errors) . '</li></ul>';
}
@@ -99,7 +99,7 @@ sub contact_page {
my $p = dbh()->selectrow_hashref(
'select title,detail,name,anonymous,extract(epoch from created) as created
from problem where id=?', {}, $id);
- $out .= $q->p('You are reporting the following problem report for being abusive, containing personal information, or similar:');
+ $out .= $q->p(_('You are reporting the following problem report for being abusive, containing personal information, or similar:'));
$out .= $q->blockquote(
$q->h2(ent($p->{title})),
$q->p($q->em(
@@ -111,26 +111,28 @@ sub contact_page {
);
$out .= '<input type="hidden" name="id" value="' . $id . '">';
} else {
- $out .= <<EOF;
-<p>Please do <strong>not</strong> report problems through this form; messages go to
+ $out .= $q->p(_('Please do <strong>not</strong> report problems through this form; messages go to
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>
-EOF
+please <a href="/">go to the front page</a> and follow the instructions.'));
+ $out .= $q->p(_("We'd love to hear what you think about this site. Just fill in the form:"));
}
+ my $label_name = _('Your name:');
+ my $label_email = _('Your&nbsp;email:');
+ my $label_subject = _('Subject:');
+ my $label_message = _('Message:');
+ my $label_submit = _('Post');
$out .= <<EOF;
<fieldset>
<input type="hidden" name="submit_form" value="1">
-<div><label for="form_name">Your name:</label>
+<div><label for="form_name">$label_name</label>
<input type="text" name="name" id="form_name" value="$input_h{name}" size="30"></div>
-<div><label for="form_email">Your&nbsp;email:</label>
+<div><label for="form_email">$label_email</label>
<input type="text" name="em" id="form_email" value="$input_h{em}" size="30"></div>
-<div><label for="form_subject">Subject:</label>
+<div><label for="form_subject">$label_subject</label>
<input type="text" name="subject" id="form_subject" value="$input_h{subject}" size="30"></div>
-<div><label for="form_message">Message:</label>
+<div><label for="form_message">$label_message</label>
<textarea name="message" id="form_message" rows="7" cols="60">$input_h{message}</textarea></div>
-<div class="checkbox"><input type="submit" value="Post"></div>
+<div class="checkbox"><input type="submit" value="$label_submit"></div>
</fieldset>
</form>
</div>
diff --git a/web/css/cache-eha2.css b/web/css/cache-eha2.css
new file mode 100644
index 000000000..2e98dc574
--- /dev/null
+++ b/web/css/cache-eha2.css
@@ -0,0 +1,493 @@
+body{
+ text-align:center;
+ background-color: #FFFFFF;
+}
+#header {
+text-align:left;
+ margin: 0px;
+ width: 760px;
+}
+#main {
+text-align:left;
+ margin: 0px;
+ width: 760px;
+}
+#footer {
+text-align:left;
+ width: 760px;
+ clear: both;
+ background-color: #80AE7D;
+ height: 110px;
+ margin-top: 5px;
+ margin-bottom: 5px;
+}
+#logo {
+ margin: 0px;
+ float: left;
+ width: 400px;
+}
+#search {
+ margin: 0px;
+ float: right;
+ width: 345px;
+ height: 70px;
+ background-color: #80AE7D;
+ padding-top: 10px;
+ padding-right: 15px;
+ padding-bottom: 10px;
+}
+#bottombox ul {
+ list-style-type: none;
+ padding: 0px;
+ margin: 0px;
+}
+#bottombox li {
+ width: 170px;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: small;
+ background-color: #B1BECF;
+ margin-bottom: 1px;
+}
+
+#smallnav {
+ width: 750px;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: small;
+ text-align: right;
+ font-weight: 400;
+ color: #354664;
+ padding-right: 10px;
+ padding-bottom: 10px;
+ padding-top: 10px;
+}
+#topbox ul {
+ list-style-type: none;
+ margin: 0px;
+ padding: 0px;
+}
+#topbox li {
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: small;
+ width: 170px;
+ background-color: #b1becf;
+ margin-bottom: 1px;
+}
+#topbox a {
+ text-decoration: none;
+ color: #30517A;
+ display: block;
+}
+#bottombox a:hover {
+ background-color: #FFFFFF;
+ width: 170px;
+}
+#topbox a:hover {
+ background-color: #FFFFFF;
+ width: 170px;
+}
+
+#bottombox a {
+ color: #30517A;
+ text-decoration: none;
+ display: block;
+}
+
+
+
+#left {
+ float: left;
+ width: 120px;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: small;
+ list-style: none;
+}
+#middle p {
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: small;
+ width: 420px;
+ color: #30517A;
+}
+#pressnav {
+ border-top-width: 1px;
+ border-right-width: 1px;
+ border-bottom-width: 1px;
+ border-left-width: 1px;
+ border-top-style: solid;
+ border-bottom-style: solid;
+ border-top-color: #CCCCCC;
+ border-right-color: #CCCCCC;
+ border-bottom-color: #CCCCCC;
+ border-left-color: #CCCCCC;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: small;
+ padding: 3px;
+}
+#pressreleases {
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: small;
+ color: #30517A;
+}
+#pressreleases p {
+ padding-bottom: 10px;
+ background-color: #EBEEF3;
+ padding-top: 10px;
+ border: 1px dashed #CCCCCC;
+}
+#bulletin p {
+ padding-bottom: 10px;
+ background-color: #EBEEF3;
+ padding-top: 10px;
+ border: 1px dashed #CCCCCC;
+}
+
+#events p {
+ border: 1px dashed #CCCCCC;
+ padding-top: 10px;
+ padding-bottom: 10px;
+ background-color: #EBEEF3;
+}
+
+
+
+
+
+#right {
+ width: 160px;
+ float: right;
+}
+#left ul {
+ list-style-type: none;
+ padding: 0px;
+ margin: 0px;
+}
+#left ol {
+ list-style-type: none;
+ display: inline;
+ background-color: #B1BECF;
+ width: 90px;
+ margin-bottom: 1px;
+}
+#left ol a {
+ background-color: #DCDCED;
+ color: #30517A;
+}
+#left ol a:hover {
+ background-color: #FFFFFF;
+}
+
+
+#left li {
+ margin-bottom: 1px;
+ display: block;
+}
+#smallnav a {
+ text-decoration: none;
+ color: #30517A;
+}
+#smallnav a:hover {
+ background-color: #B1BECF;
+}
+
+#left a {
+ display: block;
+ width: 120px;
+ font-weight: bold;
+ padding: 10px;
+ text-decoration: none;
+ background-color: #9999CC;
+ color: #FFFFFF;
+}
+#address2 a {
+ color: #FFFFFF;
+}
+#address1 a {
+ color: #FFFFFF;
+}
+
+
+#left a:hover {
+ color: #30517A;
+ background-color: #FFFFFF;
+}
+
+
+
+#middle {
+ margin: 0 250px 0 155px:
+ clear: right;
+ width: 410px;
+ float: left;
+ left: 153px;
+ margin: 0px;
+ padding-right: 10px;
+ padding-bottom: 10px;
+ padding-left: 10px;
+ top: 135px;
+ background-color: #FFFFFF;
+}
+#address1 {
+ float: left;
+ width: 180px;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: x-small;
+ margin-bottom: 20px;
+ padding: 20px;
+ color: #FFFFFF;
+}
+#address2 {
+ float: left;
+ width: 180px;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: x-small;
+ margin-bottom: 20px;
+ padding: 20px;
+ color: #FFFFFF;
+}
+#toptitle {
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-weight: bold;
+ color: #FFFFFF;
+ font-size: small;
+ width: 160px;
+ background-color: #30517A;
+ padding: 5px;
+}
+#bottomtitle {
+ width: 160px;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: small;
+ font-weight: bold;
+ background-color: #30517A;
+ color: #FFFFFF;
+ padding: 5px;
+}
+#middle h1 {
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: large;
+ width: 420px;
+ background-color: #9999CC;
+ color: #FFFFFF;
+ padding: 3px;
+ font-weight: 500;
+}
+#middle h2 {
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: small;
+ font-weight: bold;
+ background-color: #B1BECF;
+ display: block;
+ color: #30517A;
+}
+#middle h3 {
+ text-decoration: underline;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: small;
+ font-weight: bold;
+ color: #30517A;
+}
+
+#middle a:hover {
+ background-color: #B1BECF;
+}
+#middle a {
+ color: #30517A;
+ text-decoration: underline;
+}
+#eventsnav {
+ border-top-width: 1px;
+ border-bottom-width: 1px;
+ border-top-style: solid;
+ border-bottom-style: solid;
+ border-top-color: #CCCCCC;
+ border-bottom-color: #CCCCCC;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: small;
+ padding: 3px;
+ text-align: center;
+}
+#lwoanav {
+ padding-top: 5px;
+ padding-bottom: 5px;
+ border-top-width: 1px;
+ border-bottom-width: 1px;
+ border-top-style: solid;
+ border-bottom-style: solid;
+ border-top-color: #CCCCCC;
+ border-bottom-color: #CCCCCC;
+ text-align: center;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: small;
+}
+#lwoa {
+ border: 1px dotted #CCCCCC;
+ width: 420px;
+}
+#nwoanav {
+ padding-top: 5px;
+ padding-bottom: 5px;
+ border-top-width: 1px;
+ border-bottom-width: 1px;
+ border-top-style: solid;
+ border-bottom-style: solid;
+ border-top-color: #CCCCCC;
+ border-bottom-color: #CCCCCC;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: small;
+ text-align: center;
+}
+#nwoa {
+ width: 420px;
+ border: 1px dotted #CCCCCC;
+}
+#pubsubleft {
+ float: left;
+ width: 200px;
+ border: 1px solid #CCCCCC;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ color: #30517a;
+ font-size: x-small;
+}
+#pubsubright {
+ float: right;
+ width: 200px;
+ border: 1px solid #CCCCCC;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: x-small;
+ color: #30517a;
+}
+#pubtypeleft {
+ float: left;
+ width: 200px;
+ border: 1px solid #CCCCCC;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: x-small;
+ color: #30517a;
+}
+#pubtyperight {
+ float: right;
+ width: 200px;
+ border: 1px solid #CCCCCC;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: x-small;
+ color: #30517a;
+}
+#periodnavleft {
+ margin: 0px;
+ float: left;
+ width: 200px;
+ border: 1px solid #CCCCCC;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: x-small;
+ color: #30517A;
+}
+#periodnavright {
+ margin: 0px;
+ float: right;
+ width: 200px;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: x-small;
+ color: #30517A;
+ border: 1px dashed #CCCCCC;
+}
+#policynav {
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: x-small;
+ color: #30517a;
+ margin: 0px;
+ float: left;
+ width: 400px;
+ border: 1px solid #CCCCCC;
+}
+#casenav {
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: x-small;
+ color: #30517a;
+}
+#case p {
+ padding-bottom: 10px;
+ background-color: #EBEEF3;
+ padding-top: 10px;
+ border: 1px dashed #CCCCCC;
+}
+#grants p {
+ padding-bottom: 10px;
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: small;
+ color: #30517a;
+ background-color: #EBEEF3;
+ padding-top: 10px;
+ border: 1px dashed #CCCCCC;
+}
+#listing {
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: x-small;
+ color: #30517a;
+}
+#suppliernav {
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: x-small;
+ margin: 0px;
+ width: 425px;
+ border: 1px solid #CCCCCC;
+ text-align: center;
+}
+#publist {
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: small;
+ margin: 0px;
+ width: 400px;
+}
+#publist p {
+ padding-bottom: 10px;
+ background-color: #EBEEF3;
+ padding-top: 10px;
+ border: 1px dashed #CCCCCC;
+}
+#contactnav {
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: x-small;
+ margin: 0px;
+ width: 425px;
+ border: 1px solid #CCCCCC;
+ text-align: center;
+}
+#statsnav {
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: small;
+ color: #30517a;
+ margin: 0px;
+ float: left;
+ width: 425px;
+}
+#buyingnav {
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: x-small;
+ color: #30517a;
+ margin: 0px;
+ float: left;
+ width: 400px;
+ border: 1px solid #CCCCCC;
+}
+#ownernav {
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: x-small;
+ color: #30517a;
+ margin: 0px;
+ float: left;
+ width: 400px;
+ border: 1px solid #CCCCCC;
+}
+#campnav {
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: x-small;
+ color: #30517a;
+ margin: 0px;
+ float: left;
+ width: 400px;
+ border: 1px solid #CCCCCC;
+}
+#sitenav {
+ font-family: Geneva, Arial, Helvetica, sans-serif;
+ font-size: x-small;
+ color: #30517a;
+}
diff --git a/web/index.cgi b/web/index.cgi
index 8e27bccd6..7596a9763 100755
--- a/web/index.cgi
+++ b/web/index.cgi
@@ -6,7 +6,7 @@
# Copyright (c) 2006 UK Citizens Online Democracy. All rights reserved.
# Email: matthew@mysociety.org. WWW: http://www.mysociety.org
#
-# $Id: index.cgi,v 1.192 2008-05-06 10:06:13 matthew Exp $
+# $Id: index.cgi,v 1.193 2008-05-13 16:00:14 matthew Exp $
use strict;
use Standard;
@@ -164,12 +164,12 @@ sub submit_update {
push @errors, $err if $err;
}
- push(@errors, 'Please enter a message') unless $input{update} =~ /\S/;
+ push(@errors, _('Please enter a message')) unless $input{update} =~ /\S/;
$input{name} = undef unless $input{name} =~ /\S/;
if ($input{email} !~ /\S/) {
- push(@errors, 'Please enter your email');
+ push(@errors, _('Please enter your email'));
} elsif (!mySociety::EmailUtil::is_valid_email($input{email})) {
- push(@errors, 'Please enter a valid email');
+ push(@errors, _('Please enter a valid email'));
}
my $image;