![]() |
|
#11
|
|||
|
|||
|
yea even from a design point of view its pointless, because it doesn't matter. it already knows which link is active by default, hence a:active. all you have to do is slap that in your css and you're golden.
__________________
Unlimited Web Hosting If i actually managed to help you in any way, please +rep me! |
|
#12
|
|||
|
|||
|
Explain yourself
why from a design point of view is it worthless. how will it know by default which link is active by default? you are talking about something totally different, you are talking about pseudo-class not a class or id, which can't do which I posted, which changes the style of the link, which a:active will not do You keep posting but don't offer better alternatives, if you have better, then post it. I read a post by yourself, where you told someone to take php from there sig, if being superior helps you feel big, fine, but without explaining yourself you're here and what you said to that person I feel you coming across to me personally not very good. If you care to show me you better way, then please go aheard, you are more then welcome Last edited by websprite; 08-23-2009 at 05:16 PM. |
|
#13
|
||||
|
||||
|
PHP Code:
__________________
. Did I help you in any way? Please return the favor. Please remember to use [php] [html] or [code] tags when appropriate. |
|
#14
|
|||
|
|||
|
Quote:
I will request this thread to be deleted to make you all happy. |
|
#15
|
||||
|
||||
|
PHP Code:
__________________
. Did I help you in any way? Please return the favor. Please remember to use [php] [html] or [code] tags when appropriate. |
|
#16
|
||||
|
||||
|
All you need is an array containing the page names.
eg: PHP Code:
I'm sorry that this thread has turned into a flame thread but the following has to be said: There is no point in getting upset/angry at people for criticising your post. Maybe someone will find it useful, maybe not. Maybe someone can tell you how to make it better or maybe someone will tell you that your doing it wrong. Either way this is a public forum and that being so anything posted here is open to criticism.
__________________
Ben/19/PHP, MySQL, HTML, CSS, Javascript (+ Ajax), c, C#, c++, Dot, `~_~` Don't forget to ++rep (Thanks!) If you wish to have a rapid reply email me by clicking my name and selecting "Send email to..." or by downloading the vCard on my profile under "Contact Info" |
|
#17
|
||||
|
||||
|
Great Tutorial.
I will be using this on my new website. |
|
#18
|
|||
|
|||
|
Menu Current Pages
Am wondering what the shorter way to indicate the current page is, as hinted at by richei:
"So basically, you have a whole lot of code that really does nothing other than take up space. all that code can be taken down to 1 link <a href="index.php?page=page1&id=active">Page one</a></li> no php needed in the link, no complicated functions to troubleshoot. put some if statements or a switch on the index page to tell what to include and you have yourself a php menu." Can you give a fuller example, keeping in mind the lesser abilities and knowledge of others? Thanks. George |
|
#19
|
|||
|
|||
|
you'll still need the php on the other pages to tell it what to do with id=active, otherwise its really of no use, and it doesn't really help, since you don't have a way of telling that the other pages aren't active.
but still, you don't need php to tell it which links are active or not, css already does it for you with a:active. #menu a:active { text-dectoration: none; color: red; } changes any active link in the menu to red. very easy to use, no php is needed.
__________________
Unlimited Web Hosting If i actually managed to help you in any way, please +rep me! |
![]() |
| Thread Tools | |
| Display Modes | |
|
|