בעיה אחרי שהכנסתי בדיקה קטנה...
שלום...
הכנסתי את הקוד הבא:
PHP קוד:
$s2 = mysql_query("SELECT * FROM `global` WHERE `id`=1") or die(mysql_error()); $s2 = mysql_fetch_assoc($s2);
if($s2['sact'] == 0) { echo <<<EOB <!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" dir="rtl">
<head> <meta http-equiv="Content-Type" content="text/html; charset=windows-1255"> <title>האתר מכובה</title> </head>
<body> <div align="center" class="off"> <div style="width: 600px; height: 400px; border-width: 1px; border-style: solid; border-color: #A5ACB2;"> <div align="left"> <img src="images/top_01.gif" border="0" width="270" height="74" /> </div> <div align="center"> המערכת מכובה </div> </div> </div> </body>
</html> EOB; exit; }
לקובץ אחד וזה נראה ככה:
PHP קוד:
<? if (!defined ("PHP_FILE")) { header("Location:index.php"); exit; }
mysql_connect("localhost","thegod_db1","dbdbdb") or die(mysql_error()); mysql_select_db("thegod_db1") or die(mysql_error());
#################################
class skin {
function content($cont,$title) { echo <<<EOB <table id="Table_01" width="742" border="0" cellpadding="0" cellspacing="0"> <tr> <td colspan="2"> <img id="cont_01" src="images/cont_01.gif" width="742" height="1" alt="" /></td> </tr> <tr> <td> <img id="cont_02" src="images/cont_02.gif" width="449" height="20" alt="" /></td> <td style="background: url('images/cont_03.gif');" width="293" height="20" class="trBlack" align="right" dir="rtl"><div style="margin-right: 5px;">$title</div></td> </tr> <tr> <td colspan="2"> <img id="cont_04" src="images/cont_04.gif" width="742" height="10" alt="" /></td> </tr> <tr> <td colspan="2"><div class="trNormal">$cont</div></td> </tr> <tr> <td colspan="2"> <img id="cont_06" src="images/cont_06.gif" width="742" height="12" alt="" /></td> </tr> </table> EOB; }
#################################
function foot() { echo <<<EOB <table width="742" border="0" cellpadding="0" cellspacing="0"> <tr> <td colspan="5"> <img src="images/bottom_02.gif" width="742" height="26" alt="" /></td> </tr> <tr> <td><img src="images/bottom_03.gif" width="11" height="20" alt="" /></td> <td style="background: url('images/bottom_04.gif'); text-align: left;" width="135" height="20" class="trBlack"><a href="mailto:dreamd@bezeqint.net">DreaMonsteR Design</a></td> <td><img src="images/bottom_05.gif" width="414" height="20" alt="" /></td> <td style="background: url('images/bottom_06.gif'); text-align: right; direction: rtl;" width="171" height="20" class="trBlack">כל הזכויות שמורות ל-InterGame</td> <td><img src="images/bottom_07.gif" width="11" height="20" alt="" /></td> </tr> <tr> <td colspan="5" width="742" height="4"></td> </tr> </table> </div>
</body>
</html> EOB; }
#################################
function head() { $s1 = mysql_query("SELECT * FROM `global` WHERE `id`=1") or die(mysql_error()); $s1 = mysql_fetch_assoc($s1); $title = $s1['sname']; echo <<<EOB <!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">
<head> <title>$title</title> <meta http-equiv="Content-Type" content="text/html; charset=windows-1255" /> <style type="text/css"> @import url(style1.css); </style> </head>
<body>
<div align="center"> <table width="742" border="0" cellpadding="0" cellspacing="0"> <tr> <td rowspan="3"><img src="images/top_01.gif" width="270" height="74" alt="LetsPlay - בואו לשחק אתנו!" border="0" /></td> <td width="468" height="7"></td> <td rowspan="3" width="4" height="74"></td> </tr> <tr> <td> EOB; adv1(); echo <<<EOB </td> </tr> <tr> <td width="468" height="7"></td> </tr> <tr> <td colspan="3" style="background: url('images/top_06.gif');" width="742" height="20"> <div class="tMenu"> EOB; if(!$_COOKIE['membersU']) { echo '<div style="float: right; text-align: right; width: 35%;">ברוך הבא, <b>אורח</b> ( <b><a href="login.php">התחבר</a></b> | <b><a href="register.php">הירשם</a></b> )</div>'; } else { $Cid = $_COOKIE['membersU']; $u1 = mysql_query("SELECT * FROM `members` WHERE `id`='$Cid'") or die(mysql_error()); $u1 = mysql_fetch_assoc($u1); echo '<div style="float: right; text-align: right; width: 35%;">ברוך הבא, <b>'.$u1['user'].'</b> ( <b><a href="logout.php">התנתק</a></b> | <b><a href="cpanel.php">לוח הבקרה</a></b> )</div>'; } echo <<<EOB <div style="float: right; text-align: left; width: 65%;"><b><a href="index.php">עמוד ראשי</a></b> · <a href="downloads.php">הורדות</a> · <a href="articles.php">כתבות</a> · <a href="cheats.php">טיפים וצ'יטים</a> · <a href="forum" target="_blank"><b>פורומים</b></a> · <a href="contact.php">צרו-קשר</a> · <a href="team.php">צוות האתר</a> · <b><a href="adver.php">פרסם באתר</a></b></div> </div> </td> </tr> <tr> <td colspan="3"><img src="images/top_07.gif" width="742" height="26" alt="" /></td> </tr> </table> EOB; }
}
################################
$skin = new skin;
################################
function adv1() { $adv = mysql_query("SELECT * FROM `advertising` WHERE `active`=1 ORDER BY rand()") or die(mysql_error()); $adv = mysql_fetch_assoc($adv); extract($adv); echo '<a href="$usurl" target="_blank"><img src="$uurl" width="468" height="60" alt="" border="0" /></a>'; }
################################
$s2 = mysql_query("SELECT * FROM `global` WHERE `id`=1") or die(mysql_error()); $s2 = mysql_fetch_assoc($s2);
if($s2['sact'] == 0) { echo <<<EOB <!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" dir="rtl">
<head> <meta http-equiv="Content-Type" content="text/html; charset=windows-1255"> <title>האתר מכובה</title> </head>
<body> <div align="center" class="off"> <div style="width: 600px; height: 400px; border-width: 1px; border-style: solid; border-color: #A5ACB2;"> <div align="left"> <img src="images/top_01.gif" border="0" width="270" height="74" /> </div> <div align="center"> המערכת מכובה </div> </div> </div> </body>
</html> EOB; exit; }
################################# ?>
עכשיו אחרי שהכנסתי את זה פתאום הופיעה לי שגיאה שחסר לי משהו...
Parse error: syntax error, unexpected $end in /home/thegod/domains/vlad.web.lsrv.co.il/public_html/let/functions.php on line 184
ושורה 184 בכלל לא קיימת....יש לי רק 179 שורות |Stare|
תודה רבה לכל העוזרים:-D
|