• 0

Hero Nav Add a title to mobile-menu?

Question

Posted · Report post

can I add a title to the mobile-friendly navigation, so that it appears to the left of the menu icon?

Share this post


Link to post
Share on other sites

10 answers to this question

  • 0

Posted · Report post

1.2 was released today which adds several hooks for you to do things like add a title or other content, or change the icon/text for the mobile toggle button.

 

For now the source is your only how-to, but I plan on putting together a little tutorial on my website for it soon.

 

Cheers

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Hey flourishdesignstudio,

 

Your the first person to ask about this, but I think it's a good idea.

 

I'm not sure if justifies another option, but I may add a filter for it.  Are you familiar with WP hooks & filters?

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Hi Evan! I've never used a hook, but it's been something that I want to learn if you can talk me through it. I already have a child theme created.

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Filters are really cool.

 

It's basically like a checkpoint during execution.  Filters pass some information, and then generally asks "anyone else want to do something with this?", at which point you can :)  You can either add to it however you wish, or even change it completely.

 

Hooks & filters are pretty much the same thing, the only difference is that filters require that you return some data back, where as actions don't do anything with a returned value.

 

There are many tutorials about how to use hooks and filters.  Perhaps I'll write one for betterdms.com :)

 

Stay tuned for an update.  The best way right now is probably just to follow me on twitter: @aaemnnosttv.

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

I'm replying here rather than the other thread for the sake of relevance.

 

I haven't decided if I will make an option for the toggle text or not.  I think it's probably better to make it filterable, and then you can make it however you want.

 

Regarding whether most people recognize that as indicating a menu is there... I think this has been embraced as an unspoken standard in a big way.

 

There are many big websites and mobile apps (facebook for example) that use this symbol to toggle a menu.  Two big websites that come to mind are starbucks.com and theonion.com.

I don't think it's necessarily a bad idea to add a title/label next to it though.  The need for such a thing definitely depends on the audience of the website as well.

 

I'll post an update here when there is a solution :)

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Where can I find the HeroNav HOOKS?

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

1.2 was released today which adds several hooks for you to do things like add a title or other content, or change the icon/text for the mobile toggle button.

 

For now the source is your only how-to, but I plan on putting together a little tutorial on my website for it soon.

 

Cheers

Where can I find the HeroNav HOOK tagt allows to put HEADLINE into Mobile header?

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

micstepl,

 

The hooks are documented in the source.  If you're on the current version (1.3 as of this writing) you will find these starting around line 355 in plugins/hero-nav/sections/hero-nav/inc/HeroNav.php.  You will find several hooks there that you may find useful.

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Evan,

 

Would it be possible to post the what hook we should use and the code to get this to show up on Mobile only?

 

Thanks! 

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