אשכול: בעיה בפקודה
View Single Post
ישן 09-10-05, 22:17   # 2
HaMashiah
חבר בקהילה
 
מיני פרופיל
תאריך הצטרפות: Oct 2005
מיקום: עכו סיטי!
גיל: 35
הודעות: 230
שלח הודעה באמצעות ICO אל HaMashiah

HaMashiah לא מחובר  

תנסה את זה:
PHP קוד:
<?php
$host
="localhost"
$user="ali_user"
$password="password"
$db="ali_base";
$table="ali_base"//your default table/course name
mysql_connect("$host","$user","$pass"); 
mysql_select_db("$db"); 
or die(
"<BR><BR><B>ERROR:</B> cannot connect to MySQL server.<BR>");/* במקרה של כשלון בנסיון ההתחברות,
הסקריפט ידפיס הודעת שגיאה והתוכנית תעצר. */ 
$query mysql_query("insert into gb(fild1,fild2,fild3]) values('123','234','345')")
or die(
"<BR><BR><B>ERROR:</B> problem.<BR>");
$select_query "mysql_query(select * from table) or die(mysql_error())";
while(@(
$query mysql_fetch_array($select_query))) {
$fild1 $query[fild1];
$fild2 $query[fild2];
$fild3 $query[fild3];
echo 
"&eth;&uacute;&aring;&eth;&eacute;&iacute;<br><BR> ";
echo 
"$fild1";
echo 
"<br>";
echo 
"$fild2";
echo 
"<br>";
echo 
"$fild3";
}
echo 
"<BR><BR>";

?>
  Reply With Quote