# Mailto: problems

**URL:** <https://forum.kirupa.com/t/mailto-problems/184674>\
**Category:** Uncategorized\
**Created:** [April 6, 2006, 6:57pm UTC](https://forum.kirupa.com/t/mailto-problems/184674 "2006-04-06T18:57:11Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![poletnik](https://avatars.discourse-cdn.com/v4/letter/p/dc4da7/32.png) [@poletnik](https://forum.kirupa.com/u/poletnik)\
**Post date:** [April 6, 2006, 6:57pm UTC](https://forum.kirupa.com/t/mailto-problems/184674/1 "2006-04-06T18:57:11Z")

</div>

I want to send some data from my text fields on my web page.

Everything works fine when I test this on my computer. Outlook opens new window and in body of email i get data arranged as I want with  
and .

But when I test this on web everything in body is displayed as one line… as there wansn’t  
& …

Is there some other way of arranging bits of data from text fields in email body?

10x for answers…

---

<div class="post-metadata">

**Author:** ![JoshuaJonah](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/joshuajonah/32/1775_2.png) [@JoshuaJonah](https://forum.kirupa.com/u/JoshuaJonah)\
**Post date:** [April 6, 2006, 7:13pm UTC](https://forum.kirupa.com/t/mailto-problems/184674/2 "2006-04-06T19:13:11Z")

</div>

post the code you are using.

---

<div class="post-metadata">

**Author:** ![poletnik](https://avatars.discourse-cdn.com/v4/letter/p/dc4da7/32.png) [@poletnik](https://forum.kirupa.com/u/poletnik)\
**Post date:** [April 6, 2006, 7:16pm UTC](https://forum.kirupa.com/t/mailto-problems/184674/3 "2006-04-06T19:16:43Z")

</div>

> [@Defective](#):
>
> post the code you are using.

subject = “Something…”;  
email = “[my\_mail@gmail.com](mailto:my_mail@gmail.com)”;  
mailto = “mailto:” add email;

on (press) {  
var strFullText = "Name Quantity Price  
";  
for (var index= 0; index \< shop\_cart.size(); index++)  
{  
strFullText += (shop\_cart.getElement(index)).getDesc()+ " "  
+ (shop\_cart.getElement(index)).getQuantity() + " "  
+ (shop\_cart.getElement(index)).getPrice() + "  
";  
}  
getURL(mailto add “&subject=” add subject add “&body=” add strFullText);  
}

---

<div class="post-metadata">

**Author:** ![poletnik](https://avatars.discourse-cdn.com/v4/letter/p/dc4da7/32.png) [@poletnik](https://forum.kirupa.com/u/poletnik)\
**Post date:** [April 6, 2006, 10:30pm UTC](https://forum.kirupa.com/t/mailto-problems/184674/4 "2006-04-06T22:30:13Z")

</div>

Does anyone hava any Idea of how can I fix this problem of mine?

---

<div class="post-metadata">

**Author:** ![B\_L\_U\_E](https://avatars.discourse-cdn.com/v4/letter/b/ba8739/32.png) [@B\_L\_U\_E](https://forum.kirupa.com/u/B_L_U_E)\
**Post date:** [April 6, 2006, 10:36pm UTC](https://forum.kirupa.com/t/mailto-problems/184674/5 "2006-04-06T22:36:11Z")

</div>

I cant believe its slipping my mind, but what is ? I know the solution for  
might be [COLOR=“Blue”]newline[/COLOR]: [AS]subject = “Something…”;  
email = "my\_mail@gmail.com";  
mailto = “mailto:” + email;

on (press) {  
var strFullText = “Name Quantity Price” + newline;  
for (var index= 0; index \< shop\_cart.size(); index++)  
{  
strFullText += (shop\_cart.getElement(index)).getDesc()+ " "

- (shop\_cart.getElement(index)).getQuantity() + " "
- (shop\_cart.getElement(index)).getPrice() + newline;  
}  
getURL(mailto + “&subject=” + subject + “&body=” + strFullText);  
}[/AS]

by the way, are you using a shopping cart you built in flash or bought?

---

<div class="post-metadata">

**Author:** ![poletnik](https://avatars.discourse-cdn.com/v4/letter/p/dc4da7/32.png) [@poletnik](https://forum.kirupa.com/u/poletnik)\
**Post date:** [April 6, 2006, 10:46pm UTC](https://forum.kirupa.com/t/mailto-problems/184674/6 "2006-04-06T22:46:29Z")

</div>

```
 is as same as tab or I don't know how to explain this in english... you know button over Caps Lock... 

```

And I tried newline but it’s the same as  
… no effect.

And I’m using mine custom made flash cart yes.

---

<div class="post-metadata">

**Author:** ![flextnet](https://avatars.discourse-cdn.com/v4/letter/f/7ba0ec/32.png) [@flextnet](https://forum.kirupa.com/u/flextnet)\
**Post date:** [April 6, 2006, 10:48pm UTC](https://forum.kirupa.com/t/mailto-problems/184674/7 "2006-04-06T22:48:44Z")

</div>

I think this is a tough one because different mail readers display text differently- some use  
(carriage return-linefeed) for newlines. Have you tried formatting the body text with html?

---

<div class="post-metadata">

**Author:** ![poletnik](https://avatars.discourse-cdn.com/v4/letter/p/dc4da7/32.png) [@poletnik](https://forum.kirupa.com/u/poletnik)\
**Post date:** [April 6, 2006, 11:01pm UTC](https://forum.kirupa.com/t/mailto-problems/184674/8 "2006-04-06T23:01:37Z")

</div>

What do you mean by formating text with html?

---

<div class="post-metadata">

**Author:** ![flextnet](https://avatars.discourse-cdn.com/v4/letter/f/7ba0ec/32.png) [@flextnet](https://forum.kirupa.com/u/flextnet)\
**Post date:** [April 6, 2006, 11:19pm UTC](https://forum.kirupa.com/t/mailto-problems/184674/9 "2006-04-06T23:19:37Z")

</div>

Well the mail reader might like it better if the body were something like:

\<html\>\<body\>Here’s the email body\<br\>etc.\</body\>\</html\>

Then again it might just display that literally.

---

<div class="post-metadata">

**Author:** ![poletnik](https://avatars.discourse-cdn.com/v4/letter/p/dc4da7/32.png) [@poletnik](https://forum.kirupa.com/u/poletnik)\
**Post date:** [April 6, 2006, 11:33pm UTC](https://forum.kirupa.com/t/mailto-problems/184674/10 "2006-04-06T23:33:25Z")

</div>

Ok, that’s one way… but where in my code can i put this? I don’t see the way to combine it…

---

<div class="post-metadata">

**Author:** ![flextnet](https://avatars.discourse-cdn.com/v4/letter/f/7ba0ec/32.png) [@flextnet](https://forum.kirupa.com/u/flextnet)\
**Post date:** [April 6, 2006, 11:39pm UTC](https://forum.kirupa.com/t/mailto-problems/184674/11 "2006-04-06T23:39:01Z")

</div>

> [@poletnik](#):
>
> Ok, that’s one way… but where in my code can i put this? I don’t see the way to combine it…

How about:

```auto
 subject = [COLOR=#ff0000]"Something..."[/COLOR];
email = [COLOR=#ff0000]"my_mail@gmail.com"[/COLOR];
mailto = [COLOR=#ff0000]"mailto:"[/COLOR] + email;
 
[COLOR=#0000ff]on[/COLOR] [COLOR=#000000]([/COLOR]press[COLOR=#000000])[/COLOR] [COLOR=#000000]{[/COLOR]
[COLOR=#000000] **var** [/COLOR] strFullText = [COLOR=#ff0000]"<html><body>Name Quantity Price<br><br>"[/COLOR];
[COLOR=#0000ff]for[/COLOR] [COLOR=#000000]([/COLOR][COLOR=#000000] **var** [/COLOR] [COLOR=#0000ff]index[/COLOR]= [COLOR=#000080]0[/COLOR]; [COLOR=#0000ff]index[/COLOR] < shop_cart.[COLOR=#0000ff]size[/COLOR][COLOR=#000000]([/COLOR][COLOR=#000000])[/COLOR]; [COLOR=#0000ff]index[/COLOR]++[COLOR=#000000])[/COLOR]
[COLOR=#000000]{[/COLOR]
strFullText += [COLOR=#000000]([/COLOR]shop_cart.[COLOR=#000080]getElement[/COLOR][COLOR=#000000]([/COLOR][COLOR=#0000ff]index[/COLOR][COLOR=#000000])[/COLOR][COLOR=#000000])[/COLOR].[COLOR=#000080]getDesc[/COLOR][COLOR=#000000]([/COLOR][COLOR=#000000])[/COLOR]+ [COLOR=#ff0000]""[/COLOR]
+ [COLOR=#000000]([/COLOR]shop_cart.[COLOR=#000080]getElement[/COLOR][COLOR=#000000]([/COLOR][COLOR=#0000ff]index[/COLOR][COLOR=#000000])[/COLOR][COLOR=#000000])[/COLOR].[COLOR=#000080]getQuantity[/COLOR][COLOR=#000000]([/COLOR][COLOR=#000000])[/COLOR] + [COLOR=#ff0000]""[/COLOR]
+ [COLOR=#000000]([/COLOR]shop_cart.[COLOR=#000080]getElement[/COLOR][COLOR=#000000]([/COLOR][COLOR=#0000ff]index[/COLOR][COLOR=#000000])[/COLOR][COLOR=#000000])[/COLOR].[COLOR=#000080]getPrice[/COLOR][COLOR=#000000]([/COLOR][COLOR=#000000])[/COLOR] + [COLOR=#0000ff]"<br>[/COLOR];
[COLOR=#000000]}[/COLOR]
strFullText += "</body></html>";
[COLOR=#0000ff]getURL[/COLOR][COLOR=#000000]([/COLOR]mailto + [COLOR=#ff0000]"&subject="[/COLOR] + subject + [COLOR=#ff0000]"&body="[/COLOR] + strFullText[COLOR=#000000])[/COLOR];
[COLOR=#000000]}[/COLOR]

```

I changed the to spaces but if you use html you could set up a table instead. Again, I don’t really know if this will work for you… :ponder:

---

<div class="post-metadata">

**Author:** ![poletnik](https://avatars.discourse-cdn.com/v4/letter/p/dc4da7/32.png) [@poletnik](https://forum.kirupa.com/u/poletnik)\
**Post date:** [April 6, 2006, 11:47pm UTC](https://forum.kirupa.com/t/mailto-problems/184674/12 "2006-04-06T23:47:01Z")

</div>

Nop… I tried with this changes but it just literally displays them in the body…

I’ll take a look at some flash forms which are using php and see if that helps something…

10x for all your answers…
