• 0
Sign in to follow this  
Followers 0

Custom text or html instead of image on Fixed Nav Bar


Question

Posted · Report post

I'm wondering if it's possible to insert some text instead of a logo in the fixed nav var. I have the menu setup the way I want but instead of my site title or an image I would like to put some social links sort of like the ones used in Branding tutorial in the Pagelines docs section. http://docs.pagelines.com/tutorials/creating-a-branding-area

 

It's this possible?

 

Thanks.

Share this post


Link to post
Share on other sites

9 answers to this question

  • 0

Posted · Report post

Hi there,

 

This is possible but you'd need to use a hook to insert the code into the fixed nav, unfortunately you wouldn't be able to do it via the drag and drop. The best way to do this would be to set up html for the icons in the way you want inside a textbox or similar so you get the layout and the css exactly how you want them.

 

Then activate the actionmap option inside the Pro Tools plugin so you can see which hook you'd need to use to position the code in the best place inside the fixed nav. Make a note of that hook and use the instruction here to add your html into that hook - http://docs.pagelines.com/advanced/hooks

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Thanks for the response. I'm getting closer to a solution but unfortunately the ActionMap is pretty incomplete. It's not showing a lot of possible hooks that are present in the pagelines hooks documentation: http://www.pagelines.com/api//libs/hooks.html

 

Notable among the missing hooks is the "navbar_brand" hook that's actually part of the very helpful sample code provided on the link you provided. 

 

The other disappointing thing I found is that the Hooker plugin also doesn't show a lot of these possible hooks so I'm learning all about the functions.php file now.

 

I found the pagelines-customize-plugin documentation and have installed that plugin: http://docs.pagelines.com/customize/pagelines-customize-plugin

 

After adding the sample pretty much verbatim from the advanced hooks example I was able to replace the fixed nav title with my new code but the formatting is all wonky. I think that's just going to be a matter of editing the CSS to get things to fall in place.

 

Thank you for the pointing me in the right direction. Even though some of the tools don't seem to be working 100% the way I would have expected I'm at least a lot closer than I was.

 

-Will

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Hi there, glad you've managed to make progress.

 

Action map will only show the hooks loaded on the page, not all hooks are loaded on every page it depends which sections are active etc. Hooker will only include DMS related hooks, not all the additional hooks provided by WP.

 

The hook once in place will only place the code into the required area, so you're correct that you'll need to use css to get the styling and alignment correct in the layout to get it looking the way you need it in the layout.

 

Let us know how you get on.

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Action map will only show the hooks loaded on the page, not all hooks are loaded on every page it depends which sections are active etc. Hooker will only include DMS related hooks, not all the additional hooks provided by WP.

 

So this part is where I was confused. I would have expected to see the navbar_brand hook displayed on every page because it's in the fixed nav bar so is displayed on every page. And I also was hoping to see it in Hooker because I thought it was a DMS specific hook. But neither was true. However after adding the example code to the functions.php in the pagelines_customization_plugin folder things started to fall into place.

 

I'm still having a little trouble with placement since it doesn't seem like my replacement HTML wants to align all the way to the left of the fixed nav bar section, and I get some weird responsive behavior when I shrink the window down to mobile size but hopefully I can resolve those in time.

 

The site is: http://simplify.bi It's all test content at the moment because I'm trying to get all the layout things worked out, but it's coming along.

 

Thanks again for the speedy responses.

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Hi there, navbar_brand is a wp filter not an action hook which is probably why it's not included. Hooker and actionmap will only show action hooks on the page, not filters. I will check with the core team to confirm that for you.

 

http://screencast.com/t/6y5WFSYkW

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Thanks. I'm still learning the different between filters and actions and how to determine which hook is which. I think I thought a hook was just a hook and then you could apply a filter or an action to that hook. Clearly I misunderstood how it all works. Thanks for the assistance.

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Hi there, you're welcome.

 

If it helps this is the hook article I usually reference as I found it the easiest to understand - http://wpcandy.com/teaches/how-to-use-wordpress-hooks/

 

Action hooks let you add content, filters let you amend/manipulate whats already there.

1 person likes this

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Similar problem to above. Except I am trying to make changes to the link for the logo in the "Navi" section. I can't find any filters for that section or when I use the child theme with the altered "navi" section included it does not override the section.  

 

Any suggestions?

 

Josh

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Hi Josh,

 

I have just added a the Navi section to my child themes sections folder and made some basic changes, these changes appeared. What child theme are you using and what changes did you make and to which file?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0