wp-bootstrap-navwalker icon indicating copy to clipboard operation
wp-bootstrap-navwalker copied to clipboard

Conflict with jetpack?

Open justdayan opened this issue 12 years ago • 2 comments

I'm using this class successfully. However, when I log into the stats section of jetpack, i'm getting this error.

Warning: Cannot modify header information - headers already sent by (output started at /wp-content/themes/indulge/lib/helper/wp_bootstrap_navwalker.php:203) in /wp-content/plugins/jetpack/class.jetpack.php on line 3915

Warning: Cannot modify header information - headers already sent by (output started at /wp-content/themes/indulge/lib/helper/wp_bootstrap_navwalker.php:203) in /wp-content/plugins/jetpack/class.jetpack.php on line 3939

justdayan avatar Sep 04 '14 15:09 justdayan

I will dig into this.

SideQuestDIY avatar Dec 04 '14 17:12 SideQuestDIY

Seems the issue is with the fallback function in the navwalker file. The specific line is the one that echo's the variable containing the menu.

echo $fb_output;

I can't recreate this issue myself in a dev site so I'm wondering if there's some kind of conflict going on elsewhere that's leaking some text somewhere and that's causing Jetpack problems. Alternatively some text entered somewhere may not be properly sanitized (something that gets used by the fallback so it would be likely specified in your wp-nav-menu() call.

Can you paste your call to wp-nav-menu() here for me?

As a sidenote: I don't think the extra fallback menu function is really required at all so it could safely be removed. @justdayan try remove lines 158-205 from the wp_bootstrap_navwalker.php file and see if that fixes your issue.

pattonwebz avatar Jan 05 '15 16:01 pattonwebz