Home Forums General Issues Menu icons prepend vs append


Menu icons prepend vs append

  • Hello,

    I’m currently using this guide: to add menu icons to my site navigation. It is working as expected, however, I would like the <i class=”fa fa-‘.$icon.'”></i> to be before the $item->title instead of after (prepend vs append) and I’m lost on how to achieve this. Any ideas / help would be greatly appreciated.


  • something like this would probably do it

    $item->title = '<i class="fa fa-'.$icon.'"></i> '.$item->title;
  • Thanks, John. This worked perfect.

    • JoDa

    • May 16, 2019 at 7:33 pm

    Hey John, just wanted to say THANKS for your always helpful posts. Throughout the years your answers on this forum have helped me countless times!

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.

We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Cookie Policy. If you continue to use this site, you consent to our use of cookies.