Jump to content

[SOLVED] Need help from someone experienced in phpbb databases


czcore

Recommended Posts

Hi, i have problem with script Id like to use to fill in the databese with topics. It is about 1500 topics, so that is the reason why I need script to do the job.

the skript (without cyklus) is
Code:
[code]include("connect.php");
  $result = mysql_fetch_array(mysql_query("SELECT item_number FROM beacon_1 ORDER BY item_number LIMIT 1"));
  $item_number = $result["item_number"];
  $b = mysql_fetch_array(mysql_query("SELECT item_name FROM items WHERE item_number = $item_number"));
  echo mysql_error();
  $item_name = $b["item_name"];
  echo "$item_name<br>";
  include("connect_forum.php");
  mysql_query("INSERT INTO phpbb_topics (forum_id, topic_title, topic_poster, topic_time, topic_first_post_id, topic_last_post_id) VALUES('1', '$item_name', '2', '1166223682', '$id', '$id')");
  echo mysql_error();
  $id++;
  $eee = mysql_fetch_array(mysql_query("SELECT topic_id FROM phpbb_topics WHERE topic_title = '$item_name'"));
  $topic_id = $eee["topic_id"];
  mysql_query("INSERT INTO phpbb_posts (topic_id, forum_id, poster_id, post_time, poster_ip, enable_bbcode, enable_html, enable_smilies) VALUES('$topic_id', '1', '2', '1166260956', 'd4478357', '1', '0', '1')");
  echo mysql_error();[/code]

in database everythinh seems ok, but on the web page is no content. can you see any problem? thanx a lot

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.