[freeside-commits] branch FREESIDE_2_3_BRANCH updated. 340c25ab6d097a96cf6a6e5bfbfca2656d0d016a
Ivan
ivan at 420.am
Thu Jul 5 16:29:50 PDT 2012
The branch, FREESIDE_2_3_BRANCH has been updated
via 340c25ab6d097a96cf6a6e5bfbfca2656d0d016a (commit)
from 17093ed856d01f930b32a709b225c568692fec23 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 340c25ab6d097a96cf6a6e5bfbfca2656d0d016a
Author: Ivan Kohler <ivan at freeside.biz>
Date: Thu Jul 5 16:29:49 2012 -0700
fix escaping in coordinate links
diff --git a/httemplate/elements/coord-links.html b/httemplate/elements/coord-links.html
index 60882de..02a224a 100644
--- a/httemplate/elements/coord-links.html
+++ b/httemplate/elements/coord-links.html
@@ -3,7 +3,7 @@
<& /elements/popup_link.html,
'action' => $p. 'view/map.html?'. $query,
'label' => mt('map'),
- 'actionlabel' => uri_escape_utf8($name),
+ 'actionlabel' => $js_name,
'width' => 763,
'height' => 575,
#'color'
@@ -13,7 +13,7 @@
<& /elements/popup_link.html,
'action' => $p. "view/directions.html?origin=$origin;". $query,
'label' => mt('directions'),
- 'actionlabel' => uri_escape_utf8($name),
+ 'actionlabel' => $js_name,
'width' => 763,
'height' => 575,
&>
@@ -29,6 +29,12 @@ my $query = 'name='. uri_escape_utf8($name).
';lat='. $latitude.
';lon='. $longitude;
+my $js_name = $name;
+$js_name =~ s/[<>"]/ /g;
+$m->interp->apply_escapes($js_name, 'js_string');
+$js_name =~ s/^'//;
+$js_name =~ s/'$//;
+
my $origin;
#for directions link
if ( $agentnum =~ /^\d+$/ ) {
-----------------------------------------------------------------------
Summary of changes:
httemplate/elements/coord-links.html | 10 ++++++++--
1 files changed, 8 insertions(+), 2 deletions(-)
More information about the freeside-commits
mailing list