Hi All,
Here is a better explanation:
Menu Table structure
id description parent_id
1 Soccer 0
2 England 1
3 Arsenal 2
4 United 2
5 Germany 1
6 Bayern 5
7 Italy 1
8 Milan 7
9 Palermo 7
10 Inter 7
11 Liverpool 2
I need a way to list the menu hierarchy when i only have the child available.
For example if i have the description 'Milan' with parent_id 7, how can i go through all the parent ids to find the main parent which is soccer and display accordingly ?
Soccer (parent_id = 0) >> Italy (parent_id = 1) >> Milan (parent_id = 7 )
Hope this explains what i need help with a bit clearer as i am completely lost.
Thanks in advance.
//DK
Hi,
This is what i would do.
Hope this makes sens to you ?
talents ( talent_id , talent_firstname, talent_lastname) -- 1 row
movies (movie_id, movie_description, movie_year) -- 1 row
castings (casting_id , talent_id , movie_id) -- multiple rows
Regards,
Rob.
Hi, sorry for the vague reply.
First off, I already have a horizontal left menu that is up and functioning correctly.
However when i click on Milan i would like to include the "menu path" in the page i am redirected to.
Football >> Europe >> Italy > Milan
Something like this http://www.oddsportal.com/soccer/germany/bundesliga/.
Soccer» Germany»Bundesliga
Hi Guys & Gals!!
Hope you are all ok....
I need some help with the following
I need to trim the following word as follows:
$word = 'James Bond';
output would be 'James B'
There is a space between all of the words I need to trim...
Any suggestion??
Thanks in advance..
Hi Everyone,
I am stuck , and would like some inspiration
I am trying this sql but not getting the correct result.
case when max(price) and product_order = 1 then shelf_id end
What i need is the shelf_id of the book with the highest price and has a product order of 1.
p.S this is just a small part of the query....
I have really run out of ideas, so any tips would be greatly appreciated.
Thanks in advance.
//DK
Hi joel24 and waynewex thanks for your replies , it was so simple, i was tearing my hair out over this.
Problem solved now.
Great stuff , thanks again guys !!
i everyone,
I have run into a problem and need your help.
I am running a query and displaying the results into a table through php. This is a sample output.
Date Cars
6/13/2009 6:30:00 PM Ferrari
6/13/2009 6:30:00 PM Subaru
6/13/2009 8:00:00 PM Toyota
6/13/2009 8:00:00 PM Opel
6/14/2009 5:00:00 PM Ford
6/14/2009 6:00:00 PM Hyundai
6/14/2009 6:00:00 PM Fiat
6/15/2009 9:00:00 PM BMW
However i would now like to split and group the results up by date to something like this
Date Cars Sum(cars)
6/13/2009 6:30:00 PM Ferrari 76
6/13/2009 6:30:00 PM Subaru 67
6/13/2009 8:00:00 PM Toyota 6
6/13/2009 8:00:00 PM Opel 98
--New Table
6/14/2009 5:00:00 PM Ford 65
6/14/2009 6:00:00 PM Hyundai 65
6/14/2009 6:00:00 PM Fiat 65
--New Table
6/15/2009 9:00:00 PM BMW 4
Any input would be greatly appreciated as i have run out of ideas ???
Thanks in advance!!
We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.