aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorlouise <louise>2009-11-25 18:27:25 +0000
committerlouise <louise>2009-11-25 18:27:25 +0000
commit2b4b5cc079d219abc39ca3d2778623b1dafe8cbb (patch)
tree26bc3aad6e784e975ec275787184f4a3f80390b8
parent052095d7d73e511ff4c6844eda8eac72c779feaf (diff)
Allow rewriting of WTT url where referenced
-rw-r--r--perllib/Cobrand.pm21
1 files changed, 20 insertions, 1 deletions
diff --git a/perllib/Cobrand.pm b/perllib/Cobrand.pm
index 073b18ded..9e6310ea8 100644
--- a/perllib/Cobrand.pm
+++ b/perllib/Cobrand.pm
@@ -7,7 +7,7 @@
# Copyright (c) 2009 UK Citizens Online Democracy. All rights reserved.
# Email: louise@mysociety.org. WWW: http://www.mysociety.org
#
-# $Id: Cobrand.pm,v 1.45 2009-11-24 16:04:22 louise Exp $
+# $Id: Cobrand.pm,v 1.46 2009-11-25 18:27:25 louise Exp $
package Cobrand;
use strict;
@@ -148,6 +148,25 @@ sub admin_base_url {
}
+=item writetothem_url COBRAND COBRAND_DATA
+
+URL for writetothem
+
+=cut
+sub writetothem_url {
+ my ($cobrand, $cobrand_data) = @_;
+ my $handle;
+ if ($cobrand){
+ $handle = cobrand_handle($cobrand);
+ }
+ if ( !$cobrand || !$handle || ! $handle->can('writetothem_url')){
+ return 0;
+ }{
+ return $handle->writetothem_url($cobrand_data);
+ }
+
+}
+
=item email_host COBRAND
Return the virtual host that sends email for this cobrand