diff options
author | louise <louise> | 2009-09-23 15:43:54 +0000 |
---|---|---|
committer | louise <louise> | 2009-09-23 15:43:54 +0000 |
commit | a6e0574642c9b6aa0f4d3c43bba1f12b56bfdfa5 (patch) | |
tree | 032ff18eb49bd79884d559908d477726647bf545 /perllib/Cobrand.pm | |
parent | 1ed78ecb294d558b91739170c8e78bd3db8360ba (diff) |
Ugly way of allowing the AJAX paths to change depending on what root path the pages are being served from
Diffstat (limited to 'perllib/Cobrand.pm')
-rw-r--r-- | perllib/Cobrand.pm | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/perllib/Cobrand.pm b/perllib/Cobrand.pm index 0030c2ccf..e170ec87d 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.20 2009-09-23 11:31:31 louise Exp $ +# $Id: Cobrand.pm,v 1.21 2009-09-23 15:43:54 louise Exp $ package Cobrand; use strict; @@ -369,16 +369,16 @@ sub header_params { =cut -sub root_path_pattern { +sub root_path_js { my ($cobrand) = @_; my $handle; if ($cobrand){ $handle = cobrand_handle($cobrand); } - if ( !$cobrand || !$handle || !$handle->can('root_path_pattern')){ - return '//g'; + if ( !$cobrand || !$handle || !$handle->can('root_path_js')){ + return 'var root_path = "";'; } else{ - return $handle->root_path_pattern(); + return $handle->root_path_js(); } } |