Jump to content

Error When Setting up PHP form.


j4yj4y

Recommended Posts

Hey guys, I am running a WAMPP on my computer. I have just created a feedback form and when I enter the details on the form_response.php

 

mail('jordan.jones1990@live.co.uk','Feedback', $email_message);

 

I get an error saying:

 

Warning: mail(): Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:\wamp\www\web\form_response.php on line 24

Call Stack

# Time Memory Function Location

1 0.0008 143496 {main}( ) ..\form_response.php:0

2 0.0008 144520 mail ( ) ..\form_response.php:24

 

Does anyone know what I have to do to get rid of this?

 

I have changed the details on the php.ini to 465 port and from local host to my ISPs details but nothing seems to work. I want to see what the outcome looks like so I can advance to the next video.

 

If anyone has anything please let me know :)

 

Thanks

 

j4yj4y

Link to comment
Share on other sites

Have you restarted the server since your php.ini changes? Since the error message that you've posted indicates that it is still trying to send via port 25.

 

To be honest, I usually only test mail() functionality on a live, working web server, rather than on my local computer. Getting this to work usually requires changes to the PHP.ini file and it can be a bit tricky to set up.

Link to comment
Share on other sites

Whenever I change the info in the php.ini, I then restart the server but it still says in the error port 25. I dont understand why it doesn't change.

 

Is there a 3rd party software which I could use? I have heard something about pear? I really want this to work so that I can see everything as it would be running live :)

 

Cheers,

 

j4yj4y

Link to comment
Share on other sites

Link to comment
Share on other sites

Orite ben, I followed one of your guides and got passed that error message. :)

 

However, I run into another one straight after.

 

Here it is:

 

 

Warning: mail(): SMTP server response: 530 5.7.0 Must issue a STARTTLS command first in C:\wamp\www\web\form_response.php on line 24

Call Stack

# Time Memory Function Location

1 0.0008 144336 {main}( ) ..\form_response.php:0

2 0.0008 145312 mail ( ) ..\form_response.php:24

 

Thanks for your help so far, but I need you again now :)

 

Cheers,

 

j4yj4y

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...