BB Code
Geplaatst: 24 jan 2008, 14:39
door tbsites
hoe kan ik de tekst laten parsen in de BB-Code van phpBB3?
M'n Code is nu:
M'n Code is nu:
- Spoiler: bekijk
Code: Selecteer alles
<?php error_reporting(E_ALL); ini_set("display_errors", "on"); define('IN_PHPBB', true); $phpbb_root_path = '../../forum/'; $phpEx = substr(strrchr(__FILE__, '.'), 1); include($phpbb_root_path . 'common.' . $phpEx); include($phpbb_root_path . 'includes/functions_compress.' . $phpEx); include($phpbb_root_path . 'includes/functions_jabber.' . $phpEx); include($phpbb_root_path . 'includes/functions_privmsgs.' . $phpEx); include($phpbb_root_path . 'includes/functions_upload.' . $phpEx); include($phpbb_root_path . 'includes/constants.' . $phpEx); include($phpbb_root_path . 'includes/functions_convert.' . $phpEx); include($phpbb_root_path . 'includes/functions_messenger.' . $phpEx); include($phpbb_root_path . 'includes/functions_profile_fields.' . $phpEx); include($phpbb_root_path . 'includes/functions_user.' . $phpEx); include($phpbb_root_path . 'includes/functions_display.' . $phpEx); include($phpbb_root_path . 'includes/functions_module.' . $phpEx); include($phpbb_root_path . 'includes/functions_template.' . $phpEx); include($phpbb_root_path . 'includes/bbcode.' . $phpEx); include($phpbb_root_path . 'includes/functions_admin.' . $phpEx); include($phpbb_root_path . 'includes/functions_install.' . $phpEx); include($phpbb_root_path . 'includes/functions_posting.' . $phpEx); include($phpbb_root_path . 'includes/functions_transfer.' . $phpEx); include($phpbb_root_path . 'includes/message_parser.' . $phpEx); include($phpbb_root_path . 'includes/auth/auth_apache.' . $phpEx); include($phpbb_root_path . 'includes/auth/auth_db.' . $phpEx); include($phpbb_root_path . 'includes/auth/auth_ldap.' . $phpEx); include($phpbb_root_path . 'includes/captcha/captcha_gd.' . $phpEx); include($phpbb_root_path . 'includes/diff/diff.' . $phpEx); include($phpbb_root_path . 'includes/diff/engine.' . $phpEx); include($phpbb_root_path . 'includes/diff/renderer.' . $phpEx); include($phpbb_root_path . 'includes/utf/utf_normalizer.' . $phpEx); include($phpbb_root_path . 'includes/utf/data/utf_normalizer_common.' . $phpEx); mysql_connect("localhost", "", ""); mysql_select_db("tbsites_forum"); $max = 10; $forum_id = 14; $prefix = 'phpbb_'; $sql = mysql_query(" SELECT * FROM ".$prefix."posts WHERE forum_id = ".$forum_id." LIMIT 0,".$max) OR DIE (" Er is een mysql-fout opgetreden in sql:<br /> <font color=\"red\">".mysql_error()."</font>"); while($row = mysql_fetch_assoc($sql)) { echo '<h1>'; echo $row['post_subject']; echo '</h1>'; echo '<p>'; echo $row['post_text']; echo '</p>'; echo '<hr>'; } ?>
Wijziging: voor de duidenlijkhijd:
ik wil dus $row['post_text'] laten parsen door de phpbb ubb de output van deze code kun je vinden op: http://tbsites.nl/includes/php/nieuws.php
ik wil dus $row['post_text'] laten parsen door de phpbb ubb de output van deze code kun je vinden op: http://tbsites.nl/includes/php/nieuws.php