diff options
author | matthew <matthew> | 2007-06-26 14:46:37 +0000 |
---|---|---|
committer | matthew <matthew> | 2007-06-26 14:46:37 +0000 |
commit | d2477397bba15a2b8aa8632204a659eae77ca586 (patch) | |
tree | 24a68df4cd0ad6d4a8d8af3da937a639a23b7c7d | |
parent | 155911d119e385c00603cd1756c441fc565c666d (diff) |
Typo.
-rwxr-xr-x | web/index.cgi | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/web/index.cgi b/web/index.cgi index 68e9dbc39..8a5498da7 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.147 2007-06-26 14:32:42 matthew Exp $ +# $Id: index.cgi,v 1.148 2007-06-26 14:46:37 matthew Exp $ use strict; require 5.8.0; @@ -223,8 +223,11 @@ sub submit_problem { push(@errors, 'No council selected') unless ($input{council} && $input{council} =~ /^(?:-1|[\d,]+(?:\|[\d,]+)?)$/); push(@errors, 'Please enter a subject') unless $input{title} =~ /\S/; push(@errors, 'Please enter some details') unless $input{detail} =~ /\S/; - push(@errors, 'Please enter your name') unless $input{name} =~ /\S/; - push(@errors, 'Please enter your full name - if you do not wish your name to be shown on the site, untick the box') if length($input{name}) < 5 || $input{name} !~ /\s/ || $input{name} =~ /\banon(ymous)?\b/i + if ($input{name} !~ /\S/) { + push @errors, 'Please enter your name'; + } elsif (length($input{name}) < 5 || $input{name} !~ /\s/ || $input{name} =~ /\ba\s*n+on+((y|o)mo?u?s)?(ly)?\b/i) { + push @errors, 'Please enter your full name, councils need this information - if you do not wish your name to be shown on the site, untick the box'; + } if ($input{email} !~ /\S/) { push(@errors, 'Please enter your email'); } elsif (!mySociety::Util::is_valid_email($input{email})) { |