For Programmers: Free Programming Magazines  


Home > Archive > PHP Smarty Templates > August 2005 > multiple nested queries?









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author multiple nested queries?
Amanda Hemmerich

2005-08-08, 5:04 pm

Hello! I'm pretty new to PHP and Smarty.

I am trying to build a dynamic navigation bar using mysql, PHP, and
smarty. I need to get the name and id of each menu item and then for
each item, query a different table and get the sub-items associated with
them.

My normal way of using queries is to query the database and loop through
the result with a smarty section and display the results. Is there a
way I can loop through the results and build another query and then loop
through THOSE results, too?

Thanks,
Amanda
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com