|
#1
|
|||
|
|||
Error, Forum
Hi i have a problem, i want to create a topic but apper a problem
Body Code:
Fatal error: Call to undefined function textbbcode() in C:\xampp\htdocs\forums.php on line 333 at the line 333 on forums.php appear |
#2
|
|||
|
|||
|
#3
|
|||
|
|||
don't work :sorry:
step by step please |
#4
|
|||
|
|||
---------------------------------------------
New textbbcode function --------------------------------------------- add this inside format_comment function Code:
//[align=(center|left|right|justify)]text[/align] $s = preg_replace("/\[align=([a-zA-Z]+)\]((\s|.)+?)\[\/align\]/i","<div style=\"text-align:\\1\">\\2</div>", $s); //[s]strike[/s] $s = preg_replace("/\[s\]((\s|.)+?)\[\/s\]/i", "<s>\\1</s>", $s); //[mail]mail[/mail] $s = preg_replace("/\[mail\]((\s|.)+?)\[\/mail\]/i","<a href=\"mailto:\\1\" targe=\"_blank\">\\1</a>", $s); --------------------------------------------- Textbbcode function --------------------------------------------- Don't forget to remove the space from java script ie. Code:
javascript Code:
// Credits: original creator; improvements by t.bz team function textbbcode($form,$name,$content="") { ?> <script language=javascript> function insertAtCursor(myField, myValue) { //IE support if (document.selection) { myField.focus(); sel = document.selection.createRange(); sel.text = myValue; } //MOZILLA/NETSCAPE support else if (myField.selectionStart || myField.selectionStart == '0') { var startPos = myField.selectionStart; var endPos = myField.selectionEnd; myField.value = myField.value.substring(0, startPos) + myValue + myField.value.substring(endPos, myField.value.length); myField.selectionEnd = startPos + myValue.length; } else { myField.value += myValue; } myField.focus(); } // calling the function function SmileIT(smile,form,text){ insertAtCursor(document.forms[form].elements[text], smile) } function PopMoreSmiles(form,name) { link='moresmiles.php?form='+form+'&text='+name newWin=window.open(link,'moresmile','height=500,width=450,resizable=no,scrollbars=yes'); if (window.focus) {newWin.focus()} } function PopMoreTags(form,name) { link='moretags.php?form='+form+'&text='+name newWin=window.open(link,'moresmile','height=500,width=775,resizable=no,scrollbars=yes'); if (window.focus) {newWin.focus()} } function BBTag(tag,s,text,form){ var df = document.forms[form].elements[s]; var ele = document.forms[form].elements[text]; var tval; var ttag; switch(tag) { case '<<<@!1!@>>>"; if(df.value == "QUOTE ") { tval = "QUOTE*"; ttag = "[quote]"; } break; case '[img]': tval = "IMG "; ttag = "[/img]"; if(df.value == "IMG ") { tval = "IMG*"; ttag = "[img]"; } break; case '': tval = "URL "; ttag = ""; if(df.value == "URL ") { tval = "URL*"; ttag = "[url]"; } break; case '[*]': tval= "List "; if(df.value == "List ") ttag = "[*]"; break; insertAtCursor(ele, tag); df.elements[s].value = tval; break; case '[hr]': tval= "Hr "; if(df.value =="HR "){ ttag="[HR]"; } insertAtCursor(ele,tag); df.elements[s].value=tval; break; case ' |
Tags |
error , forum |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Forum installing error | mat22 | BT.Manager (phpMyBitTorrent) | 1 | 10th February 2010 01:49 |
Forum error | simalingur | SZ Edition | 12 | 9th February 2010 18:36 |
Forum | piraders | Yuna Scatari Edition (YSE) | 3 | 28th December 2009 01:06 |
Forum? | adso | Torrent Trader | 0 | 7th August 2009 23:36 |
Error Under Forum | Azurious | BT.Manager (phpMyBitTorrent) | 6 | 18th January 2009 17:23 |