ich versuche jetzt schon seit Stunden das Problem zu lösen aber keine Chance. Es klappt einfach nicht. Ich habe vorhin den Ajax Chat 0.8.1.2 installiert. War auch kein Problem. Über http://www.ngwreloaded.de/phpBB3/chat ist dieser auch zuerreichen. Im ReadMe steht aber das man diesen Chat auch als Shoutbox verweden kann:
Shoutbox:
=========
AJAX Chat is also usable as shoutbox - this is a short guide on how to set it up:
1. Shoutbox stylesheet
----------------------
Add the following line to the stylesheet (CSS) of all pages displaying the shoutbox:
@import url("http://example.org/path/to/chat/css/shoutbox.css");
Replace http://example.org/path/to/chat/ with the URL to the chat.
Modify css/shoutbox.css to your liking.
2. Shoutbox function
--------------------
Add the following function to your PHP code:
<?php
function getShoutBoxContent() {
// URL to the chat directory:
if(!defined('AJAX_CHAT_URL')) {
define('AJAX_CHAT_URL', './chat/');
}
// Path to the chat directory:
if(!defined('AJAX_CHAT_PATH')) {
define('AJAX_CHAT_PATH', realpath(dirname($_SERVER['SCRIPT_FILENAME']).'/chat').'/');
}
// Validate the path to the chat:
if(@is_file(AJAX_CHAT_PATH.'lib/classes.php')) {
// Include Class libraries:
require_once(AJAX_CHAT_PATH.'lib/classes.php');
// Initialize the shoutbox:
$ajaxChat = new CustomAJAXChatShoutBox();
// Parse and return the shoutbox template content:
return $ajaxChat->getShoutBoxContent();
}
return null;
}
?>
Make sure AJAX_CHAT_URL and AJAX_CHAT_PATH point to the chat directory.
2. Shoutbox output
------------------
Display the shoutbox content using the shoutbox function:
<div style="width:200px;"><?php echo getShoutBoxContent(); ?></div>
Jedoch verstehe ich es nicht 100%ig was die von mir wollen, wo soll ich das denn einfügen? Den ersten Code habe ich mal ins template.php eingetragen und den zweiten habe ich in meinen Style in den Index_body.html eingetragen. Aber es kommt immer folgende Meldung:
Code: Alles auswählen
Fatal error: Call to undefined function: () in /var/www/***/html/phpBB3/includes/template.php(187) : eval()'d code on line 34