aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--perllib/Cobrand.pm21
-rw-r--r--perllib/Cobrands/Emptyhomes/Util.pm12
2 files changed, 31 insertions, 2 deletions
diff --git a/perllib/Cobrand.pm b/perllib/Cobrand.pm
index 528a338da..94570142d 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.30 2009-10-20 11:55:50 louise Exp $
+# $Id: Cobrand.pm,v 1.31 2009-10-20 14:24:59 louise Exp $
package Cobrand;
use strict;
@@ -527,6 +527,25 @@ sub council_check {
}
}
+=item feed_xsl
+
+Return an XSL to be used in rendering feeds
+
+=cut
+sub feed_xsl {
+ my ($cobrand) = @_;
+ my $handle;
+ if ($cobrand){
+ $handle = cobrand_handle($cobrand);
+ }
+ if ( !$cobrand || !$handle || !$handle->can('feed_xsl')){
+ return '/xsl.xsl';
+ } else{
+ return $handle->feed_xsl();
+ }
+
+}
+
1;
diff --git a/perllib/Cobrands/Emptyhomes/Util.pm b/perllib/Cobrands/Emptyhomes/Util.pm
index 3c02f08f3..6f0708c81 100644
--- a/perllib/Cobrands/Emptyhomes/Util.pm
+++ b/perllib/Cobrands/Emptyhomes/Util.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: Util.pm,v 1.5 2009-09-23 17:01:00 louise Exp $
+# $Id: Util.pm,v 1.6 2009-10-20 14:24:59 louise Exp $
package Cobrands::Emptyhomes::Util;
use Standard;
@@ -95,5 +95,15 @@ sub site_title {
return _('Report Empty Homes');
}
+=item feed_xsl
+
+Return the XSL file path to be used for feeds'
+
+=cut
+sub feed_xsl {
+ my ($self) = @_;
+ return '/xsl.eha.xsl';
+}
+
1;