I am trying to have a "Contact us" page with a drop down tab that you can select from 4 people to contact. I am trying to figure out how to link each one to a certin email address. I was only able to get it with one. Thanks for your help.
krauz2
0
Light Poster
Recommended Answers
Jump to PostYou will need to take the POST value for the drop-down and use that as the E-Mail to address in the mail function, preferably, use names without an @ or domain.com and use …
Jump to PostIn contact1.php, change the 'value' for each of the <option> tags in the select to a single word in lower case to make it easire, for example, webmaster, info, tech and rgl like so:
<select name="attn" size="1"> <option value="webmaster">Webmaster </option> <option value="info">General Info </option> </select>
Then in …
Jump to PostTry de-capitalizing the W in webmaster, that was meant to be lower case
Jump to PostDoes the script in your last posts work? As this seems to be correct.
Make sure you put your code in code-tags so that it displays correctly
Also, yes I am based in the UK, but I work nightshift as tech support in the US department of a PC company
Jump to PostNo, check line 28 of his sendemail.php script:
$attn = $_POST['attn'];
Also, he has been echoing the attn value and it is printing the correct item.
All 26 Replies
Will Gresham
81
Master Poster
krauz2
0
Light Poster
Will Gresham
81
Master Poster
krauz2
0
Light Poster
Will Gresham
81
Master Poster
krauz2
0
Light Poster
krauz2
0
Light Poster
Will Gresham
81
Master Poster
krauz2
0
Light Poster
Will Gresham
81
Master Poster
krauz2
0
Light Poster
Will Gresham
81
Master Poster
krauz2
0
Light Poster
Will Gresham
81
Master Poster
krauz2
0
Light Poster
krauz2
0
Light Poster
krauz2
0
Light Poster
krauz2
0
Light Poster
Will Gresham
81
Master Poster
krauz2
0
Light Poster
Will Gresham
81
Master Poster
krauz2
0
Light Poster
scru
909
Posting Virtuoso
Featured Poster
Will Gresham
81
Master Poster
scru
commented:
sorry mate
+3
scru
909
Posting Virtuoso
Featured Poster
krauz2
0
Light Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.