Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Sidebars & Widgets (http://forum.bytesforall.com/forumdisplay.php?f=14)
-   -   [SOLVED] Extra page links (http://forum.bytesforall.com/showthread.php?t=19372)

edlElisabet Jan 18, 2013 03:52 AM

[SOLVED] Extra page links
 
Hi! I want to add some extra links that are only shown on some pages in my site. The links will link to "page pages". I have already added some links like that to another page with menus and then I used Style and configure sidebars and added the pages that I didn't want the menu/links to show in. That worked fine.

Then I tried to add a menu and links to the left inner sidebar so the links didn't conflict with the existing links, but then the links from the inner sidebar keep showing up in the frontpage and other places on the site.

Is there an easier way to do this?

I have latest version of Wordpress and Atahualpa.

Best regards Edle Holmin

juggledad Jan 18, 2013 05:22 AM

I don't understand what you are trying to do. can you supply a detailed example of what you are trying?

edlElisabet Jan 26, 2013 04:21 PM

I'm sorry, I found a solution to the problem by adding some buttons.

But I have another question. I have added this to the css insert:

div.widget ul {
list-style-type: none !important;
}
div.widget a:link,
div.widget a:visited {
border-left: 0 !important;
padding-left: 0 !important;
color: #000000 !important;
text-decoration:none;
}
div.widget a:active {
border-left: 0 !important;
padding-left: 0 !important;
color: #9F153E !important;
text-decoration:none;
}
div.widget ul {
list-style-type: none !important;
}
div.widget a:hover {
color: #9F153E !important;
}

I want the active links to show in a different color in the left sidebar, but it doesnt work. It only shows in black color and I want the visitors to see where their at in the page.

juggledad Jan 26, 2013 06:16 PM

what is the url to the site pointing at an example where it doesn't work?

edlElisabet Jan 27, 2013 12:14 AM

Here is the url: www.fannyholmin.no

In the left siderbar I have some links. I want all of the links, also the sublinks to be red when theire active.

juggledad Jan 27, 2013 05:36 AM

the reason your CSS doesn't work is that there is other CSS that is more specific that is being used.
Use a code inspector like the firebug extension in firefox to see what is being applied

edlElisabet Jan 28, 2013 03:23 AM

Ok, I don't get it to work. I used Firebug and tried out with different css. I tried

a:active
div.widget a:active
div.widget td a:active
div.widget ul li a:active
div.widget_nav_menu ul li a:active
div.widget_nav_menu ul li a:active

Could you see if you see what I should put in the css insert?

juggledad Jan 28, 2013 03:44 AM

try
HTML Code:

div.widget ul li ul li a:active {
    color: #00F000;
}


edlElisabet Jan 28, 2013 01:23 PM

Ok, I tried that, but maybe I have misunderstund what active links are. I want the links to stay in a different color when the visitors is in that page (so they can see what page their in). Here is an example: http://steinmarimusic.com/concerts/

In the horizontal menu bar the links turn green when you are in that page. I would like the same in the sidebar in my other page.

juggledad Jan 28, 2013 02:47 PM

in that case you need to use the 'current_page_item' on the 'li'

You should look at the source of the page and see what classes are added to the different parts of the menu when you click on different pages. It's quite educational

edlElisabet Jan 29, 2013 02:05 AM

Thank you so much, that worked fine. I added this to the CSS insert:

div.widget ul li.current_page_item a, div.widget ul ul li.current_page_item a, div.widget ul ul ul li.current_page_item a {
color: #9F153E;
}

But my only problem now is that I don't get the red color in the subpages. I used this code:

div.widget li.page_item.page-item-40.current_page_item a {
color: #9F153E;
}

But then I have to add this to every subpage and remember to do so every time I make a new subpage. Can you help me with that?

juggledad Jan 29, 2013 04:08 AM

when I click on a subpage it becomes red, so I'm now sure what you are trying to do.

edlElisabet Jan 29, 2013 05:40 AM

Yes, to get the submenu red I added this to the CSS Insert:

div.widget li.page_item.page-item-40.current_page_item a {
color: #9F153E;
}
div.widget li.page_item.page-item-53.current_page_item a {
color: #9F153E;
}
div.widget li.page_item.page-item-35.current_page_item a {
color: #9F153E;
}
div.widget li.page_item.page-item-272.current_page_item a {
color: #9F153E;
}
div.widget li.page_item.page-item-289.current_page_item a {
color: #9F153E;
}
div.widget li.page_item.page-item-235.current_page_item a {
color: #9F153E;
}
div.widget li.page_item.page-item-152.current_page_item a {
color: #9F153E;
}
div.widget li.page_item.page-item-226.current_page_item a {
color: #9F153E;
}
div.widget li.page_item.page-item-257.current_page_item a {
color: #9F153E;
}
div.widget li.page_item.page-item-244.current_page_item a {
color: #9F153E;
}

But then I have to add this code to every new subpage I add. Can I add a code that will work for all the subpages?

juggledad Jan 29, 2013 06:30 AM

sure you can do it that way but you don't need every class so why not try
HTML Code:

div.widget li.current_page_item a {
color: #9F153E;
}


edlElisabet Jan 29, 2013 07:48 AM

Thank you, I got confused with all the code. Now I added
div.widget ul li ul li.current_page_item a {
color: #9F153E;
}
And that worked fine for all the subpages.

Thank you SO much for all your help! :)


All times are GMT -6. The time now is 12:57 AM.

Powered by vBulletin® Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.