Code: Select all
local domain = "%Domain"
local username = "%Name"
local weblink = "%WebLink"
local filename = "%FileName"
local client_ip = "%IP"
if username == "<UPLOADLINK>" then
local result = c_ExecuteSQL("select f_email from wftp_weblink where f_domain='"..domain.."' and f_is_uplink=1 and f_weblink='"..weblink.."' limit 1")
if result[1] ~= nil and result[1][0] ~= "" then
local arrEmail = Split(result[1][0], "|")
if table.maxn(arrEmail) == 2 and arrEmail[2] ~= "" then
local notifyEmail = arrEmail[2]
c_SendMail(notifyEmail, "File uploaded via uploadlink "..weblink, "Client "..client_ip.." uploaded the file '"..filename.."'.", "", "SMTP_CONFIG")
end
end
end
Then you can login the web client and create a File Upload Request, just check on the option "Send email to" and input the recipient's email address, and specify the originator's email address in the filed "My email address".
So when the recipient uploads files via the upload link, an email notification will be sent to the originator.