473,804 Members | 2,758 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

FeedBack Form

14 New Member
i have a code wherein it is asking email id and message from the user in the form named as feedback.html
HTML CODE AS BELOW[php]<html>
<body>
<form method="post" action="sendmai l.php">
Email: <input name="email" type="text" size="20" /><br />
Message:<br />
<textarea name="message" rows="15" cols="40">
</textarea><br />
<input type="submit" />
</form>
</body>
</html>[/php]THE ABOVE HTML CODE CALLS sendmail.php . wherein this accepts the emailid and message variable in php and sends mail.
PHP CODE AS BELOW[php]<?php
$email = $_REQUEST['email'] ;
$message = $_REQUEST['message'] ;

mail( "yourexample@ex ample.com", "Feedback Form Results",
$message, "From: $email" );
header( "Location: http://www.yoursite.co m/thanks.php" );
?>[/php]

in the above code yourexample@exa mple.com was my email address.
http://www.yoursite.com/thanks.php was having my clients site .

but the error is i havent recd any mail i my mailbox

anyone can help me please regarding this issue
Apr 9 '08
15 2659
TheServant
1,168 Recognized Expert Top Contributor
Sorry did you also change isset($_REQUEST['email']) to isset($_POST['email'])?

After looking at that link I gave you, they use REQUEST, so not 100% sure you can't do that... I only use POST though...

So are you getting an error, or is the email just not coming through?
Apr 11 '08 #11
nickyspace
14 New Member
Sorry did you also change isset($_REQUEST['email']) to isset($_POST['email'])?

After looking at that link I gave you, they use REQUEST, so not 100% sure you can't do that... I only use POST though...

So are you getting an error, or is the email just not coming through?
hi

The servant

i'm really very thankful to u for answering my query . but i'm very sad after making changes from REQUEST to POST the mail is still not working.

could you plz give any other alternative or any link where i can findout the way to overcome from phpmail
Apr 11 '08 #12
nickyspace
14 New Member
hi
the servant


thanxs for all ur help.

i have resolved my issue.

warm regards
priti
Apr 14 '08 #13
dlite922
1,584 Recognized Expert Top Contributor
Your form submission method has been changed to what I recommended, but your variables called by php ($email, $subject, $message) are still coming from a request ($_REQUEST['email'], $_REQUEST['subject'], $_REQUEST['message']).

You need to change your code to:
[PHP]$email = $_POST['email'] ;
$subject = $_POST['subject'] ;
$message = $_POST['message'] ;[/PHP]

Then it should work...
Why don't you like $_REQUEST()?

it basically just tries to get the vars from $_GET[], $_COOKIE[], and $_POST[] anyway.

not in that order though.

You insisted so much on something not relative.

How about asking if he's got PHP.INI configured to send mail and SMTP points to a valid SMTP server that sends mail.

peace out,

DM
Apr 14 '08 #14
TheServant
1,168 Recognized Expert Top Contributor
hi
the servant


thanxs for all ur help.

i have resolved my issue.

warm regards
priti

No worries mate.

Why don't you like $_REQUEST()?

it basically just tries to get the vars from $_GET[], $_COOKIE[], and $_POST[] anyway.

not in that order though.

You insisted so much on something not relative.

How about asking if he's got PHP.INI configured to send mail and SMTP points to a valid SMTP server that sends mail.

peace out,

DM
Personally I like to be exact, so if (I know this is unlikely) someone has 2 variables called the same thing, one in a COOKIE and then POSTs one, there could be issues. After this post I have been looking into it more and have realised that I was wrong to change that. You are right it is irrelavent and does not need to be changed.
Apr 14 '08 #15
Markus
6,050 Recognized Expert Expert
No worries mate.



Personally I like to be exact, so if (I know this is unlikely) someone has 2 variables called the same thing, one in a COOKIE and then POSTs one, there could be issues. After this post I have been looking into it more and have realised that I was wrong to change that. You are right it is irrelavent and does not need to be changed.
I too believe in being exact; for some reason i see $_REQUEST[] as being lazy - you should know how you're submitting values.

And, surely if $_REQUEST[] checks POST, GET and COOKIE values, it'd be more resource intensive?

But i digress -

OP: How did you solve the problem?
Apr 14 '08 #16

Sign in to post your reply or Sign up for a free account.

Similar topics

5
5114
by: Andrew | last post by:
Where can i find a free feedback form in php script to download it and put it in my website? thanks in advance andreas
1
4187
by: Kenneth McDonald | last post by:
I'm working on the 0.8 release of my 'rex' module, and would appreciate feedback, suggestions, and criticism as I work towards finalizing the API and feature sets. rex is a module intended to make regular expressions easier to create and use (and in my experience as a regular expression user, it makes them MUCH easier to create and use.) I'm still working on formal documentation, and in any case, such documentation isn't necessarily the...
2
5226
by: Mindful_Spirit | last post by:
I'm trying to set up a basic email feed back form like this, and was wondering about some basic configuration settings. I have used code from this website. I have it working just fine. I'm running IIS on my home machine. My problem is that I need to upload this stuff to a webhosting place and register a domain and I'm not sure what to put as the smtp mail server value
0
3518
by: starace | last post by:
I have designed a form that has 5 different list boxes where the selections within each are used as criteria in building a dynamic query. Some boxes are set for multiple selections but these list boxes do not necessarily need to have a selection made to be used in the dynamic query. In essence the form can have selections made in all or none of its list boxes to form the dynamic query I am looking to get some feedback in reference to...
6
2774
by: Patrick De Ridder | last post by:
I use a form with text boxes. The user enters data in the text boxes. The data is written away to a file. I wish to give the user feedback on the form, before the data is written away to the file - and (!) also before the user has finished entering all the data in remaining text boxes. How do I do this? Please give a short code example if you know the answer. Many thanks. --
0
1509
by: vijay | last post by:
hello friends, I have done one website by using frontpage 2005 and i have done the feedback form.Now I want to send this feedback form to email id.I have used mailto: in form tag but it is not working.so What is the solution.
4
2230
by: ianbarton | last post by:
Hello all I am trying to setup a feedback form on my webpage using some script provided by my ISP. I really don't know a lot about PHP and it's syntax etc. The feedback form only has 4 fields. These are UserName, UserEmail, UserCountry & Comments. It works well with all of those fields appearing in the body of an email that is sent to me. What I would now like is for the UserEmail field to appear in the "From:" field in the
1
1625
by: lali | last post by:
hi everybody, i am doing a project and i have strucked in middle of my code usiong asp. the problem is, in the feedback form there are many fields which are manidatory.when an user fills the form and clicks on submit button all the fields in the feedback form should be sent as the mail to the company who are providing feedback form can anybody help me out by giving me code?
9
2504
by: gs | last post by:
the feedback for the install of c#2008 places 97 to 99% cpu load for way too long on athlon x64 3800+ PC. 3/4 an hour later its only about 80% complete, continuing with 98% CPU load! Next time installing visual studio /dot product I will likely make sure no feedback
0
9705
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9576
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10074
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9138
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7613
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5516
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5647
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4292
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2988
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.