From 412f9e9363e340613a35762dfff2b10bd61bf7ad Mon Sep 17 00:00:00 2001 From: Florian Zeitz Date: Thu, 27 Aug 2009 00:17:10 +0200 Subject: [PATCH] Handle multiple e-mail addrs. and telephnone nrs. --- scripts/basic.js | 4 ++++ vCard.html | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/scripts/basic.js b/scripts/basic.js index fbb8d85..292f666 100644 --- a/scripts/basic.js +++ b/scripts/basic.js @@ -49,15 +49,19 @@ function populateVCard(e, jid) { $("#PHOTO img").attr('src', 'data:'+mime+';base64,'+binval); } $(e).find('TEL:has(HOME)').each(function() { + $('#TELHOME').append(' '); $('#TELHOME').append(Strophe.xmlTextNode($(this).find('NUMBER').text())); }); $(e).find('TEL:has(WORK)').each(function() { + $('#TELWORK').append(' '); $('#TELWORK').append(Strophe.xmlTextNode($(this).find('NUMBER').text())); }); $(e).find('EMAIL:has(HOME)').each(function() { + $('#EMAILHOME').append(' '); $('#EMAILHOME').append(Strophe.xmlTextNode($(this).find('USERID').text())); }); $(e).find('EMAIL:has(WORK)').each(function() { + $('#EMAILWORK').append(' '); $('#EMAILWORK').append(Strophe.xmlTextNode($(this).find('USERID').text())); }); diff --git a/vCard.html b/vCard.html index 1769db4..cd173ed 100644 --- a/vCard.html +++ b/vCard.html @@ -15,8 +15,8 @@
  • Birthday:
  • Telephone (Home):
  • Telephone (Work):
  • -
  • E-Mail (Home):
  • -
  • E-Mail (Work):
  • +
  • E-Mail (Home):
  • +
  • E-Mail (Work):
  • Country:
  • E-Mail:
  • -- 2.39.5