
interchange-cvs at icdevgroup
Apr 7, 2010, 1:40 PM
Post #1 of 1
(235 views)
Permalink
|
|
[interchange] Added path_only attribute to the [area] tag
|
|
commit 7aa66b0038137e9f578d5077a1e0ffea504321fb Author: Jon Jensen <jon [at] endpoint> Date: Wed Apr 7 14:39:15 2010 -0600 Added path_only attribute to the [area] tag This returns the URL without the leading protocol. Written by David Christensen <david [at] endpoint> on 2008-12-30. lib/Vend/Util.pm | 5 +++++ 1 files changed, 5 insertions(+), 0 deletions(-) --- diff --git a/lib/Vend/Util.pm b/lib/Vend/Util.pm index 646a119..ecbafba 100644 --- a/lib/Vend/Util.pm +++ b/lib/Vend/Util.pm @@ -1316,6 +1316,11 @@ sub vendUrl { $opt->{anchor} =~ s/^#//; $r .= '#' . $opt->{anchor}; } + + # return full-path portion of the URL + if ($opt->{path_only}) { + $r =~ s!^https?://[^/]*!!i; + } return $r; } _______________________________________________ interchange-cvs mailing list interchange-cvs [at] icdevgroup http://www.icdevgroup.org/mailman/listinfo/interchange-cvs
|