<?php
##################################
# functions.php #
##################################
# Форум на MySQL #
#Афтар : Morgan #
#ICQ : 530-648 #
#Email : [email protected] #
##################################
function my_error()
{
echo '<b>Ошибка MySQL</b> #'.mysql_errno().': '.mysql_error().'<br />';
}
function izmena($text)
{
$text = str_replace(')p','<img src="smiles/)P.gif"/>',$text);
$text = str_replace('=)','<img src="smiles/=).gif"/>',$text);
$text = str_replace('=]','<img src="smiles/=].gif"/>',$text);
$text = str_replace('[admin]','<img src="smiles/admin.gif"/>',$text);
$text = str_replace('[answer]','<img src="smiles/answer.gif"/>',$text);
$text = str_replace('[close]','<img src="smiles/close.gif"/>',$text);
$text = str_replace('[dollar]','<img src="smiles/dollar.gif"/>',$text);
$text = str_replace('[dumay]','<img src="smiles/dumay.gif"/>',$text);
$text = str_replace('[elvis]','<img src="smiles/elvis.gif"/>',$text);
$text = str_replace('[flowers]','<img src="smiles/flowers.gif"/>',$text);
$text = str_replace('[hachu]','<img src="smiles/hachu.gif"/>',$text);
$text = str_replace('[in_love]','<img src="smiles/in_love.gif"/>',$text);
$text = str_replace('[kaleka]','<img src="smiles/kaleka.gif"/>',$text);
$text = str_replace('[man]','<img src="smiles/man.gif"/>',$text);
$text = str_replace('[mod]','<img src="smiles/mod.gif"/>',$text);
$text = str_replace('[molodec]','<img src="smiles/molodec.gif"/>',$text);
$text = str_replace('[monah]','<img src="smiles/monah.gif"/>',$text);
$text = str_replace('[moroz]','<img src="smiles/moroz.gif"/>',$text);
$text = str_replace('[neznay]','<img src="smiles/neznay.gif"/>',$text);
$text = str_replace('[ninzya]','<img src="smiles/ninzya.gif"/>',$text);
$text = str_replace('[O_o2]','<img src="smiles/O_o2.gif"/>',$text);
$text = str_replace('[O_o]','<img src="smiles/O_o.gif"/>',$text);
$text = str_replace('[ofigel]','<img src="smiles/ofigel.gif"/>',$text);
$text = str_replace('[ok]','<img src="smiles/ok.gif"/>',$text);
$text = str_replace('[OoO]','<img src="smiles/OoO.gif"/>',$text);
$text = str_replace('[open]','<img src="smiles/open.gif"/>',$text);
$text = str_replace('[pank]','<img src="smiles/pank.gif"/>',$text);
$text = str_replace('[plachu]','<img src="smiles/plachu.gif"/>',$text);
$text = str_replace('[podmig]','<img src="smiles/podmig.gif"/>',$text);
$text = str_replace('[simp]','<img src="smiles/simp.gif"/>',$text);
$text = str_replace('[sleza]','<img src="smiles/sleza.gif"/>',$text);
$text = str_replace('[smele2]','<img src="smiles/smele2.gif"/>',$text);
$text = str_replace('[smile1]','<img src="smiles/smile1.gif"/>',$text);
$text = str_replace('[smile3]','<img src="smiles/smile3.gif"/>',$text);
$text = str_replace('[smile4]','<img src="smiles/smile4.gif"/>',$text);
$text = str_replace('[smile]','<img src="smiles/smile.gif"/>',$text);
$text = str_replace('[somnevays]','<img src="smiles/somnevays.gif"/>',$text);
$text = str_replace('[soska]','<img src="smiles/soska.gif"/>',$text);
$text = str_replace('[ura]','<img src="smiles/ura.gif"/>',$text);
$text = str_replace('[uuu]','<img src="smiles/uuu.gif"/>',$text);
$text = str_replace('[xuy]','<img src="smiles/xuy.gif"/>',$text);
$text = str_replace('[yxaxa]','<img src="smiles/yxaxa.gif"/>',$text);
$text = str_replace('[zloy]','<img src="smiles/zloy.gif"/>',$text);
$text = str_replace('[play]','<img src="smiles/play.gif"/>',$text);
$text = eregi_replace('(.*)\\[url\\](.*)\\[/url\\](.*)','\\1<a href=\\2>\\2</a>\\3',$text);
$text=preg_replace( '#\[red\](.+?)\[/red\]#is' , '<font color=red>\\1</font>',$text);
$text=preg_replace( "#\[b\](.+?)\[/b\]#is" , "<b>\\1</b>",$text);
$text=preg_replace( "#\[i\](.+?)\[/i\]#is" , "<i>\\1</i>",$text);
$text=preg_replace( "#\[u\](.+?)\[/u\]#is" , "<u>\\1</u>",$text);
$text = preg_replace( '#\[sub\](.+?)\[/sub\]#is' , '<sub>\\1</sub>',$text);
$text = preg_replace( '#\[sup\](.+?)\[/sup\]#is' , '<sup>\\1</sup>',$text);
return ($text);
}
##################################
# © Все права защищены #
##################################
?>