Page 1 of 1

Sending formmail.php from a free web host?

Posted: Tue May 16, 2006 3:30 am
by mamaluke
Is it possible to send a formmail script form RIPWAY.net or 110MB.com because I know they support free php, but every time I try to use this it wont work.

I know everything is coded right because when I used this formmail script on the website I got it off of (they have it so you can use it to test it) It works fine....

Posted: Tue May 16, 2006 5:57 am
by JayBird
Would be best to ask the provider.

In what way doesn't it work, any error messages?

Posted: Tue May 16, 2006 6:03 am
by mamaluke
nope I just never get the message in mail.

Posted: Tue May 16, 2006 6:12 am
by Chris Corbyn
What's the script? If mail() is blocked you can try Swift Mailer (see my signature) or phpMailer.

ok

Posted: Tue May 16, 2006 7:27 am
by mamaluke
Ok dw11 I appreciate the help but I tryed looking through those scripts and tryed to use it to work with me but I got lost. Basically im a NOOB lol, I have very little clue on what I am doing All I know is in the last 4 days I have gone through every single tutorial on how to make a formmail. I think I have the part on how to put it thourgh Flash and PHP the only problem Im having now is that im not getting the mails? Did anyone ever use a free php host to use a formmail and if so can you please write me a quick tutorial on how to do this. Because I am honestly going crazy!

I have seen thousands of different types of formmail scripts. I have seen thousands of free php host. But for some reason I just cant get the emails :( and yes im using the (mail) code or whatever in PHP. Do you think you could just give me a quick explaination on how to use it though? Thanks alot.

Posted: Tue May 16, 2006 8:17 am
by mamaluke
Ok, All I need to see is a simple code of how to send a two inputbox form to my GMAIL inbox.

Oh yeah, and isnt there a spot where you need to put your domain as the refferal url or something? So if I was using ripway.com my url usually comes out to something like

http://h1.ripway.com/jimread/formmail.php

since that h1. gets put in there instead of putting http://www.ripway.com would i put http://h1.ripway.com? I am so lost

Ok

Posted: Tue May 16, 2006 4:03 pm
by mamaluke
Ok here is the code I am using.

I am using the Jack's Formmail Script since that is apperently the script which is most popular.

Heres the only code i changed in the PHP script

Code: Select all

// for ultimate security, use this instead of using the form
$recipient = "jimsemail@gmail.com"; // jimsemail@gmail.com

// bcc emails (separate multiples with commas (,))
$bcc = "";

// referers.. domains/ips that you will allow forms to
// reside on.
$referers = array ('ripway.com','www.ripway.com','192.168.0.5');

Ok and in my HTML I have this code

Code: Select all

<html>  <head>  <title>Form Mail</title> </head>
<body bgcolor="#FFFFFF" text="#000000"> <form name="form1" method="post" action="formmail.php">
<input type=hidden name="subject" value="Form Mail Results">
<input type=hidden name="required" value="fullname,email">
<input type=hidden name="redirect" value="http://www.thankyoupage.com"">
Name<br><input type=text name="fullname"><br>
Email<br> <input type=text name="email"><br>
<br> <input type="submit" name="Submit" value="Submit">
</form>
</body> </html>
Everything works fine it redirects me but I never get an email with the results? Any suggestions on what to change

Posted: Tue May 16, 2006 4:55 pm
by RobertGonzalez
Nothing in the code you posted would suggest that an email would be sent. Have you looked at the PHP manual for mail()? If the mail function is disabled for your server then mail() won't work. Of course, I would suggest you look at d11's swiftmailer and try using that, seeing as it doesn't rely on mail() to do what you want. :wink:

Posted: Tue May 16, 2006 5:56 pm
by mamaluke
I took my redirection script out to see if there were any errors and im getting this


Warning: mail(): SMTP server response: 550 5.7.1 Unable to relay for jimsemail@gmail.com in \\192.168.1.16\webfiles\files\2005-12\566918\formmail.php on line 237
Thank you for your submission

This form is powered by Jack's Formmail.php 5.0!

Posted: Tue May 16, 2006 6:02 pm
by RobertGonzalez
Are you testing locally? Is your SMTP server setup for this?

Posted: Tue May 16, 2006 6:03 pm
by mamaluke
All I am doing is uploading the scripts to my free PHP host at "ripway.com" and then clicking on the link to test?

Posted: Tue May 16, 2006 6:07 pm
by Chris Corbyn
mamaluke wrote:I took my redirection script out to see if there were any errors and im getting this


Warning: mail(): SMTP server response: 550 5.7.1 Unable to relay for jimsemail@gmail.com in \\192.168.1.16\webfiles\files\2005-12\566918\formmail.php on line 237
Thank you for your submission

This form is powered by Jack's Formmail.php 5.0!
It looks like you're on a windows server and using SMTP for mail() in php.ini. Either that SMTP server needs a username and password to send mail outside of it's own domain or it doesn't allow hosts outside of it's domain to send mail out at all. If it's authentication you need then Swift should manage that... (no plug intended).

Swift

Posted: Tue May 16, 2006 6:09 pm
by mamaluke
I know i was looking through the scripts for swift it looked great. However I got very lost haha... Im new to all of this ( I just started like last week) LOL so do you think that you could help me set this up?