Skip to Content
0
Former Member
Jul 24, 2016 at 01:24 PM

Appeon / PB12.5 / Roland's Email Code / Firewall?

156 Views

Greetings All,

I have an Appeon Web Application that sends emails using Roland's code.

I am deploying to server mobile.ftl.com.

When I run the application using http://mobile.ftl.com/affiliate_portal the application sends the email without a problem.

But when I run the application using http://ap.flightviewlimo.com/affiliate_portal the return code from lb_Return = gn_smtp.of_SendMail(). The text of the error is "An unknown error as occurred."

Chris Pollach has suggested in the past to simply create a web service to handle this. And I might have to now, but I was hoping there is something simple to change to make it work.

I 'thought' this code would be running on the server so there would be no need to authenticate if that is the issue.

I have edited my SMTP Server settings on webapp3.ftl.com to allow for traffic from mobile.ftl.com using its IP address.

Any pointers would be greatly appreciated!!

Thank you!!

Paul

string return_code

message_prefix = "Affiliate " + sp_id + " has made a request to override the original quoted amount for this trip. They would like to close this trip with details as shown in the bottom of this email." + &

'~r~n' + 'Affiliate Job ID: ' + affiliate_job_id + &

'~r~n' + 'Override Requested By: ' + userid + &

'~r~n' + &

'~r~n' + 'To APPROVE the Override Request, click on the link below' + &

'~r~n' + &

'~r~n' + 'http://mobile.ftl.com/trip_closeout_override/default.aspx?PBCommandParm=' + confo + '%20' + 'approved' + &

'~r~n' + &

'~r~n' + 'To DECLINE the Override Request, click on the link below' + &

'~r~n' + &

'~r~n' + 'http://mobile.ftl.com/trip_closeout_override/default.aspx?PBCommandParm=' + confo + '%20' + 'declined' + &

'~r~n' + &

'~r~n' + 'The following is the users reason for requesting the override:' + &

'~r~n' + &

'~r~n' + ''

String ls_body, ls_server, ls_uid, ls_pwd

String ls_filename, ls_port, ls_encrypt, ls_errormsg

Integer li_idx, li_max

Boolean lb_html, lb_Return

UInt lui_port

string subject

subject = "Request To Override Affiliate Charges: Confo: " + confo

ls_server = 'webapp3.ftl.com'

lb_html = False

string m_message

m_message = message_prefix + reason_text + notepad_entry

lui_port = 25

gn_smtp.of_SetPort(lui_port)

gn_smtp.of_SetServer(ls_server)

gn_smtp.of_SetLogFile(false, "")

gn_smtp.of_SetDebugViewer(false)

gn_smtp.of_SetSubject(subject)

gn_smtp.of_SetBody(m_message, lb_html)

gn_smtp.of_SetFrom(userid, sp_id)

gn_smtp.of_AddAddress("billing@flightviewlimo.com", "Billing")

gn_smtp.of_AddAddress("paulm@flightviewlimo.com", "IT") //uncommented on 7/24

gn_smtp.of_AddAddress("jasonr@flightviewlimo.com", "IT") //added on 7/24

lb_Return = gn_smtp.of_SendMail()

If lb_Return Then

MessageBox("Trip Closeout Request", "Request successfully sent to Billing.")

Else

MessageBox("Trip Closeout Request", gn_smtp.of_GetLastError())

End If

If lb_Return Then

return_code = "OK"

Else

return_code = "ERROR"

End If

return return_code