You cannot select more than 25 topics
			Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
		
		
		
		
		
			
		
			
				
	
	
		
			39 lines
		
	
	
		
			1.2 KiB
		
	
	
	
		
			PHP
		
	
			
		
		
	
	
			39 lines
		
	
	
		
			1.2 KiB
		
	
	
	
		
			PHP
		
	
| <?php
 | |
| /*
 | |
|  * Created on 20.08.2007
 | |
|  *
 | |
|  * @copyright (c) 2010 animegame.eu
 | |
|  * @license http://www.gnu.org/licenses/gpl-3.0.html GNU General Public Licence
 | |
|  *
 | |
|  */
 | |
| /******************************************************************************
 | |
| * Dieser Skript enthaelt Funktionen fuer das versenden von Nachrichten wichtig ist
 | |
| * Dabei werden die Info's ueber einen bbCode umgesetzt
 | |
| *******************************************************************************
 | |
| * Autor: Pascal Proksch
 | |
| * Erstellungsdatum: 20.08.2007
 | |
| * Zuletzt veraendert: 03.10.2007
 | |
| *******************************************************************************/
 | |
| 
 | |
| include_once('../path.inc.php'); // get the path ;)
 | |
| include_once(ROOT_PATH.'/include/config/db.inc.php');
 | |
| 
 | |
| function getChatMessages(){
 | |
| 	$result = mysql_query('SELECT *, Minute(zeit) as m, Hour(zeit) as h, DAY(zeit) as d , MONTH(zeit) as mon FROM ag_chat ORDER BY ID desc');
 | |
| 	$resultstring = '';
 | |
| 	
 | |
| 	while ($row = mysql_fetch_array($result)) {
 | |
| 		$h = $row['h'];
 | |
| 		if($h < 10){ $h = "0".$h;}
 | |
| 		$m = $row['m'];
 | |
| 		if($m < 10){ $m = "0".$m;}
 | |
| 		$resultstring = $row['d'].'.'.$row['mon'].' '.$h.':'.$m.' '.$row['user'].': '.$row['nachricht'].'<br>'.$resultstring;
 | |
| 	}
 | |
| 	return $resultstring;
 | |
| }
 | |
| 
 | |
| echo getChatMessages();
 | |
| 
 | |
| ?>
 | |
| 
 |