Digital experiences for all disciplines
New Landing › How can we help? › Themeforest Theme Support › Flexform › Accordion: Icon before the tab name?
New Landing › How can we help? › Themeforest Theme Support › Flexform › Accordion: Icon before the tab name?
Tagged: accordion, cant, comments, didnt, google, I, icon, name, page, possible, results, section, shortcode, Somebody, tab, themeforest
- This topic has 9 replies, 3 voices, and was last updated 11 years by Cosmin – SUPPORT.
-
Posted in: Flexform
-
June 8, 2013 at 10:44 am #7507June 8, 2013 at 9:15 pm #7523
I can’t seem to get it working, I’ll try and get cosmin in here to help.
Thanks
BenJune 27, 2013 at 11:31 am #9343Bump!
Did you take a look at this already?Best greetings,
thosch
June 27, 2013 at 7:58 pm #9432Hi Thosch,
First of all, apologies for the delay, will do my best to not happen again ๐
Now, the solution to this is a bit tricky. You’d need to specify custom CSS for each accordion heading that you have. The following solution will work if you only have one accordion group in only one page on your site:
h3.ui-accordion-header:before { float: left; font-family: FontAwesome; line-height: 38px; margin: 0 20px; }
That’s something to style them all so we don’t write it a lot of times.
Now, for the first accordion heading:
#ui-accordion-1-header-0:before { content: "\f002"; }
That would give you the search icon. Here are all the options available: http://fortawesome.github.io/Font-Awesome/cheatsheet/
You take starting from the “f” in the parenthesis and add a \ in front of it.The code for the second heading would be:
#ui-accordion-1-header-1:before { content: "\f002"; }
Note it changed from header-0 to header-1… and so on.
If you have multiple accordion groups or are using accordions on multiple pages, let me know, there’s a different thing to do there.
Hope this helps.
Regards,
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Cosmin
Support AssistantJune 28, 2013 at 12:52 pm #9456Hi Cosmin,
thanks a lot for helping me out! Works like a charm for me and isn’t tricky at all.
I have got only accordion group on the website right now. But I don’t know if I need another one on a certain page. If it isn’t too much hassle, I’d be very grateful, if you let me know the other solution as well.Thanks again!
PS: Nevermind on being a bit late with the answer… I guess you have quite a bit to do with answering all the forum posts, haven’t you. My site is still on dev-status anyway, so all’swell
๐June 28, 2013 at 8:53 pm #9493You wont have to change anything to make it work on multiple accordions if that’s what you mean?
Thanks
BenJuly 3, 2013 at 11:37 am #9962Hi Ben,
you are right, if I want to have the same Icons in every other accordion section. If I have another accordion on another page with different icons, then this solution doesn’t work.Best greetings,
thosch
July 3, 2013 at 9:57 pm #10081Hi Thosch,
If you have multiple pages with accordions, you will need to modify that CSS and specify it for each page.
First, get the page ID of your first page with accordions. You can do this by viewing the page source when on your site (right click>view source) and checking the body tag: http://cl.ly/image/0S3j3L3g3X2A
In my example, it’s page-id-570, so the last two sections of code that I gave you, would be:
.page-id-570 #ui-accordion-1-header-0:before { content: "\f002"; }
and
.page-id-570 #ui-accordion-1-header-1:before { content: "\f002"; }
Now let’s say I have another page, with ID 571. My class would be page-id-571, so I would need to add this as well, to make it work for this new page:
.page-id-571 #ui-accordion-1-header-0:before { content: "\f002"; }
and
.page-id-571 #ui-accordion-1-header-1:before { content: "\f002"; }
And so on… hope this helps ๐
Regards,
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Cosmin
Support AssistantJuly 4, 2013 at 2:25 pm #10157Cosmin!
You made my day!
Thanks a lot for pushing me in the right direction…. i already tried out sth. similar, but it didn’t work out!
Top notch support, guys….
Best greetings,
thosch
July 4, 2013 at 8:58 pm #10276Glad to hear that helped, Thosch ๐
If I haven’t mentioned this before and you like the product and support, please do rate the theme in your ThemeForest Download section, we would greatly appreciate it!
Regards,
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Cosmin
Support Assistant -
Posted in: Flexform
You must be logged in and have valid license to reply to this topic.