From: x2003bruneau Date: Sat, 26 May 2007 13:49:22 +0000 (+0000) Subject: Fix GoogleMaps links X-Git-Tag: xorg/0.9.15~277 X-Git-Url: http://git.polytechnique.org/?a=commitdiff_plain;h=92630203925015ac6f70faaf4aacd05d26e5924b;p=platal.git Fix GoogleMaps links ChangeLog | 1 + plugins/function.display_address.php | 10 ++++++++-- 2 files changed, 9 insertions(+), 2 deletions(-) git-svn-id: svn+ssh://murphy/home/svn/platal/trunk@1839 839d8a87-29fc-0310-9880-83ba4fa771e5 --- diff --git a/ChangeLog b/ChangeLog index a1413c9..38fba1a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -10,6 +10,7 @@ Bug/Wish: * Profile: - #663: Link to Xnet's map from the "My groups" page -FRU + - Fix GoogleMaps links -FRU From 0.9.14 branch: diff --git a/plugins/function.display_address.php b/plugins/function.display_address.php index 45cbb8e..fe5d355 100644 --- a/plugins/function.display_address.php +++ b/plugins/function.display_address.php @@ -20,7 +20,8 @@ ***************************************************************************/ -function smarty_function_display_address($param, &$smarty) { +function smarty_function_display_address($param, &$smarty) +{ require_once('geoloc.inc.php'); $txtad = get_address_text($param['adr']); if (!$txtad && @@ -30,8 +31,13 @@ function smarty_function_display_address($param, &$smarty) { !$param['adr']['mobile']) return ""; $lines = explode("\n", $txtad); + $idt = array_shift($lines); + $txthtml = ""; - $map = "\"Google"; + $map = "\"Google"; + array_unshift($lines, $idt); if ($param['titre']) { if ($param['titre_div'])