Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Page & Category Menu Bars (http://forum.bytesforall.com/forumdisplay.php?f=10)
-   -   [SOLVED] Need some help editing my page menu bar.. (http://forum.bytesforall.com/showthread.php?t=12757)

Carles Feb 11, 2011 09:29 AM

[SOLVED] Need some help editing my page menu bar..
 
Hi!

I got stuck with this problem...I want one of the items of my page menu bar to be floating to the right...but i cannot find the way to do it.

I found the way to edit the hole at once menu using CSS in CSS Inserts, but what i need is to edit only one of the items and i cannot find the id of the items to, then, be able to edit only the one i want.

Can someone help me with this? Where can i find the items id?

tnx in advance! :)

runnerb0y Feb 11, 2011 10:21 AM

If you use Firefox, do yourself a huge favor and install Firebug. Learn how to use that little gem and it will save you literally hundreds of hours in developing sites.

In the case of the Page Menu items, they will be identified something like the following...(I'm using ATA 3.6.4, earlier versions may have a slightly different identification.

Code:

<li class="page_item page-item-2">
Obviously the one you're trying to affect could be numbered differently

Carles Feb 11, 2011 10:34 AM

First of all tnx for the fast reply!

I already did that, and i already know how firebug works...it is really amazing! and i already did that but when I tried to edit that class in CSS Inserts, in ATO, it didn't work, i don't know why...i thought that was not the right id...:S

Any idea which can be the problem?

tnx!

juggledad Feb 11, 2011 10:41 AM

you may have to add an !important' if there is another CSS selector that takes more precedence over the one you are entering.

Carles Feb 11, 2011 10:48 AM

Tried that too... :( and still not working.

I go to ATO, Add HTML/CSS Inserts, and then i write down this code:

.page_item page-item-910{
float:right !important;
}

but it doesn't work. I've tried also changing the margin or the width and height...to check the problem was not on trying to make it float on the right but non of this options work... :S

tnx again for replying that fast :)

juggledad Feb 11, 2011 10:54 AM

Page-item-910 is a class so it needs a leading period

Carles Feb 11, 2011 10:58 AM

Srry i don't know what you mean with a leading period... :S

if you mean that the code should be like this:

div#menu1 ul.rMenu li.page_item page-item-910{
float:right !important;
}

it doesn't work either...but as I said, i don't know what is a leading period

juggledad Feb 11, 2011 11:51 AM

You need a period('.') like this
HTML Code:

div#menu1 ul.rMenu li.page_item .page-item-910 {
float:right;
}


Carles Feb 11, 2011 11:56 AM

Well it had a period like that already, i just didnt know the name it has in english..:p

Anyway, I sopy pasted your code and still not working...don't know what to do or try anymore..:S

tnx for all the help! :)

juggledad Feb 11, 2011 12:10 PM

what version of Atahualpa and what is the url?
In 3.6.4 there in now a <span>...</span> surrounding the menu text. You could add padding-left to that item like
HTML Code:

li.page-item-910 a span  {
padding-left:30px;
}


Carles Feb 11, 2011 12:33 PM

I have Atahualpa 3.4.9 and the url is: www.wpprova1.com

What i want is to move the item called "zona privada" to the right as i explained before.

Also i tried your code, and just copy pasting it into CSS Inserts it doesn't work. I don't know if i had to create that <span></span> before to make it work, but as I understood it comes with the new version which I cdon't have.

tnx for the time you're spending in this!

juggledad Feb 11, 2011 02:24 PM

if you want to try retro fitting this, here is the original write-up I was going to do, but I just added it to the code instead. The line numbers are based on 3.5.3 so they might not be right for 3.4.9
HTML Code:

To add <span>...</span> before and after the menu link text do the following

version 3.5.4
1) edit bfa_new_wp3_menus.php
2) find lines 26-32 which should be

        wp_nav_menu( array(
                'theme_location' => $theme_location,
                'container' => 'div',
                'container_id' => $theme_location,
                'menu_class' => $menu_class,
                'menu_id' => $menu_id
                ) );

and change them to

        wp_nav_menu( array(
                'theme_location' => $theme_location,
                'container' => 'div',
                'container_id' => $theme_location,
                'menu_class' => $menu_class,
                'menu_id' => $menu_id,
                'link_before' => '<span>',
                'link_after' => '</span>'
                ) );


3) edit bfa_hor_pages.php
4 find lines 6-7 which should be

        $list_pages_string = wp_list_pages('sort_column=' . $sort_order . '&title_li=&depth=' . $levels . '&exclude=' . trim(str_replace(" ", "",
        $exclude)) . '&echo=0');

and change them to

        $list_pages_string = wp_list_pages('sort_column=' . $sort_order . '&title_li=&depth=' . $levels . '&exclude=' . trim(str_replace(" ", "",
        $exclude)) . '&echo=0&link_before=<span>&link_after=</span>');

that should do it for you...at least it should put the <span> in, I don't know it it will fix your issue.

runnerb0y Feb 11, 2011 02:30 PM

Try this... I believe it will work.

Code:

div#menu1 ul.rMenu li.page-item-910 {
float:right;
}


Carles Feb 12, 2011 04:21 AM

woow! runnerb0y is right, the solution was much easier than what we were going...we just had a mistake in the class name. using the code he sent in the last messege it works, so problem solved!

thanks to all of you to spend your time trying to help me, i was quite lost :)


All times are GMT -6. The time now is 02:50 AM.

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