From: Christian Weiske Date: Thu, 3 Oct 2013 18:12:56 +0000 (+0200) Subject: support multiple URLs X-Git-Tag: 0.8.0~4^2~3 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=8cd94400f4cf4cab25b33da2015a4d89bd9c70bd;p=contagged support multiple URLs --- diff --git a/inc/fields.php b/inc/fields.php index 25e0508..0c236be 100644 --- a/inc/fields.php +++ b/inc/fields.php @@ -38,7 +38,7 @@ $FIELDS = array( 'homephone' => 'homePhone', 'homestreet' => 'homePostalAddress', 'photo' => 'jpegPhoto', - 'url' => 'labeledURI', + '_url' => 'labeledURI', 'note' => 'description', 'manager' => 'manager', // aka. key account '_mail' => 'mail', diff --git a/templates/entry_edit.tpl b/templates/entry_edit.tpl index ddad5dc..b8f3ff8 100644 --- a/templates/entry_edit.tpl +++ b/templates/entry_edit.tpl @@ -216,13 +216,20 @@

{$lang.communication}

-{if $fields.url} +{if $fields._url} + {foreach from=$entry.url|smarty:nodefaults item=url} - {$lang.url}: - + {$lang.url} {counter}: + + + {/foreach} + + {$lang.url} {counter}: + {/if} {if $fields._mail} + {counter start=0} {foreach from=$entry.mail|smarty:nodefaults item=mail} {$lang.mail} {counter}: diff --git a/templates/entry_show.tpl b/templates/entry_show.tpl index b10b45f..4960893 100644 --- a/templates/entry_show.tpl +++ b/templates/entry_show.tpl @@ -141,7 +141,11 @@ {if $entry.url} {$lang.url}: - {$entry.url|http} + + {foreach from=$entry.url item=url} + {$url|http}
+ {/foreach} + {/if} {if $entry.mail}