Icon Font in Menu Item
11 years 5 months ago #15764
by Bucklash
Icon Font in Menu Item was created by Bucklash
Bon Soir Mr CK
I apologise if this has been mentioned before but I can't find it:
I would like to put an icon font in to some of my menu items ie:
<li><a><i class="icon-star"> </i>Favourites</a></li>
I don't expect maximenu to do everything, it almost does!!
But this capability would be the icing on the cake if it were possible.
i am trying to find a solution but thought I would ask you aswell.
(It would be great if we could enter html in module titles, but alas, we can't)
Merci / Thanks
Jon
I apologise if this has been mentioned before but I can't find it:
I would like to put an icon font in to some of my menu items ie:
<li><a><i class="icon-star"> </i>Favourites</a></li>
I don't expect maximenu to do everything, it almost does!!
But this capability would be the icing on the cake if it were possible.
i am trying to find a solution but thought I would ask you aswell.
(It would be great if we could enter html in module titles, but alas, we can't)
Merci / Thanks
Jon
Please Log in or Create an account to join the conversation.
11 years 5 months ago - 11 years 5 months ago #15766
by Bucklash
Replied by Bucklash on topic Icon Font in Menu Item
Right,
I was being a bit of a dumbo, or I'm now being really clever (you decide)
I thought icon-fonts HAD to be in an <i> tag.
I just added the class to the <li> and all is funky ( I added css to change the icon from width 14px to auto to suit my visual idea)
I assume I am not breaking any coding law that says I MUST use an <i> tag...
I will use it until the HTML police come a knockin'
Jon
I was being a bit of a dumbo, or I'm now being really clever (you decide)
I thought icon-fonts HAD to be in an <i> tag.
I just added the class to the <li> and all is funky ( I added css to change the icon from width 14px to auto to suit my visual idea)
I assume I am not breaking any coding law that says I MUST use an <i> tag...
I will use it until the HTML police come a knockin'
Jon
Last edit: 11 years 5 months ago by Bucklash. Reason: Spelling
Please Log in or Create an account to join the conversation.
11 years 5 months ago #15768
by ced1870
Joomlack Webmaster and Developer
Replied by ced1870 on topic Icon Font in Menu Item
Hi
you can do that like this, no problem
you can use the bootstrap css class for icon on every html tag
CEd
you can do that like this, no problem

you can use the bootstrap css class for icon on every html tag
CEd
Joomlack Webmaster and Developer
The following user(s) said Thank You: Bucklash
Please Log in or Create an account to join the conversation.
11 years 5 months ago #15772
by Bucklash
Replied by Bucklash on topic Icon Font in Menu Item
Good to know
Why do all the examples use the <i> tag
I suppose it must be a best practise principle?
Anyway, thanks for confirming it was ok to do
Jon
Why do all the examples use the <i> tag
I suppose it must be a best practise principle?
Anyway, thanks for confirming it was ok to do
Jon
Please Log in or Create an account to join the conversation.
11 years 5 months ago #15773
by ced1870
Joomlack Webmaster and Developer
Replied by ced1870 on topic Icon Font in Menu Item
really ? I don't know, may be because "i" is a simple html tag and because written "i" is less characters than "span" for example

Joomlack Webmaster and Developer
The following user(s) said Thank You: Bucklash
Please Log in or Create an account to join the conversation.
Time to create page: 0.215 seconds