Generating mailto: string - in Chrome I get new lines and formatting, in encapsulated Windows app I get a continuous text string

2 replies [Last post]
Offline
 Green Belt
Joined: Jan 29 2012
Points: 115
5
Average: 5 (1 vote)

In my HTML5 + Javascript app I'm generating a mailto: string for window.open to create an email.

var email_text = "I have a new question about SAS code for this ebook." +
" I have included my question here:\n ----------\n\n\n\n\n\n ----------\n";
var email_subject = this.ebook_title + " (new question)";
window.open("mailto:name@email.com?subject=" +
escape(email_subject) +
"&body=" +
escape(email_text));

In Chrome I get the following (which is what I'd like to see!):

I have a new question for this ebook. I have included my question here:
----------

----------

In the encapsulated Windows app I get the following:

I have a new question for this ebook. I have included my question here: ---------- ----------

What do I need to put into the mailto: string to produce new lines?

I've tried using \r\n, %0D%0A, %0A and , but none of these work.

............Phil

Offline
 Green Belt
Joined: Jan 29 2012
Points: 115

If this is different for the MeeGo app (and I'm downloading Meego 1.2 now to test this out) then what is the point of generating Windows and MeeGo apps together?

..........Phil

PS. See the discussion on generating Windows and MeeGo apps together at http://appdeveloper.intel.com/en-us/forums/can-you-allow-option-not-create-meego-files

Offline
 Green Belt
Joined: Jan 29 2012
Points: 115

For the record I've successfully published this web app through the Chrome Web Store instead of Intel AppUp, because I'm not satisfied with the impact on my generated emails of the encapsulation process. However, I'm intending to maintain my membership of this developer program (at least to the end of my free year) to see if the beta version is sufficiently improved.

................Phil

PS. I sold 2 copies of my new Chrome apps in the first 24 hours they were available!