function URLencode(sStr)
{
 return escape(sStr).replace(/\+/g, '%2C').replace(/\"/g,'%22').replace(/\'/g, '%27');
}

function EmailPageURL( p_subject )
{

   var v_url;
   var v_string;
   var v_enllac;
   if (p_subject == null)
   {
      p_subject = document.title;
   }

   v_string = "Departament d'Educació%0A%0A";
   v_enllac = window.location;
   window.location = "mailto:?subject="+ p_subject + "&body="+ v_string + v_enllac;

 }

