0

I have this code and wondering why this doesn't work. \n or br tag doesn't make a new line.

Here is my code.

let mailTo = 'user@example.com';
let subject = 'Testing title';
let body = '';
body += 'Checking if slash n would work \n\n'
    +'Checking if br would work <br /><br />'
    +'Final Result';


window.location.href = 'mailto:'+mailTo+'?subject='+subject+'&body='+body;

0 Answers0