Can someone help with this
I have tried putting ; after the last > still does not work though.
Parse error: parse error, unexpected '\"', expecting ',' or ';' in /home/usr/public_html/category.php on line 26
echo "<link href=""\"/base.css\" rel=\"stylesheet\" type=\"text/css\">
Error??
Moderator: General Moderators
- skylavelle
- Forum Newbie
- Posts: 18
- Joined: Sun May 04, 2003 11:33 pm
- Location: Brisbane, Australia
ok that got some of it go here and click a link http://realwebhost.net/category.php
and look at bottom
here is file
and look at bottom
here is file
Code: Select all
<?php
$dbi= mysql_connect('localhost','usr','pass');
mysql_select_db('dbname');
$sql_get_faq_categories1_txt = "select cid,cname from faq_categories1 where cid IN (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24)";
$sql_get_faq_categories1 = mysql_query($sql_get_faq_categories1_txt);
if (!$sql_get_faq_categories1)
die ("Error displaying information. Please report this information to the administrator -- ".$sql_get_faq_categories1_txt . " - " . mysql_error());
while(list($cid,$cname)=mysql_fetch_row($sql_get_faq_categories1))
{
echo "<a href="".$_SERVER['$PHP_SELF']."?cid=$cid">$cname</a><br>";
}
// done topics so now display question if appropriate
if((int)$_REQUEST['cid']>0)
{
$sql_get_faq_questions1_txt = "select fid,cid,question,answer,timestamp from faq_questions1 where cid=$cid";
$sql_get_faq_questions1 = mysql_query($sql_get_faq_questions1_txt);
if (!$sql_get_faq_questions1)
die ("Error displaying information. Please report this information to the administrator -- ".$sql_get_faq_questions1_txt . " - " . mysql_error());
echo "<table cellpadding=0 cellspacing=0 border=0 align=center width=100%>";
while(list($fid,$cid,$question,$answer,$timestamp)=mysql_fetch_row($sql_get_faq_questions1))
{
echo "<link href="/base.css" rel="stylesheet" type="text/css" />
<tr>
<td valign=top>
<table>
<tr>
<td>
Q: $question
</td>
</tr>
</table>
<table cellpadding=0 cellspacing=0 border=0 align=center width=100%>
<tr>
<td valign=top>
<table>
<tr>
<td>
A:$answer
</td>
</tr>
</table>
</td>
</tr>";
}
echo "</table>";
} // end questions
?>note: this thread is related to viewtopic.php?t=8469
It's hard to keep tracks on every post(er) here on this board, jackal
It's hard to keep tracks on every post(er) here on this board, jackal
you're checking $_REQUEST['cid'] which seems to be working but then you use $cid in your querystring. why?if((int)$_REQUEST['cid']>0)
{
$sql_get_faq_questions1_txt = "select fid,cid,question,answer,timestamp from faq_questions1 where cid=$cid";