Hi
I'm rather new at php/mysql and I have a problem that has me stumped.
I setup a simple database to run a site off of, Basically each page has a name, text, title, text for the navbar (linktext) and something to keep them in the wanted order (linkpriority) Everything else runs smoothly until I try to get the links to display in my little navbar section.
I have this at the beginning.
include("includes/mySql.php");
connect_mySql('votfcouk_cms');
$get = select_query_mySql("*", "votf_cms", "page", $page);
$info = mysql_fetch_assoc($get);
$pagelist = "select page, linktext, linkpriority from votf_cms order by linkpriority";
$pagelist_res = mysql_query($pagelist,$conn) or die(mysql_error());
$pagelist_array = mysql_fetch_array($pagelist_res);
And this where I tried to put the navbar.
foreach ($pagelist_array as $pagelist_array['page'] => $value) {
echo ("<a href=\"idx.php?page=".$value['page']."\" class=\"link\">".$value['linktext']."</a><br>"); }
Odds are its something simple that I forgot to do but I'm stumped.
If anyone has any ideas as to how I could fix it it would be appreciated. 🙂
Thanks!