xaser
Mitglied
Dabei seit: 19.01.04
Beiträge: 39
|
|
Hallo
.
Ich weis nicht genau ob das hier reingehört, aber ich frage einfach mal.
Und zwar, habe mir eine zweite formmail.php erstellt, und einw enig umgeschrieben. Und zwar habe ich eine Kontaktseite, mit mailaddresse. Wenn ein User draufklickt, wird die Mailaddresse, per GET übergeben, und in die variable $email gesetzt. Das funktioniert auch alles. Es wird das Template formmail2 ausgegeben, funktioniert auch!
Die Email, an die gesendet werden soll bleibt versteckt, sprich hidden. Klappt auch!
Wenn ich nun senden klicke, wird da irgendwie die Mailaddy nicht übergeben oder sonstetwas passiert da?!
Es kommt eben die Fehlermeldung, das die EMmailaddresse ungültig wäre.
Kann mir jemand helfen?
Code, formmail2.php:
code: |
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
|
$filename = 'formmail2.php';
require('./global.php');
$lang->load("MISC,POSTINGS");
if (!$wbbuserdata['userid'] || $wbbuserdata['activation'] != 1) access_error();
if (isset($_POST['send'])) {
if ($_POST['email'] == "") access_error();
$recipient = wbb_trim($_POST['email']);
$message = wbb_trim($_POST['message']);
if (!$message) error($lang->items['LANG_POSTINGS_ERROR1']);
if (!$recipient) error($lang->items['LANG_MISC_FORMMAIL_ERROR1']);
mailer($recipient, wbb_trim($_POST['subject']), $message, $wbbuserdata['email']);
eval("\$tpl->output(\"".$tpl->get("formmail3")."\");");
}
if (isset($_GET['email'])) {
$email = $_GET['email'];
$subject = "Frage an das Team";
eval("\$tpl->output(\"".$tpl->get("formmail2")."\");");
}
|
|
Template formmail2:
code: |
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
|
<?xml version="1.0" encoding="{$lang->items['LANG_GLOBAL_ENCODING']}"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" dir="{$lang->items['LANG_GLOBAL_DIRECTION']}" lang="{$lang->items['LANG_GLOBAL_LANGCODE']}" xml:lang="{$lang->items['LANG_GLOBAL_LANGCODE']}">
<head>
$headinclude
</head>
<body>
<table cellpadding="{$style['tableincellpadding']}" cellspacing="{$style['tableincellspacing']}" border="{$style['tableinborder']}" style="width:{$style['tableinwidth']}" class="tableinborder">
</table>
</table>
<form action="formmail2.php" method="post">
<table cellpadding="{$style['tableincellpadding']}" cellspacing="{$style['tableincellspacing']}" border="{$style['tableinborder']}" style="width:{$style['tableinwidth']}" class="tableinborder">
<tr>
<td class="tabletitle" colspan="2" align="left"><span class="normalfont"><b>{$lang->items['LANG_MISC_FORMMAIL_TITLE']}</b></span></td>
</tr>
<tr align="left">
<td><input class="input" type="hidden" name="email" value="$email"></td></tr>
<tr align="left">
<td class="tablea" valign="top"><span class="normalfont">{$lang->items['LANG_MISC_FORMMAIL_MESSAGE']}</span></td>
<td class="tablea"><textarea name="message" rows="14" cols="70">$message</textarea></td>
</tr>
</table>
<p align="center">
<input type="hidden" name="sid" value="$session[hash]" />
<input type="hidden" name="send" value="send" />
<input class="input" type="submit" name="submit" accesskey="S" value="{$lang->items['LANG_MISC_SEND']}" />
<input class="input" type="reset" name="reset" accesskey="R" value="{$lang->items['LANG_MISC_FORMMAIL_RESET']}" />
</p>
</form>
</body>
</html>
|
|
Wäre nett wenn mir jemand helfen könnte!
Danke
|
|