asbxzeeko Posted February 23, 2013 Share Posted February 23, 2013 Probably a stupid question, but I was wondering how to add a BBcode option on my guestbook, on my website. I followed the steps exactly as they were in this tutorial (and the next two) but I can't seem configure the textarea to be the $outut. Sorry if that didn't make sense. Code for the guestbook page: <?php include 'header.php'; require 'classes/nbbc.php'; $bb = new bbcode(); $bb->SetDetectURLs(true); $bb->AddRule('php', array( 'simple_start' => '<pre class="php">', 'simple_end' => '</pre>', 'class' => 'block', 'allow_in' => null )); $bb->AddRule('youtube', array( 'mode' => BBCODE_MODE_ENHANCED, 'template' => '<iframe width="560" height="315" src="http://www.youtube.com/embed/{$_content}" frameborder="0" allowfullscreen></iframe>', 'class' => 'block', 'allow_in' => null )); $output = ''; $bb -> Parse($output); ?> <br> <form method=post action=add_entry.php> <table border='0' cellspacing='0' cellpadding='0' align=center width=300> <tr><td><font face='Verdana' size='2'>Your Name *</font><td><input type=text name=name></td></tr> <tr bgcolor=#F2EABD><td><font face='Verdana' size='2'>Email *</font><td><input type=text name=email></td></tr> <tr><td><font face='Verdana' size='2'>Country</font><td><input type=text name=country></td></tr> <tr bgcolor=#F2EABD><td colspan=2 align=center><textarea name=dtl rows=5 cols=40 id="textyy"></textarea></td></tr> <tr ><td colspan=2 align=center><input type=submit value='Add Entry'></td></tr> </table></form> <br><br> <?php include 'view_entry.php'; include 'footer.php'; ?> Thanks for reading! Quote Link to comment https://forums.phpfreaks.com/topic/274862-phpbbcode-question/ Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.