Und genau da liegt mein Problem: Wie stelle ich es an, dass die abgesende Nachricht in die Datenbank eingetragen wird, mitsamt User-ID und Nachrichten-ID?
Dies ist der Code der Shoutbox.php, welche ich in die includes/page_header.php eingebunden habe:
Code: Alles auswählen
<?php
if (!defined('IN_PHPBB'))
{
header("Location: index.php");
} else {
$template->set_filenames(array(
'shoutbox' => 'shoutbox_body.tpl',
));
$template->assign_vars(array(
'MESSAGE_TEXT' => 'test',
'RELOAD' => $lang['Reload'],
'SUBMIT' => $lang['Submit'],
'L_SHOUTBOX' => $phpbb_root_path . 'shoutbox.'.$phpEx,
'SHOUTBOX' => $lang['Shoutbox'],
));
}
?>
Code: Alles auswählen
<table width="150" cellpadding="1" cellspacing="1" border="0" class="forumline" align="left">
<tbody><tr>
<th colspan="2" class="thCornerL" height="25" nowrap="nowrap">{SHOUTBOX}</td>
</tr>
<tr>
<td class="row1" colspan="2" height="20" valign="center"><span class="genmed">
<form method="post" action="{L_SHOUTBOX}"><input class="post" type="text" name="message" size="15" /><input type="hidden" name="user_id" value="{USER_ID}" /><input type="submit" class="mainoption" name="submit" value="{SUBMIT}" /></form>
<a href="{U_INDEX}">{RELOAD}</a></span></td>
</tr>
<tr>
<td class="row2" colspan="2" height="28"><span class="cattitle">{MESSAGE_TEXT}</span></td>
</tr>
</table>

Dominic Laumer