Code in php - Template einbinden: wie?
FruchtderLiebe
- php
0 Tom0 FruchtderLiebe0 vangoo
Hallo,
ich möchte den Code:
<?php
$wochentag = date("w");
$stunde = date("H");
if($wochentag == 3 && $stunde > 19){ // Wenn der Wochentag == Mittwoch ist und es später als 19.59 Uhr ist
echo "<img src="top_chat_animiert.gif">";
}else{
echo "<img src="top_chat.gif">";
}
?>
Hier einbinden:
<?php
/*
templatepackid: 0
templatename: header
*/
$this->templates['header']="<table style=\"width:{$style['tableoutwidth']}\" cellpadding=\"{$style['tableoutcellpadding']}\" cellspacing=\"{$style['tableoutcellspacing']}\" align=\"center\" border=\"{$style['tableoutborder']}\" class=\"tableoutborder\">
<tr>
<td class=\"mainpage\" align=\"center\">
<table style=\"width:100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">
<tr>
<td class=\"logobackground\" align=\"center\">".(($style['logoimage']!="") ? ("
<map name=\"FPMap0\">
<area target=\"_blank\" href=\"http://www.avon-renndienst.de\" shape=\"rect\" coords=\"1, 177, 473, 240\">
<area target=\"_blank\" href=\"http://www.reuter-motorsport.de\" shape=\"rect\" coords=\"473, 177, 940, 240\">
<area href=\"http://www.atmotorsport-forum.de\" shape=\"rect\" coords=\"0, 1, 939, 176\">
</map>
<img border=\"0\" src=\"http://atmotorsport-forum.de/images/logo.gif\" usemap=\"#FPMap0\">
") : (""))."</td>
</tr>
<tr align=\"center\">
<td><br><br>
<a href=\"http://www.raceforhelp.de\" target=\"_blank\"><img alt=\"Flugplatzblasen\" src=\"http://www.atmotorsport-forum.de/bilder/aktuell.flublakonvoi2.gif\" border=\"0\"></a>
<br><br></td>
</tr>
<tr>
<td align=\"center\"><span class=\"smallfont\"><br>
".(($wbbuserdata['userid']) ? ("
<a href=\"usercp.php{$SID_ARG_1ST}\"><img src=\"{$style['imagefolder']}/top_usercp.gif\" border=\"0\" alt=\"{$lang->items['LANG_GLOBAL_USERCP']}\" title=\"{$lang->items['LANG_GLOBAL_USERCP']}\" /></a>
<a href=\"pms.php{$SID_ARG_1ST}\"><img src=\"{$style['imagefolder']}/top_pms.gif\" border=\"0\" alt=\"{$lang->items['LANG_GLOBAL_PMS']}\" title=\"{$lang->items['LANG_GLOBAL_PMS']}\" /></a>")
: ("<a href=\"register.php{$SID_ARG_1ST}\"><img src=\"{$style['imagefolder']}/top_register.gif\" border=\"0\" alt=\"{$lang->items['LANG_GLOBAL_REGISTER']}\" title=\"{$lang->items['LANG_GLOBAL_REGISTER']}\" /></a>"))."
<a href=\"videos.php{$SlD_ARG_1ST}\"><img src=\"{$style['imagefolder']}/top_videos.gif\" border=\"0\" alt=\"Videos\" title=\"Videos\" /></a>
<a href=\"links.php{$SlD_ARG_1ST}\"><img src=\"{$style['imagefolder']}/top_links.gif\" border=\"0\" alt=\"Links\" title=\"Links\" /></a>
<a target=_blank href=\"http://server2.webkicks.de/bergchat/index.cgi\"><img src=\"{$style['imagefolder']}/top_chat.gif\" border=\"0\" alt=\"Chat\" title=\"Chat\" /></a>
<a href=\"search.php{$SID_ARG_1ST}\"><img src=\"{$style['imagefolder']}/top_search.gif\" border=\"0\" alt=\"{$lang->items['LANG_GLOBAL_SEARCH']}\" title=\"{$lang->items['LANG_GLOBAL_SEARCH']}\" /></a>
".(($wbbuserdata['a_can_use_acp']==1 && $wbbuserdata['a_acp_or_mcp']==1) ? ("<a href=\"acp/index.php\" target=\"_blank\"><img src=\"{$style['imagefolder']}/top_acp.gif\" border=\"0\" alt=\"{$lang->items['LANG_GLOBAL_ACP']}\" title=\"{$lang->items['LANG_GLOBAL_ACP']}\" /></a>") : (""))."
".(($wbbuserdata['a_can_use_acp']==1 && $wbbuserdata['a_acp_or_mcp']==0) ? ("<a href=\"acp/index.php\" target=\"_blank\"><img src=\"{$style['imagefolder']}/top_modcp.gif\" border=\"0\" alt=\"{$lang->items['LANG_GLOBAL_MODCP']}\" title=\"{$lang->items['LANG_GLOBAL_MODCP']}\" /></a>") : (""))."
<a href=\"index.php{$SlD_ARG_1ST}\"><img src=\"{$style['imagefolder']}/top_start.gif\" border=\"0\" alt=\"{$lang->items['LANG_GLOBAL_TOINDEX']}\" title=\"{$lang->items['LANG_GLOBAL_TOINDEX']}\" /></a>
<br><br>
<a href=\"calendar.php{$SID_ARG_1ST}\"><img src=\"{$style['imagefolder']}/top_calendar.gif\" border=\"0\" alt=\"{$lang->items['LANG_GLOBAL_CALENDAR']}\" title=\"{$lang->items['LANG_GLOBAL_CALENDAR']}\" /></a>
<a href=\"memberslist.php{$SID_ARG_1ST}\"><img src=\"{$style['imagefolder']}/top_members.gif\" border=\"0\" alt=\"{$lang->items['LANG_GLOBAL_MEMBERSLIST']}\" title=\"{$lang->items['LANG_GLOBAL_MEMBERSLIST']}\" /></a>
<a href=\"team.php{$SID_ARG_1ST}\"><img src=\"{$style['imagefolder']}/top_team.gif\" border=\"0\" alt=\"{$lang->items['LANG_GLOBAL_TEAM']}\" title=\"{$lang->items['LANG_GLOBAL_TEAM']}\" /></a>
<a href=\"misc.php?action=faq{$SID_ARG_2ND}\"><img src=\"{$style['imagefolder']}/top_faq.gif\" border=\"0\" alt=\"{$lang->items['LANG_GLOBAL_FAQ']}\" title=\"{$lang->items['LANG_GLOBAL_FAQ']}\" /></a>
<a href=\"misc.php?action=imprint{$SID_ARG_2ND}\"><img src=\"{$style['imagefolder']}/top_impressum.gif\" border=\"0\" alt=\"{$lang->items['LANG_GLOBAL_IMPRINT']}\" title=\"{$lang->items['LANG_GLOBAL_IMPRINT']}\" /></a>
</span></td>
</tr>
</table><br />";
?>
Zwischen dem Bild top_links.gif und top_search.gif, also für das Bild top_chat.gif!
DANKE FÜR NE HILFE!
LG
FruchtderLiebe
Hello,
\\\irgend\\wie finde ich \\\\\die\\eigent\\li\che\Frage\\nich\t. ;-)
Was willst Du denn nun wirklich wissen?
Harzliche Grüße vom Berg
http://bergpost.annerschbarrich.de
Tom
Hello,
\\\irgend\\wie finde ich \\\\\die\\eigent\\li\che\Frage\\nich\t. ;-)
Was willst Du denn nun wirklich wissen?
Harzliche Grüße vom Berg
http://bergpost.annerschbarrich.deTom
Wie ich den Code in das Template reinbekomme, ohne etwas kaputt zu machen...
Hallo,
informiere dich doch in der Dokumentation des Woltlab forums.
http://www.woltlab.de/de/documentation/
Falls du dort nichts findest ist das woltlab forum auch ganz nützlich.
bye vangoo