Omiddy
-
Posts
6 -
Joined
-
Last visited
Never
Posts posted by Omiddy
-
-
Hi,
I'm pretty sure that I am complicating thing for something I'm trying to do.
In my database, I have some posts, each with a category field.
what I'm trying to do is have a list of categories with each post that falls in that category listed underneath each category.
ie:
<h3>Category 1</h3> <ul class="nav1"> <li><a href="#">Title of post with category 1</a></li> <li><a href="#">Title of another post with category 1</a></li> <li><a href="#">Title of 3rd post with category 1</a></li> </ul> <h3>Category 2</h3> <ul class="nav1"> <li><a href="#">Title of post with category 2</a></li> <li><a href="#">Title of another post with category 2</a></li> <li><a href="#">Title of 3rd post with category 2</a></li> </ul>
Can someone please tell me what the easiest way to do this is? I've tried different tutorials and methods i could think of, but they overcomplicated things.
any help would be appreciated,
thank you : )
-
yea, i actually dont know why im doing this .. :S
-
I'm trying to have a single web layout and have all the content pulled from the database ..
this way i can make an admin panel and ill be able to edit the content from anywhere .. not sure if its the wisest idea, but its the only one i could come up with ...
:S what do you think?
-
nvm, I got it ...
just used:
<?php eval('?>' . $table. '<?php '); ?>
'
-
Hello,
I'm new to this website so forgive me if I'm posting in the wrong section.
I just need to know if there is a way that I can retrieve php script that is stored in a database?
for example, in my database in table:
<? echo"Hello World"; ?>
and in my php file, I call that using:
<?
mysql_connect("asdas","asdas","asd");
mysql_select_db("asdasda");
$result = mysql_query("select * from somedatabse");
while($r=mysql_fetch_array($result))
{
$table=$r["table"];
}
echo"$table";
?>
i know its confusing, i just hope i made sense and that someone understands what im trying to do.
any help will be appreciatedddd
thank you : )
Categorizing
in PHP Coding Help
Posted
PFMaBiSmAd you are a genious. that is exactly what i needed.
thanks everyone !