View Full Version : Feedback Form
HELIMAD
06-29-2002, 04:01 PM
For my sin's I'm looking to try and get some feedback on my site, I've just move it from freeserve and I used a cgi form there, but it won't work here........I'm not a wizard at these things and I'm lost as to how to get it working........
Can you help pls.......
Valuehost.com
06-29-2002, 10:04 PM
Hi,
Create a PHP script wich will send your email feedback.
insert to html:
--- CUT ---
<form action="myfeedback.php" method=POST>
Your Name: <input type=text name=visitorname size=30><BR>
Feedback: <textarea name=feedback></textarea><BR>
<input type=submit value=Send><BR>
</form>
--- CUT ---
Then create myfeedback.php in Notepad (or any text editor) and upload "myfeedback.php" to the same folder:
--- cut: myfeedback.php ---
<?
$email="your@email.address";
$subject="New feedback from my site";
mail("$email", "$subject", "$feedback","From:$email\nReply-To: $email\nContent-Type: text/plain; charset=\"iso-8859-1\"\nX-Mailer: Webmailer/" . phpversion());
?>
<html>
Place usual html here
Example: Thank you for submitting feedback!
</html>
--- cut: myfeedback.php ---
HELIMAD
06-30-2002, 12:05 PM
I understood your top bit and modified it to get the info I wanted, however, I have no idea about the .php section I don't quite understand.
I use FP2000 and I made a txt file and uploaded it, that didn't work so I made an .asp version and I'm getting an error of 504.....
Obviously, not getting it right.......
Have you a set of files you could e-mail for me to look at, it may help to understand better.........
I'm not the brightest when it comes to scripts.......;)
HELIMAD
06-30-2002, 03:13 PM
Can you tell I'm getting excited :D .......
I've got to the point where you fill it in and press send then it takes you to the next page, click on animation to get you back to homepage.
I get an e-mail saying feedback from your website......Yip Heeee!!
But unfortunatley no text :confused: .......
I'm just off the mark somewhere but I'm not sure where :confused:
Help Pls.......
www.rcheliaddict.co.uk/feedback.htm
In advance thanks and thanks again for you help so far......
Cheers
Stuart
Valuehost.com
07-02-2002, 10:36 AM
Hi
Let's see source of your PHP file and correct the problem.
Post your PHP here please.
Thanks
Sincerely,
Valuehost
jediii
07-04-2002, 05:42 PM
i have know idea what perl is
and i have the same problem
someone help!!!!
:hacker:
HELIMAD
07-04-2002, 10:24 PM
This is the html from myfeedback.php......which is effectively a .htm file renamed to .php.
<p><!--webbot bot="HTMLMarkup" startspan --><?
$email="stuart@rcheliaddict.co.uk";
$subject="Feedback from my site";
mail("$email", "$subject", "$feedback","From:$email\nReply-To: $email\nContent-Type: text/plain; charset=\"iso-8859-1\"\nX-Mailer: Webmailer/" . phpversion());
?>
<html>
<b>Thank you for submitting feedback
</b>
</html>
<!--webbot bot="HTMLMarkup" endspan -->
This is the form that I've used on the site.
<form action="myfeedback.php" method=POST>
<b>Your Name:</b> <input type=text name=visitorname size=35> <BR>
<b>Comments:</b> <h3><textarea name=Feedback rows="10" cols="45"></textarea></h3>
</blockquote>
<h3>Select from List</h3>
<blockquote>
<p><select name="Category" size="1" multiple>
<option selected>Feedback</option>
<option>Hints</option>
<option>General</option>
</select> </p>
</blockquote>
<p><b>How did you come across the site<select size="1" name="Referral">
<option selected>RunRyder</option>
<option>RC Web Directory</option>
<option>AOL</option>
<option>Yahoo</option>
<option>Google</option>
<option>Freeserve</option>
<option>FMS</option>
<option>Hotbot</option>
<option>Model Index</option>
<option>-------</option>
</select></b></p>
<p><b>If none of the above, feel free to right here</b></p>
<p><textarea rows="2" name="Comments" cols="32"></textarea></p>
<table>
<b>Your E-Mail Address:</b> <input type=text name=address size=35><BR>
<input type=submit value=Send><BR>
</form>
As mentioned I get an e-mail saying feedback, but no text in the e-mail to tell what they've said......
Thanks for helping...
EncoderZ
07-04-2002, 11:30 PM
Hi
On inspection of your feedback script I noticed that your "select from list options" faults:
1 - feedback, hints, general all *need* > specify value feedback
2 - How did you come across the site > drop down menu properties > your choices need a specify value eg: choice - Runryder, selected - yes, value Runryder, modify choice = specify value.
what people type in the visitorname, Feedback, comments, address fields does all that get posted, because that looks OK
I'd also use lowercase in the form field names - good to be universal.
The specify value means that it has a specified text to send - whichever is highlighted - if no value nothing is sent regardless of what name or what is highlighted from menus.
Hope this helps - get back if any more probs :)
HELIMAD
07-05-2002, 04:59 PM
I'm one of these people that takes ages to grasp things....
Could you pls, type and example of the source for say the drop down box and then I'll modify the site from that....
I'm confused when you say a value what value do you give :dnkn:
Thanks for you help
EncoderZ
07-05-2002, 09:12 PM
Think of it this way:
You have options people can see eg: feedback from your page, you also need a specify tag for each option you give because they are not typing it themselves, this specify tag is what is posted to you.
You could give the option feedback what people see in the drop down menu but you could also have the specify tag as "bin this" so if someone filling out your form and highlighted feedback, you'd get the text "bin this", below is the example you required, apologies I should've posted earlier:
<p><select name="Category" multiple size="1">
<option selected value="Feedback">Feedback</option>
<option>Hints</option>
<option>General</option>
</select> </p>
Hint and General need altering to the correct way, I did Feedback but not the latter 2 for example.
Do the same for any options you give in forms where you are specifying the option.
Hope this helps :)
HELIMAD
07-06-2002, 06:50 PM
I've altered all the bits with regards to the options etc, and I get an e-mail, but still no text to say what been filled in the form.
I must need to do something else......
I bet your getting sick of this one.....
HELIMAD
07-06-2002, 07:41 PM
I noticed that I was able to get the text written within the feedback section, but from nowhere else.
After a brain fart:D .
I thought that maybe the answer lay with the .php file as I assume it selects which fields from the form to e-mail over.
So I added the other field in the same format as the "$feedback", "$text", etc etc......
Now I get this error message.
Warning: Wrong parameter count for mail() myfeedback.php on line 51
It has no line 51, so I'm stumped, I'm sure I can smell the coffee but from where I'm lost.......
Pls help!!
HELIMAD
07-06-2002, 08:05 PM
I knew I could smell the coffee.........
Thanks for all you help:D :D :D
EncoderZ
07-06-2002, 08:17 PM
Originally posted by HELIMAD
I knew I could smell the coffee.........
Thanks for all you help:D :D :D
Great...was it the actual php script? You've been more pesistant with this script than I'd be tbh :)
I think you need a medal never mind a coffee!
HELIMAD
07-06-2002, 09:34 PM
Yeh,
You mentioned that it was best to keep to a single format for the named sections in the script.
Eventually I realised that not only do the named sections need to be the same "lower case", but also that the .php script had to also have the same named fields so as to fire all the details over via e-mail.
Now its working perfect, if anything the only part I'd like to add to it would be a an automatic reply to the person who left the feedback saying thanks.
My form asks for an e-mail address, so I don't know if this is easy or not.
But thanks for all your help, cheers
:D
mjkerr
01-27-2003, 04:28 PM
Helimad,
Did you find that saving your files in .htm format locally and then uploading them as .php worked alright?
HELIMAD
01-28-2003, 09:34 AM
Yes, upload as .htm and then rename on the server using your ftp software to .php
Works perfect.
Still haven't developed an automatic response e-mail I'd love to get that bit sorted, any ideas ?
spcomputing.com
01-28-2003, 10:33 AM
Within the VH control panel, you can set up autoresponders for any of your e-mail address.
vBulletin v3.0.7, Copyright ©2000-2010, Jelsoft Enterprises Ltd.