]*?>.*?'si", "'<[\/\!]*?[^<>]*?>'si", // Strip out html tags "'([\r\n])[\s]+'", // Strip out white space "'&(quot|#34);'i", // Replace html entities "'&(amp|#38);'i", "'&(lt|#60);'i", "'&(gt|#62);'i", "'&(nbsp|#160);'i", "'&(iexcl|#161);'i", "'&(cent|#162);'i", "'&(pound|#163);'i", "'&(copy|#169);'i", "'&#(\d+);'e"); // evaluate as php $replace = array ("", "", "\\1", "\"", "&", "<", ">", " ", chr(161), chr(162), chr(163), chr(169), "chr(\\1)"); $text = preg_replace ($search, $replace, $Note); $text = eregi_replace ( " " , " ", $text ) ; $text = eregi_replace ( " " , " ", $text ) ; $text = eregi_replace ( " " , " ", $text ) ; } mysql_close(); mysql_connect($host,$user,$passwd); $sql1="UPDATE webboard_data SET pageview=pageview+1 WHERE id='$id'"; $result1 = mysql_db_query($dbname,$sql1); mysql_close(); $rankfile="rank/$picfolder.php"; if (file_exists($rankfile)==1){ include("rank/$picfolder.php");} ?> <? echo $Question; ?> : [ สำหรับสั่งพิมพ์ ]


0){ mysql_connect($host,$user,$passwd); $s1 = "select f.*,m.id as meid ,m.ICQ as ICQ,m.WebName as WebName,m.URL as URL,m.icons as icons,m.msn as msn,m.level as level,m.post as post,m.photo as photo,m.sig as sig,m.levelname as levelname from webboard_ans f,webboard_member m where f.QuestionNo='$id' and f.commid = m.id order by f.No $order"; $r1 = mysql_db_query($dbname,$s1) or die ("ไม่สามารถสั่งให้ database ทำงานได้ในขณะนี้"); $i=1; while ($rows = mysql_fetch_array($r1)) { $QuestionNo = $rows["No"]; $Name1 = $rows["Name"]; $Namer1 = $rows["Namer"]; $Member1 = $rows["Member"]; $Msg = $rows["Msg"]; $Date1 = $rows["Date"]; $nphoto1 = $rows["nphoto"]; $tphoto1 = $rows["tphoto"]; $picture1="photo/$picfolder/$nphoto1"; $No_com = $rows["No_com"]; $tdate1 = $rows["tdate"]; $id1 = $rows["id"]; $banip1=$rows["IP"]; $IP1 = "[".substr($rows["IP"],0,strrpos($rows["IP"],".")).".*]"; $ICQ1 = $rows["ICQ"]; $WebName1 = $rows["WebName"]; $URL1 = $rows["URL"]; $User1 = $rows["User"]; $Email1 = $rows["Email"]; $icons1 = $rows["icons"]; $msn1 = $rows["msn"]; $photo1 = $rows["photo"]; $level1 = $rows["level"]; $numpost1= $rows["post"]; $memid1= $row["meid"]; $signature1=$rows["sig"]; $levelname1=$rows["levelname"]; $search = array ("']*?>.*?'si", "'<[\/\!]*?[^<>]*?>'si", // Strip out html tags "'([\r\n])[\s]+'", // Strip out white space "'&(quot|#34);'i", // Replace html entities "'&(amp|#38);'i", "'&(lt|#60);'i", "'&(gt|#62);'i", "'&(nbsp|#160);'i", "'&(iexcl|#161);'i", "'&(cent|#162);'i", "'&(pound|#163);'i", "'&(copy|#169);'i", "'&#(\d+);'e"); // evaluate as php $replace = array ("", "", "\\1", "\"", "&", "<", ">", " ", chr(161), chr(162), chr(163), chr(169), "chr(\\1)"); $text1 = preg_replace ($search, $replace, $Msg); $text1 = eregi_replace ( " " , " ", $text1 ) ; $text1 = eregi_replace ( " " , " ", $text1 ) ; $text1 = eregi_replace ( " " , " ", $text1 ) ; include ("template/print/oldreply.php"); $i++; } @mysql_close(); } ?>