Jump to content

Need help with a mail function


Recommended Posts

i dont see anything bad with that code i can't make it to work it will fill in the boxes but it wont submit the form and also it doesnt hide the screen i cant seem to make it work

#include

Func sendmail($FromName,$FromEmail,$ToEmail,$Subject,$Message,$silent)



$oIE = _IECreate ("http://www.spoofalot.com/anon_email.php", 0, 0)

WinSetState("Spoofalot Anon Emails - Microsoft Internet Explorer","",@SW_HIDE)



$o_form = _IEFormGetCollection ($oIE, 0)

$o_FromName = _IEFormElementGetObjByName ($o_form, "name")

$o_FromEmail= _IEFormElementGetObjByName ($o_form, "email")

$o_Toemail= _IEFormElementGetObjByName ($o_form, "to")

$o_Subject = _IEFormElementGetObjByName ($o_form, "Subject")

$o_Message = _IEFormElementGetObjByName($o_form,"message")

If @error = 1 Then 

if $silent = 1 then MsgBox(0, "Error","No connection")

return 0

EndIf

_IEFormElementSetValue ($o_FromName, $FromName)

_IEFormElementSetValue ($o_FromEmail, $FromEmail)

_IEFormElementSetValue ($o_Toemail, $ToEmail)

_IEFormElementSetValue ($o_Subject, $Subject)

_IEFormElementSetValue ($o_Message,$Message)

_IEFormSubmit ($o_form)

_IEQuit($oIE)

EndFunc
Link to post
Share on other sites

I stopped reading at the first line. Do a search and you will probably find zillions of working samples.

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...