Wordpress Themes - WP Forum at BFA
Click here to register or to donate.
Auto self-registration is not available here - far too many spammers. This forum has many, many backlinks and because of that there is an intense desire among spammers to drop their links here.

Wordpress Themes - WP Forum at BFA » WordPress Themes » Atahualpa 3 Wordpress theme » Plugins & Atahualpa »

[SOLVED] Yoast Breadcrumbs And Page Menu Bar


  #1  
Old Jun 13, 2009, 06:45 PM
fromtheranks
 
149 posts · Apr 2009
Dev Env't: XP Pro SP3, IIS 5.1, MySQL 5.1, PHP 5.2.x, WP 2.7.1, Atahualpa 3.3.3, IE 7, FF 3.0.x
I'm trying to add bread crumbs to my page menu bar. I found http://forum.bytesforall.com/showthr...ght=breadcrumb and have been trying to emulate that logic with the Yoast Breadcrumb plugin: http://yoast.com/wordpress/breadcrumbs/.

I'm doing something wrong or haven't done something else that I should.

It works, sort of, but the Breadcrumbs do a new paragraph, or something at the end of the last page menu tab (in this case "Sitemap"), and it gets worse if I try to move through the pages ... it actually picks up the enter tab (format, borders and all) and inserts them into the bread crumb trail. See the attached images.

The default code from the yoast breadcrumb site is:

Code:
<?php if ( function_exists('yoast_breadcrumb') ) {
	yoast_breadcrumb('<p id="breadcrumbs">','</p>');
} ?>
In the tests below I tried the function with and without the argument as in the above example, and getting rid of the para tags helped, fractionally but that is all. (I also tried it in header.php and it didn't show up.)

I've tried two different styles of code in bfa_header_config (using the above forum link as a "template", and they both result in essentially the same result:

#1 - my code is in red:
Code:
	$page_menu_bar .= bfa_hor_pages($bfa_ata['sorting_page_menu_bar'], $bfa_ata['levels_page_menu_bar'], 
	$bfa_ata['titles_page_menu_bar'], $bfa_ata['exclude_page_menu_bar']);
	if ( function_exists('yoast_breadcrumb')) 
	{
		ob_start(); yoast_breadcrumb(); $yoast_breadcrumb = ob_get_contents(); ob_end_clean();
	}
	$page_menu_bar .= $yoast_breadcrumb;
	$page_menu_bar .= '</ul></div>' . "\n";
	// END of Page Menu Bar
#2 - I also tried this version:
Code:
	if ( function_exists('yoast_breadcrumb'))
	$page_menu_bar .= '<li class="breadcrumbs">You are here $raquo;'; 
	{
		ob_start(); yoast_breadcrumb(); $yoast_breadcrumb = ob_get_contents(); ob_end_clean();
	}
	$page_menu_bar .= $yoast_breadcrumb;
	$page_menu_bar .= '</li></ul></div>' . "\n";
Am I coding something incorrectly. Possible, considering I'm new to PHP and HTML. Or. Am I barking up a dead tree here? ...

Thanks in advance.
Attached Thumbnails
Click image for larger version

Name:	breadcrumb-1.jpg
Views:	754
Size:	14.3 KB
ID:	158  Click image for larger version

Name:	breadcrumb-2.jpg
Views:	764
Size:	16.3 KB
ID:	159  
  #2  
Old Jun 14, 2009, 06:28 PM
fromtheranks
 
149 posts · Apr 2009
Dev Env't: XP Pro SP3, IIS 5.1, MySQL 5.1, PHP 5.2.x, WP 2.7.1, Atahualpa 3.3.3, IE 7, FF 3.0.x
Hi.

Has anyone successfully added a Breadcrumb plugin to their Page Menu Bar? See my two attempts below.

The reason I'd like to use the page menu bar is that it isn't terribly full and I'd like to not add another row of stuff to the header area.

Thanks in advance.
  #3  
Old Jun 14, 2009, 07:26 PM
juggledad's Avatar
juggledad
 
23,667 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
I just played with this for a while and came up with the same results as you did. the problem is that Yoast Breadcrumb is creating text mixed with several <a...> and they are in an unordered list. While you could use the Yoast prefix and suffix to make this a list, the styling that's already applied to the list is causing what you see.

If you wanted this on a seperate line from the menu, it is easy, just put the code at the end like this
HTML Code:
	$page_menu_bar .= '</ul></div>' . "\n";

	if ( function_exists('yoast_breadcrumb') ) 
		{
		$page_menu_bar .=  yoast_breadcrumb("", "\n", false); 
		} 
	// END of Page Menu Bar 
__________________
"Tell me and I forget, teach me and I may remember, involve me and I learn." - Benjamin Franklin
Juggledad | Forum Moderator/Support
  #4  
Old Jun 14, 2009, 07:53 PM
fromtheranks
 
149 posts · Apr 2009
Dev Env't: XP Pro SP3, IIS 5.1, MySQL 5.1, PHP 5.2.x, WP 2.7.1, Atahualpa 3.3.3, IE 7, FF 3.0.x
A thousand thanks, Juggledad.

It's nice to know it wasn't something silly I did. ... Maybe I'm beginning to learn a little something, from studying yours and Flynn's code, after all.

Just wondering, have you ever worked with Breadcrumb NavXT? And tried anything like this?
http://mtekk.weblogs.us/code/breadcrumb-navxt/
After uninstalling Yoast, that's my next attempt (unless you have a better suggestion).

Thanks.

A small token is on its way.
  #5  
Old Jun 14, 2009, 07:55 PM
fromtheranks
 
149 posts · Apr 2009
Dev Env't: XP Pro SP3, IIS 5.1, MySQL 5.1, PHP 5.2.x, WP 2.7.1, Atahualpa 3.3.3, IE 7, FF 3.0.x
Hmmmm ... the "Click here" link to donate doesn't seem to be linking. Do you have to catch that when you first open your reply? Before responding?

Thanks.
  #6  
Old Jun 14, 2009, 07:56 PM
fromtheranks
 
149 posts · Apr 2009
Dev Env't: XP Pro SP3, IIS 5.1, MySQL 5.1, PHP 5.2.x, WP 2.7.1, Atahualpa 3.3.3, IE 7, FF 3.0.x
Never mind. Stupid question. I really have to get some sleep one of these days.
  #7  
Old Jun 14, 2009, 07:59 PM
fromtheranks
 
149 posts · Apr 2009
Dev Env't: XP Pro SP3, IIS 5.1, MySQL 5.1, PHP 5.2.x, WP 2.7.1, Atahualpa 3.3.3, IE 7, FF 3.0.x
On its way.

Thanks again, Jugglehead.

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Page Menu Bar - Strange Space Occurring Between Menu Items NealSchaffer Page & Category Menu Bars 2 Jun 20, 2009 10:18 AM
[SOLVED] Yoast Breadcrumbs And Page Menu Bar - Follow-up fromtheranks Plugins & Atahualpa 0 Jun 17, 2009 02:01 AM
[SOLVED] Breadcrumbs in Page Menu Bar not working ... no matter what ... but has for fromtheranks Page & Category Menu Bars 2 Jun 17, 2009 01:52 AM
Integration with Yoast Breadcrumbs lawvol Plugins & Atahualpa 2 Feb 17, 2009 06:21 PM
[SOLVED] Very minor : page menu bar home option dcousquer Page & Category Menu Bars 1 Dec 13, 2008 03:52 AM


All times are GMT -6. The time now is 04:53 AM.


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