Re: [PHP] Links hierarchy maintenance
Adil Drissi wrote: should be displayed differently. I was wondering if there is a way to do the same thing without the overhead of all that if statements. If you're using PHP (or any other interpreted language) overhead is a fact of life, there's little you can do about it. /Per Jessen, Zürich -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Links hierarchy maintenance
At 6:13 PM -0700 3/9/08, Adil Drissi wrote: Yes like that, but you can consider also that the vertical menu has different style for the link of the current page. Anyway it does not matter for this problem. Can you show us how your php function looks like? Or maybe you are just doing a test for each link for your function to know if it is the link that should be displayed differently. I was wondering if there is a way to do the same thing without the overhead of all that if statements. Two menus, do you mean like this: http://webbytedd.com/clients/beckyscan/about-company.php No offense meant, but if you're concerned about the if overhead then I question if you would understand how the double menu works. Cheers, tedd -- --- http://sperling.com http://ancientstones.com http://earthstones.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Links hierarchy maintenance
Adil Drissi wrote: Hi, Yes this is the correct way to do things. As i said, i'm using different styles for the menus links indicating the current page. Suppose my page has one horiontal menu at the top and one vertical menu at the left. In this case, one element of the horizontal menu and one from the vertical menu will be displayed differently from the other elements. So the function that will be inluded will be more complex to handle this. I was just wondering, how other poeple are dealing with that. Of course it is feasable, but i want to do it the best way. CSS ? If that's not enough to alter the display, you need to make your includes sensitive to or aware of the context they're being included in. /Per Jessen, Zürich -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Links hierarchy maintenance
Hi Jessen, The question is how to make it aware of the context. Do you know any work dealing with that? Thanks --- Per Jessen [EMAIL PROTECTED] wrote: Adil Drissi wrote: Hi, Yes this is the correct way to do things. As i said, i'm using different styles for the menus links indicating the current page. Suppose my page has one horiontal menu at the top and one vertical menu at the left. In this case, one element of the horizontal menu and one from the vertical menu will be displayed differently from the other elements. So the function that will be inluded will be more complex to handle this. I was just wondering, how other poeple are dealing with that. Of course it is feasable, but i want to do it the best way. CSS ? If that's not enough to alter the display, you need to make your includes sensitive to or aware of the context they're being included in. /Per Jessen, Zürich -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Links hierarchy maintenance
Adil Drissi wrote: Hi Jessen, The question is how to make it aware of the context. Do you know any work dealing with that? Variables? Set a variable $context= before you include, then have your include check on $context. /Per Jessen, Zürich -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Links hierarchy maintenance
Yes this is the correct way to do things. As i said, i'm using different styles for the menus links indicating the current page. Suppose my page has one horiontal menu at the top and one vertical menu at the left. In this case, one element of the horizontal menu and one from the vertical menu will be displayed differently from the other elements. So the function that will be inluded will be more complex to handle this. I was just wondering, how other poeple are dealing with that. Of course it is feasable, but i want to do it the best way. I hope the problem i posted is clearer now Two menus, do you mean like this: http://webbytedd.com/clients/beckyscan/about-company.php It's still just css and php -- simply a logic problem. Cheers, tedd -- --- http://sperling.com http://ancientstones.com http://earthstones.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Links hierarchy maintenance
Yes like that, but you can consider also that the vertical menu has different style for the link of the current page. Anyway it does not matter for this problem. Can you show us how your php function looks like? Or maybe you are just doing a test for each link for your function to know if it is the link that should be displayed differently. I was wondering if there is a way to do the same thing without the overhead of all that if statements. --- tedd [EMAIL PROTECTED] wrote: Yes this is the correct way to do things. As i said, i'm using different styles for the menus links indicating the current page. Suppose my page has one horiontal menu at the top and one vertical menu at the left. In this case, one element of the horizontal menu and one from the vertical menu will be displayed differently from the other elements. So the function that will be inluded will be more complex to handle this. I was just wondering, how other poeple are dealing with that. Of course it is feasable, but i want to do it the best way. I hope the problem i posted is clearer now Two menus, do you mean like this: http://webbytedd.com/clients/beckyscan/about-company.php It's still just css and php -- simply a logic problem. Cheers, tedd -- --- http://sperling.com http://ancientstones.com http://earthstones.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Links hierarchy maintenance
Hi, I'm working on a site that is becoming more and more bigger (containing more links). Now the problem of links maintenance arises. An intuitive idea that i'm trying to do right know is calling php functions that will display every part of the site that is repetitive. For example left side menu and footer. For the left side menu with static HTML and CSS i'm disabling the link to the actual page, like that the user has a visual presentation allowing him to know where he is exaclty in the site. This introduces more difficulty for the function that will display the menu. So i'm wondering if there is some efficient way of modeling and implementing this. All suggestions are welcome, and if some part of the problem is not clear enough please feel free to ask me more questions if necessary. Thanks Looking for last minute shopping deals? Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Links hierarchy maintenance
At 9:23 AM -0800 3/8/08, Adil Drissi wrote: I'm working on a site that is becoming more and more bigger (containing more links). Now the problem of links maintenance arises. An intuitive idea that i'm trying to do right know is calling php functions that will display every part of the site that is repetitive. For example left side menu and footer. For the left side menu with static HTML and CSS i'm disabling the link to the actual page, like that the user has a visual presentation allowing him to know where he is exaclty in the site. This introduces more difficulty for the function that will display the menu. So i'm wondering if there is some efficient way of modeling and implementing this. All suggestions are welcome, and if some part of the problem is not clear enough please feel free to ask me more questions if necessary. In all of my pages, I use includes. I have one include for the header, one for the footer and one for the navigation, which is usually called by the header. If something changes in navigation, I change one file and it's done throughout the site. Look into includes. Cheers, tedd -- --- http://sperling.com http://ancientstones.com http://earthstones.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Links hierarchy maintenance
Hi, Yes this is the correct way to do things. As i said, i'm using different styles for the menus links indicating the current page. Suppose my page has one horiontal menu at the top and one vertical menu at the left. In this case, one element of the horizontal menu and one from the vertical menu will be displayed differently from the other elements. So the function that will be inluded will be more complex to handle this. I was just wondering, how other poeple are dealing with that. Of course it is feasable, but i want to do it the best way. I hope the problem i posted is clearer now --- tedd [EMAIL PROTECTED] wrote: At 9:23 AM -0800 3/8/08, Adil Drissi wrote: I'm working on a site that is becoming more and more bigger (containing more links). Now the problem of links maintenance arises. An intuitive idea that i'm trying to do right know is calling php functions that will display every part of the site that is repetitive. For example left side menu and footer. For the left side menu with static HTML and CSS i'm disabling the link to the actual page, like that the user has a visual presentation allowing him to know where he is exaclty in the site. This introduces more difficulty for the function that will display the menu. So i'm wondering if there is some efficient way of modeling and implementing this. All suggestions are welcome, and if some part of the problem is not clear enough please feel free to ask me more questions if necessary. In all of my pages, I use includes. I have one include for the header, one for the footer and one for the navigation, which is usually called by the header. If something changes in navigation, I change one file and it's done throughout the site. Look into includes. Cheers, tedd -- --- http://sperling.com http://ancientstones.com http://earthstones.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php Never miss a thing. Make Yahoo your home page. http://www.yahoo.com/r/hs -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php