Page 1 of 3

smtp

Posted: Thu Sep 17, 2020 5:42 pm
by Zazi
Hi guys,
Is there a way to use the tsNetPost function without having the bussiness edition or any other paid version?
Thank you

Re: smtp

Posted: Thu Sep 17, 2020 6:04 pm
by Klaus
Hi Zazi,

since tsNet only comes with LC Indy and Business, the answer will be no.


Best

Klaus

Re: smtp

Posted: Thu Sep 17, 2020 6:15 pm
by Zazi
there way to do it without tsNet?

Re: smtp

Posted: Thu Sep 17, 2020 6:59 pm
by ghettocottage
What is it you are trying to do? There is (almost) always several ways to do a thing.

Re: smtp

Posted: Thu Sep 17, 2020 7:37 pm
by Zazi
This is what i need to Someone is using my apps and want to tell me about bug so he need to send me email but I want it to be inside my app I think I found way but I mess with the code.

Re: smtp

Posted: Thu Sep 17, 2020 10:10 pm
by ghettocottage
Do you have a server that you are sending the messages to, that then get emailed?

If so, does your server have livecode-server installed along with Apache? Or perhaps just php?

you could just send a POST with the message to your server and from there you can email it or log it in a database. From a button on the app you might do something like this:

Code: Select all


on mouseUp
   
   put "https://yourserveraddress.com" into tServer
   put field device into tDevice
   put field message into tData
   
   put  "id=" & tDevice & "&data=" & tData into tStuffToPost
      
   --post it to the server
   post tStuffToPost to URL tServer

   --get the response if you need it
   put it into tResponse
   put tResponse into field response

end mouseUp


and then on your server you can have your lc script that receives the post and does whatever you want with it, like this:


[code]
      	  put  $_POST["id"] into tDevice
      	  put  $_POST["data"] into tData
     
         //do whatever you need to with that information






[/code]

Re: smtp

Posted: Thu Sep 17, 2020 10:12 pm
by Zazi
I use Gmail to be the server

Re: smtp

Posted: Fri Sep 18, 2020 8:59 am
by Klaus
Hi zazi,

please only ONE thread per topic!
I deleted the other thread: "Sending email using tsNet external"


Best

Klaus

Re: smtp

Posted: Fri Sep 18, 2020 9:58 am
by Zazi
sorry can u answer my question?

Re: smtp

Posted: Fri Sep 18, 2020 10:03 am
by Klaus
No, sorry, I don't know.

Re: smtp

Posted: Fri Sep 18, 2020 3:12 pm
by Zazi
Like nothing ?
I found something but the code is to messy u can check it for me?
Sending Emails From LiveCode Server Scripts | How To - LiveCode Ser... this is the Instructions

Re: smtp

Posted: Fri Sep 18, 2020 6:30 pm
by Klaus
Zazi wrote:
Fri Sep 18, 2020 3:12 pm
Sending Emails From LiveCode Server Scripts | How To - LiveCode Ser... this is the Instructions
This a script that will only work on a SERVER that has "Livecode Server" installed as the CGI engine.
Do you have access to a server with LC server software installed?
Zazi wrote:
Fri Sep 18, 2020 3:12 pm
I found something but the code is too messy...
The code is definitively not messy, but may be a bit too much for a new user.
Zazi wrote:
Fri Sep 18, 2020 3:12 pm
u can check it for me?
Do you mean I should create a script for you?
Come on, this is not how this forum is supposed to work, Zazi! 8)

Re: smtp

Posted: Fri Sep 18, 2020 6:34 pm
by Zazi
I am not new user :(
I use gamil server how I can do it?
I couldn't make it with the code the tsnet code was way more simple I understand all of it. What I need to do so the code to work.

Re: smtp

Posted: Fri Sep 18, 2020 7:07 pm
by Klaus
Zazi wrote:
Fri Sep 18, 2020 6:34 pm
I am not new user :(
Sorry, I presumed this because you found the code "too messy".
Zazi wrote:
Fri Sep 18, 2020 6:34 pm
I use gamil server how I can do it?
That script requires that "Livecode Server"* is installed on the server and I highly doubt this is the case with the GMAIL servers!
* This a CGI engine on the server like PHP, ASP etc.
Zazi wrote:
Fri Sep 18, 2020 6:34 pm
I couldn't make it with the code the tsnet code was way more simple I understand all of it. What I need to do so the code to work.
If you are using the Community version of LC than you cannot make THAT code (tsNet) work at all.
I don't know of any library for SMTP that will work with the Community version.

Re: smtp

Posted: Fri Sep 18, 2020 7:16 pm
by Zazi
So I can't make smtp with community at all?
And if I can I didn't get the live code server u can teach me master? 8)