mam taki kod:
  1. <?php 
  2. define('IN_PHPBB', true); 
  3. $phpbb_root_path = './forum/'; 
  4. include($phpbb_root_path . 'extension.inc'); 
  5. include($phpbb_root_path . 'common.'.$phpEx); 
  6. include($phpbb_root_path . 'includes/bbcode.'.$phpEx); 
  7.  
  8. $sql = 'SELECT 
  9. t.topic_id, 
  10. t.topic_time, 
  11. t.topic_title, 
  12. pt.post_text, 
  13. u.username, 
  14. u.user_id, 
  15. u.user_rank, 
  16. u.user_posts, 
  17. t.topic_replies, 
  18. pt.bbcode_uid, 
  19. t.forum_id, 
  20. t.topic_poster, 
  21. t.topic_first_post_id, 
  22. t.topic_status, 
  23. pt.post_id, 
  24. p.post_id, 
  25. p.enable_smilies 
  26. FROM 
  27. ' . TOPICS_TABLE . ' AS t, 
  28. ' . USERS_TABLE . ' AS u, 
  29. ' . POSTS_TEXT_TABLE . ' AS pt, 
  30. ' . POSTS_TABLE . ' AS p 
  31. WHERE 
  32. t.forum_id IN (102) AND 
  33. t.topic_time <= ' . time() . ' AND 
  34. t.topic_poster = u.user_id AND 
  35. t.topic_first_post_id = pt.post_id AND 
  36. t.topic_first_post_id = p.post_id AND 
  37. t.topic_status <> 2 
  38. ORDER BY 
  39. t.topic_time DESC'; 
  40. if ($number_of_posts != 0) 
  41. { 
  42. $sql .= 'LIMIT 
  43. 0,10'; 
  44. } 
  45. // 
  46. // query the database 
  47. // 
  48. if(!($result = $db->sql_query($sql))) 
  49. { 
  50. message_die(GENERAL_ERROR, 'Could not query announcements information', '', __LINE__, __FILE__, $sql); 
  51. } 
  52. while($row = $db->sql_fetchrow($result)){ 
  53. $tresc = nl2br(stripslashes($row['post_text'])); 
  54. echo '<div class="title"><SPAN CLASS="cattitle"><b>Tytuł:</b> <a href="forum/'.append_sid('viewtopic.' . $phpEx . '?t=' . $row['topic_id']).'"class="public" >'.$row['topic_title'].'</a></span></div>'; 
  55. echo '<div class="public">dodany '.create_date($board_config['default_dateformat'], $row['topic_time'], $board_config['board_timezone']).' przez <a href="' . append_sid('forum/profile.'.$phpEx.'?mode=viewprofile&amp;u='.$row['user_id'].'') . '">'.$row['username'].'</a>'; 
  56. echo '<br />'.$tresc; 
  57. echo '<br /><a href="forum/'.append_sid('viewtopic.' . $phpEx . '?t=' . $row['topic_id']).'" class="public">Komentarze: [ '.$row['topic_replies'].' ]</a>'; 
  58. echo ' | <a href="'.append_sid('forum/posting.' . $phpEx . '?mode=reply&amp;t=' . $row['topic_id']).'" class="public">Dodaj komentarz</a></div><br />';} 
  59. $db->sql_freeresult($result); 
  60. ?>

ten kod polega na tym ze pisze na forum a pojawia sie na stronie smile.gif

Chciałbym żebyście mi doniego dopisali że chodzi bbcode + że daje np. (img)www.foteka.pl/blablabla(img) i że mam zdjecie pokazane na stronie też a nie tylko link smile.gif

Bardzo prosze o pomoc zrobiłbym to sam ale niestety nie umie sad.gif