videomontaj.com adlı üyeden alıntı: mesajı görüntüle
Arkadaşlar vbulletin olan sitemin de www.sitem.com/sorular.php şeklinde bir harici sayfa oluşturdum. şimdi sorular katagorisinde ki son konuları sorular.php olan harici sayfama çekmek istiyorum. bunu nasil yapabilirim?
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:fb="http://www.facebook.com/2008/fbml" dir="ltr" lang="tr" id="vbulletin_html">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-9" />
<link rel="Shortcut Icon" href="http://www.sitedı.com/favicon.ico" type="image/x-icon" />

<meta name="keywords" content="****" />
<meta name="description" content="***" />



<body onmouseover=clearInterval(scrollInterval) onmouseout=runScroller() 
text=#7B4B1B vLink=#7B4B1B aLink=#7B4B1B link=#7B4B1B bgColor=#313131
centerMargin=0 topMargin=0 onload=runScroller() marginheight="0" 
marginwidth="0" style="background-image: url('')">


<font color="#7B4B1B">
<?

$db_host = "localhost"; 
$db_name = "veritabanı"; 
$db_user = "kullanıcı"; 
$db_pw = "şifre";

$forum_url = "http://sitedı.com"; 
$forum_id = "20"; //hangi forumdan çekmek istersen id girin
$limit = "5"; //kaç adet mesaj çekilsin? numara girin.
$titlecolor = "#FFFFFF"; 
$postedcolor = "#999999"; 
$txtlimit = "48"; 
#######################################

// Connecting to your database
mysql_connect($db_host, $db_user, $db_pw)
OR die ("Cannot connect to your database");
mysql_select_db($db_name) OR die("Cannot connect to your database");

// Below is the beginning of a table. If you feel you don't need it, you may remove it.



echo "<table border=\"0\" width=\"55%\" align=\"center\" cellspacing=\"0\" cellpadding=\"2\" bgcolor=\"\"><tr>";

if ($forum_id) {
$forumid = "AND forumid=$forum_id";
}

if ($limit) {
$limited = "LIMIT $limit";
}
$thread_sql = mysql_query("SELECT threadid,title,lastpost,lastposter FROM thread WHERE visible=1 AND open=1 $forumid ORDER BY lastpost DESC $limited");

while($thread_get=mysql_fetch_array($thread_sql))
{
$lastpost = $thread_get['lastpost'];
$poster = $thread_get['lastposter'];
$tid = $thread_get['threadid'];
$psql = mysql_query("SELECT postid FROM post WHERE threadid=$tid ORDER BY postid DESC");
$getp=mysql_fetch_array($psql);
$pid = $getp['postid'];
$date2 = date ("d/m/y H:i" ,$lastpost);   
$time = date ("H:i" ,$lastpost);               
$title = $thread_get['title'];
$title = substr($title,0,$txtlimit);
  
echo "



<font size=\"2\" face=\"verdana,arial,geneva\">
<a href=\"$forum_url/showthread.php?p=$pid#post$pid\" target=\"_blank\">
<FONT SIZE=\"2\" COLOR=\"$titlecolor\" face=\"verdana,arial,geneva\">$title</FONT></a>
</font> 

<br />

<font color=\"$postedcolor\" face=\"verdana\" size='2'>Yazan: $poster - $time </FONT>
<br />
</td>
</tr>


";

}

echo "</table>";



?>

</font>




</body>
</html>
işinizi görür...