function writeEmail(inId)
{  
  var el = document.getElementById(inId);
  var mail = el.firstChild.getAttribute('href').split('_');
  var tagValue = el.firstChild.firstChild.nodeValue;
  el.innerHTML = '<a href="mailto:'+ mail[7] + '@' + mail[3] +'">'+ tagValue +'</a>';
}
