Yet another menu system
Posted: Mon Jul 25, 2005 11:02 pm
Ok this is a simple hack but it dosen't have redraw problems with Flash backgrounds - See (http://forum.cmsmadesimple.org/index.ph ... 310.0.html)
";
$db_host = "localhost";
$db_user = "cms_user";
$db_pass = "Yourpassword";
$db_name = "cms";
$db = mysql_connect($db_host,$db_user,$db_pass);
mysql_select_db ($db_name) or die ("Cannot connect to database");
$result = mysql_query("select menu_text from cms_content");
$total = mysql_num_rows($result);
while ($myrow = mysql_fetch_array($result))
{
echo "";
echo $myrow["menu_text"];
}
echo "";
mysql_close($db);
?>
______End code
Ah!
If I create a user defined tag
insert this
echo "";
$result = mysql_query("select menu_text from cms_content");
$total = mysql_num_rows($result);
while ($myrow = mysql_fetch_array($result))
{
echo "";
echo $myrow["menu_text"];
}
echo "";
Wohla!
I can see an adiction developing!
";
$db_host = "localhost";
$db_user = "cms_user";
$db_pass = "Yourpassword";
$db_name = "cms";
$db = mysql_connect($db_host,$db_user,$db_pass);
mysql_select_db ($db_name) or die ("Cannot connect to database");
$result = mysql_query("select menu_text from cms_content");
$total = mysql_num_rows($result);
while ($myrow = mysql_fetch_array($result))
{
echo "";
echo $myrow["menu_text"];
}
echo "";
mysql_close($db);
?>
______End code
Ah!
If I create a user defined tag
insert this
echo "";
$result = mysql_query("select menu_text from cms_content");
$total = mysql_num_rows($result);
while ($myrow = mysql_fetch_array($result))
{
echo "";
echo $myrow["menu_text"];
}
echo "";
Wohla!
I can see an adiction developing!