PDA

View Full Version : Please help me



joely14
04-28-2006, 05:32 PM
hi
ive got a form but i cant get it to email it to me when the submit button is pressed, ive read the bit below but cant work out what it means !!
PLEASE HELP

2) Now create a new file using Notepad and call it: contact.php
So now you will have two pages one called

www.YourDomainName.com/contact.html and one called
www.YourDomainName.com/contact.php
Enter the following code into the file (replace order@example.com with your own email address):

<HTML>
<HEAD>
<TITLE>Succesfully processed your order</TITLE>
</HEAD>
<BODY>
<H2>Thanks for your order!</H2>

<?PHP
$email = $HTTP_POST_VARS[email];
$mailto = "order@example.com";
$mailsubj = "Enter Your Subject Here";
$mailhead = "From: $email\n";
reset ($HTTP_POST_VARS);
$mailbody = "Values submitted from web site form:\n";
while (list ($key, $val) = each ($HTTP_POST_VARS))
{
$mailbody .= "$key : $val\n";
}
mail($mailto, $mailsubj, $mailbody, $mailhead);
?>
</BODY>
</HTML>

Girlonthehill
04-28-2006, 05:53 PM
hi
ive got a form but i cant get it to email it to me when the submit button is pressed, ive read the bit below but cant work out what it means !!
PLEASE HELP

2) Now create a new file using Notepad and call it: contact.php
So now you will have two pages one called

www.YourDomainName.com/contact.html and one called
www.YourDomainName.com/contact.php
Enter the following code into the file (replace order@example.com with your own email address):

<HTML>
<HEAD>
<TITLE>Succesfully processed your order</TITLE>
</HEAD>
<BODY>
<H2>Thanks for your order!</H2>

<?PHP
$email = $HTTP_POST_VARS[email];
$mailto = "order@example.com";
$mailsubj = "Enter Your Subject Here";
$mailhead = "From: $email\n";
reset ($HTTP_POST_VARS);
$mailbody = "Values submitted from web site form:\n";
while (list ($key, $val) = each ($HTTP_POST_VARS))
{
$mailbody .= "$key : $val\n";
}
mail($mailto, $mailsubj, $mailbody, $mailhead);
?>
</BODY>
</HTML>
I don't really know how to explain it much better than that. Open up notepad (start>all programs>accessories>notepad>).
Paste the above code into a new page, changing the relevant bits to reflect your details. Save as (change the file type to all files) contact.php

Back to your BV page. Use the file publisher tool (looks like a globe with an arrow on it). It opens a box. Duble click the box and browse for the contact.php file that you've just created.

Publish your page as normal.

The file published doesn't show on your published page but acts as a kind of basket to carry files to your public.html folder.

If, after trying the above, you are still experiencing difficulties then please post back asking for help.

Good luck.

joely14
04-28-2006, 06:49 PM
hi
that made things alot easier to understand, thank you very much.
only trouble is im still struggling it still doesnt seem to wrk, any help would be really really appreciated :)
AARRRGGGHHHH
the website is www.bouncypartyplanners.co.uk/setup/setup.html (http://www.bouncypartyplanners.co.uk/setup/setup.html)

beegud2
04-28-2006, 06:50 PM
Hi

Try this tutorial by Andy 128....it worked for me...as a matter of fact Amanda put me on to it...it was great and easy.

http://netisopen.com/computer/TF001/T001.html

Hope that helps and like Amanda says check back...some one is always here to help.

It was simple and I followed it as I went along and now my email is working.

joely14
04-28-2006, 06:50 PM
i meant http://www.bouncypartyplanners.co.uk/setup/Setup.html sorry

joely14
04-28-2006, 08:41 PM
thanks for that link, i expect i am really startin to look silly but still nothing im going crazy
can anyone do any more to help?
http://www.bouncypartyplanners.co.uk/setup/Setup.html (http://www.http://www.bouncypartyplanners.co.uk/setup/Setup.html)

beegud2
04-28-2006, 08:47 PM
Just quick question...is it that you are not getting you mail or is the whole form not working...what I mean is...is your form not going through when you send it to your email or is that the you are getting a url error.?

joely14
04-28-2006, 08:58 PM
im gettin url error

beegud2
04-28-2006, 09:30 PM
Ok then you probably did a goofy like me. Did you name you page contact.bvp or contactme.bvp ...just to be sure that was okay.
1.) Now on your form double click to open the properties dialog box.
2.) In the section that says action you should type contact.php (or what ever second page you chose...it could also be thankyou.php) as your action to occur. Remember that you must have created a contact.php page for that to work. I created a thankyou page in bluevoda thankyou.bvp and directed my action to thankyou.php so that when my visitors finish the form and send they are sent to the thank you page.
3.) Publish all your pages before trying to test your form. I then published all my pages including the thankyou.bvp. Also did you copy the exact script on Andy's tutorial and place it in the page html in the inside tag section of the page you are directing the action to take place (ie your contact.php page where action is directed.) I know this sounds confusing but try and see what happens.
4.) Publish everything and see what happens and then we can try again if you are still having problems.

basically you have to have somewhere for the page to go to...whether it is thankyou or contactme.

joely14
04-28-2006, 09:57 PM
wahoo well done thank you so much, 1 more problem just that ive got the email but no info in it any ideas?

beegud2
04-28-2006, 10:00 PM
sorry I got one of my 'duh' moments as I call them...I'm not quite sure I know what you mean...

joely14
04-28-2006, 10:08 PM
i am now at last gettin the email but the email doesnt contain any information it jus says a for has been submited

beegud2
04-28-2006, 10:16 PM
Diid you test your form by filling out the fields and sending it.
Have you gone into your cpanel and setup your account?
I can test it for you by filling out and sending to you if you like....
I thought your form looked great and had a lot of info. It is quite fabulous ..although I wanted to know if you meant to spell pinata the way you did deliberately?

joely14
04-28-2006, 10:16 PM
wahoo well done thank you so much, 1 more problem just that ive got the email but no info in it any ideas?

joely14
04-28-2006, 10:17 PM
ive just got a message saying
Values submitted from web site form:

joely14
04-28-2006, 10:20 PM
if you could that would be great i have tried it but you never know what might happen, thanks for the tip off bout spelling mistake !!! :)

beegud2
04-28-2006, 10:49 PM
Hey Joely14,

Just submitted on your form and it seems to be working fine. I got sent to the thank you, we''l be in touch with you soon page. Now I guess it's time to check the webmail and see what you got. A tip here if you have not already figured it out. To get to your mail...go into 'mail' NOT your webmail on your cpanel and the section for add/mange etc accounts and set up accounts there and check mail there...it's tons easier....at least for my techie challenged mind.

Andy128
04-29-2006, 01:42 AM
joely14-

Looking at the source code- there are few problems.

Encode type in the form properties is set to text/plain
It should be blank

Several check boxes have no name and therefore will not get posted.
Name the submit button- Submit

I would suggest simplifying your field names- Many are long and multiple words. If you must have more than one word you need to use an under score ( _ ) between them. For example; contact_us or phone_number
Also- it is a good idea to get into the habit of keeping everything lower case.

If you are still not getting information after addressing the above- post back.

Andy

Andy128
04-29-2006, 01:48 AM
beegud2,

As to accessing your e-mail. After your domain name simply put /webmail
and hit enter.

A pop up will open and ask for your user name and password. Simply type in your full e-mail address that you set up in c-panel. Example-
webmaster@beegud2.com then put in the pass word you created for that account and it will open right up to the mail center. No hassel in having to go through c-panel.

Just a thought.

In fact- on my main site I created a nav button that says Mail Check-
When I hit that it is a link to webmaster@netisopen.com and I can get my mail.

Cheers
Andy

beegud2
04-29-2006, 02:14 AM
Andy,

As usual...a life saver and thanks for tip for me also. I'm glad you checked the thread and caught all this stuff. Now if only you can help me solve my domain problem....christobal and sadain have tried....sigh...:)

joely14
04-29-2006, 07:48 AM
everything working perfectly thankyou so much really appreciated

davidundalicia
04-29-2006, 09:27 PM
Now if only you can help me solve my domain problem.

Its working now..........................At least I could view it......