Linux °æ (¾«»ªÇø)
·¢ÐÅÈË: tcpip (°³µÄêdzƸÄÁË), ÐÅÇø: Linux
±ê Ìâ: php·ÃÎÊsybaseÒ»Àý
·¢ÐÅÕ¾: ×Ï ¶¡ Ïã (Fri Oct 22 15:08:57 1999), תÐÅ
ÎÒ±àÒëPHP3ʱ¼ÓÈëÁËSybaseÖ§³Ö£¬µ«ÊÇ£¬ÎÒ²»ÖªµÀÈçºÎʹÓá£
¼ÓÈëÎÒµÄSybaseµÄÐÅÏ¢ÈçÏ£º
ip: 10.1.1.1
servername: sybase.temp.com
port: 5000
saµÄÃÜÂë:123
ÆäÖÐÓÐÊý¾Ý¿â£ºdbtemp
ÆäÖÐÓÐ±í£ºtabletemp
ÇëÎÊ£¬ÈçºÎ±àдһ¶Î³ÌÐòÀ´·ÃÎÊtabletemp£¿
лл´ó¼Ò£¡
ÕâÀïÊÇÒ»¸öÀý×Ó:
<!DOCTYPE HTMLPUBLIC "-//W3C//DTD HTML 3.2//EN">
<html>
<head>
<title>This PHP3 Example!</title>
</head>
<boby>
<center>
ThisPHP3Example!Connect to SYBASE!<br>
<table col=4 border=5 >
<tr><th bgcolor="#00DDDD" width="150">±à/th>
<th bgcolor="#00DDDD"width="150">Àà ÐÍ</th>
<th bgcolor="#00DDDD"width="100">¼Û ¸ñ</th>
</tr>
<?
sybase_connect("SYBASE","sa","123");
sybase_select_db("pubs2");
$result=sybase_query("select title_id,type,price from titles");
while ($row=sybase_fetch_row($result)){
printf("<tr><td bgcolor='#DDDDDD'>%s</td>",$row[0]);
printf("<td bgcolor='#DDDDDD'>%s</td>",$row[1]);
printf("<td bgcolor='#DDDDDD'>%10.2f</td>",$row[2]);
cho("</tr><br>");
sybase_close();
?>
</table>
</center>
</boby>
</html>
--
"Õâһǧ¶àÄêûдʫÁË?"
"дÁË, ²»¹ýֻдÁËÁ½¾ä."
"ǧÄêµÃÁ½¾ä, Ò»¶¨ÊÇÍò¹ÅÀö¾äÁË. ÄîÀ´ÌýÌý."
"ºÃ°É, ÎÒÏÖ³óÁË" Ì«°×ÐÇÇåÁËÇåɤ×Ó, »ëºñµÄÄÐÖÐÒôÔÚÌìÍ¥ÏìÆð:
´óº£°¡, ¶¼ÊÇË®;
¿¥Âí°¡, ËÄÌõÍÈ;
¡ù ÐÞ¸Ä:£®tcpip ÓÚ Oct 22 15:11:34 Ð޸ı¾ÎÄ£®[FROM: mtmail.hit.edu.c]
¡ù À´Ô´:£®×Ï ¶¡ Ïã bbs.hit.edu.cn£®[FROM: mtmail.hit.edu.c]
Powered by KBS BBS 2.0 (http://dev.kcn.cn)
Ò³ÃæÖ´ÐÐʱ¼ä£º2.983ºÁÃë