Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 8 of 8 total
Thread using mailto with an attachment
Mon, Mar 14 2016 6:29 AMPermanent Link

kamran

Hi

I wish to use mailto using the "EWB TLink" component to send an email.

eg. MyTLink.URL:=
'mailto:myemail@mydomain.com?subject=mysubject&body=mybody&attachment=xxxxxxxxxxxxxx'

the attachment path and file name seems to be the problem !

how is this constructed for it to work?

Assuming that the file is created on the web server
It should pick the file from the web server.

Is that possible ? Or is it just a local file thing ?, can you do both ?

thanks

Kamran
Mon, Mar 14 2016 8:28 AMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Kamran,

<< how is this constructed for it to work? >>

You can't send a file with an attachment like that.  It may work with certain mail clients, but I don't think it's a standard thing and probably isn't something that is allowed in all cases anyways due to stricter security standards.

Tim Young
Elevate Software
www.elevatesoft.com
Mon, Mar 14 2016 9:22 AMPermanent Link

Huseyin Aliz

myBiss ApS

Avatar

Hi Tim,

Can you please share some code to send mails from a module (server)?

Thanks Smile

Regards,

Hüseyin

Den 14-03-2016 kl. 13:28 skrev Tim Young [Elevate Software]:
> Kamran,
>
> << how is this constructed for it to work? >>
>
> You can't send a file with an attachment like that.  It may work with certain mail clients, but I don't think it's a standard thing and probably isn't something that is allowed in all cases anyways due to stricter security standards.
>
> Tim Young
> Elevate Software
> www.elevatesoft.com
>
Mon, Mar 14 2016 9:26 AMPermanent Link

Matthew Jones

Hüseyin Aliz wrote:

> Can you please share some code to send mails from a module (server)?

That's beyond Tim's scope I would say. It depends a lot on what you
really want with email, things like retry, multiple destinations, copy
to admin. Perhaps the best I would expect would be a way to write the
destination address to the first line of a text file, and the body
following it, to a place on disk. Then anyone can have whatever they
want pick that message up and process it according to needs. (For my
server, not using the EWB service, I have a thread that tries to send
messages from a database, using the Clever Components email sending,
but retries etc are important).

--

Matthew Jones
Tue, Mar 15 2016 8:22 AMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Huseyin,

<< Can you please share some code to send mails from a module (server)? >>

If you're using the EWB Web Server, then you can use any Delphi code available for sending emails in a web server module, such as this:

http://delphi.about.com/od/indy/a/email-send-indy.htm

Tim Young
Elevate Software
www.elevatesoft.com
Tue, Mar 15 2016 10:12 AMPermanent Link

Huseyin Aliz

myBiss ApS

Avatar

Tim,

I am using EWB Web Server, so i will try to see if I can use given link.

Thanks.

Regards,
Hüseyin

On 15-03-2016 13:22, Tim Young [Elevate Software] wrote:
> Huseyin,
>
> << Can you please share some code to send mails from a module (server)? >>
>
> If you're using the EWB Web Server, then you can use any Delphi code available for sending emails in a web server module, such as this:
>
> http://delphi.about.com/od/indy/a/email-send-indy.htm
>
> Tim Young
> Elevate Software
> www.elevatesoft.com
>
Wed, Mar 16 2016 7:53 AMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Huseyin,

<< I am using EWB Web Server, so i will try to see if I can use given link. >>

As long as you strip out the visual stuff, you should be able to use that Indy code verbatim (minus any changes to Indy that may have occurred between when the article was written and now).

Tim Young
Elevate Software
www.elevatesoft.com
Wed, Mar 16 2016 8:35 AMPermanent Link

Huseyin Aliz

myBiss ApS

Avatar

Tim,

Thanks Smile

Regards,

Hüseyin


Den 16-03-2016 kl. 12:53 skrev Tim Young [Elevate Software]:
> Huseyin,
>
> << I am using EWB Web Server, so i will try to see if I can use given link. >>
>
> As long as you strip out the visual stuff, you should be able to use that Indy code verbatim (minus any changes to Indy that may have occurred between when the article was written and now).
>
> Tim Young
> Elevate Software
> www.elevatesoft.com
>
Image