-
AuthorPosts
-
March 25, 2020 at 6:33 pm #1197794
Hi,
In my home page, in the top I have a Slider accordéon with 6 images.
The title (or legend) of each images appears like H3.
my SEO partner asks me to remove the H3 at the top of the page, which appear before the H1 on the page
Is it possible to have the same text design without H3, with quick CSS ?
ThanksMarch 28, 2020 at 1:18 pm #1198562Hey ppi37,
Here is the code you can put in your funtions.php
function my_avf_customize_heading_settings( array $args, $context, array $extra_args = array() ) { if( $context == 'avia_sc_magazine' ) { $args['heading'] = 'div'; // change heading from h3 to div $args['extra_class'] = 'my-magazine-header'; // add an extra class for styling } return $args; } add_filter( 'avf_customize_heading_settings', 'my_avf_customize_heading_settings', 10, 3 );
If you need further assistance please let us know.
Best regards,
VictoriaMarch 30, 2020 at 6:28 pm #1199121Hi Victoria,
I added your code in the function.php of the enfold child theme,
but there is always H3 in the accordion sliderthe page code :
…<h3 class=’aviaccordion-title ‘ itemprop=”headline” >Appareil de levage</h3>…Thanks for help
March 31, 2020 at 7:36 pm #1199479Hi ppi37,
Can you give us temporary admin access to your website in the private content box below, so that we can have a closer look?
Best regards,
VictoriaMarch 31, 2020 at 9:10 pm #1199536This reply has been marked as private.April 3, 2020 at 9:29 pm #1200639Hi ppi37,
Sorry, the class was incorrect. Please try to use this code instead:
function my_avf_customize_heading_settings( array $args, $context, array $extra_args = array() ) { if( $context == 'avia_sc_slider_accordion' ) { $args['heading'] = 'div'; // change heading from h3 to div $args['extra_class'] = 'my-accordion-header'; // add an extra class for styling } return $args; } add_filter( 'avf_customize_heading_settings', 'my_avf_customize_heading_settings', 10, 3 );
Best regards,
VictoriaApril 6, 2020 at 10:19 am #1201171Hi Victoria,
No change.
Here is the code before and after the new functiun you give me :
<div class=’aviaccordion-preview-title-pos’>
<div class=’aviaccordion-preview-title-wrap’>
<div class=’aviaccordion-preview-title’>
<h3 class=’aviaccordion-title ‘ itemprop=”headline” >Appareil de levage</h3>
</div></div></div>
Thanks for helpApril 9, 2020 at 9:46 pm #1202501Hi ppi37,
This is fixed now, I have replaced this part of Victoria’s code:
if( $context == 'avia_sc_slider_accordion' )
with:
if( $context == 'aviaccordion' )
Let us know if you need further assistance.
Best regards,
NikkoApril 10, 2020 at 12:18 pm #1202645Hi Nikko and Victoria,
it seems to work perfectly !
Thanks a lotApril 11, 2020 at 2:01 pm #1202900Hi ppi37,
Glad we could help :)
If you need further assistance please let us know.
Best regards,
VictoriaApril 11, 2020 at 2:02 pm #1202901Hi ppi37,
Glad we could help :)
If you need further assistance please let us know.
Best regards,
VictoriaNovember 9, 2020 at 7:10 pm #1259342Hi, I have the same problem with a iconbox….
where is the function.php?
thanks- This reply was modified 4 years, 1 month ago by mtrebbi.
November 9, 2020 at 7:50 pm #1259375Hi mtrebbi,
Could you please give us a link to your website, we need more context to be able to help you.
Best regards,
VictoriaNovember 10, 2020 at 10:23 am #1259506http://www.udsa.it
thanks
SaraNovember 10, 2020 at 11:13 am #1259518@Nikko
https://kriesi.at/support/topic/how-to-remove-h3-in-slider-accordeon/#post-1202501this was new to my – and a look to source code is right – the filter ( avf_customize_heading_settings ) is indeed part of this on line 875:
if ( ! class_exists( 'aviaccordion' ) )
if i use the filter i always took as victoria intends to do the context from the beginning:
if ( ! class_exists( 'avia_sc_slider_accordion' ) )
it seems to be a specific thing for accordion slider !
@mtrebbi the iconbox has on top of the alb source code:if ( ! class_exists( 'avia_sc_icon_box' ) )
so context of the filter is : avia_sc_icon_box
only the title is set with conjuction to that filter – so this will be enough:function my_heading_settings_for_iconbox( array $args, $context, array $extra_args = array() ) { if( $context == 'avia_sc_icon_box') { $args['heading'] = 'h1'; $args['extra_class'] = 'my-iconbox'; } return $args; } add_filter( 'avf_customize_heading_settings', 'my_heading_settings_for_iconbox', 10, 3 );
the extra_class you can set by yourself – it is only for additonal Styling Options.
November 10, 2020 at 11:24 am #1259521Just for info: some ALB Elements got extra-args for that filter – so you can influence f.e. on timeline.php the date and the title headings
Date is on default : h2 – and the title is h4
if you want to influence those ALB Elements with extra args you had to do following:function my_avf_customize_heading_settings( array $args, $context, array $extra_args = array() ){ //so here comes the extra_arg date with that filter if( $context == 'avia_sc_timeline' && is_array( $extra_args ) && in_array( 'date', $extra_args ) ) { $args['heading'] = 'h3'; $args['extra_class'] = 'my-timeline-date-class'; } //so here comes the extra_arg title with that filter if( $context == 'avia_sc_timeline' && is_array( $extra_args ) && in_array( 'title', $extra_args ) ) { $args['heading'] = 'h1'; $args['extra_class'] = 'my-timeline-title-class'; } return $args; } add_filter( 'avf_customize_heading_settings', 'my_avf_customize_heading_settings', 10, 3 );
November 10, 2020 at 1:29 pm #1259560I’m a beginner and I can’t do this …. why isn’t the possibility to choose the type of tag integrated into the tool?
Right now, I have a page with 10 h2 and 10 h4 and that’s not good …November 10, 2020 at 4:39 pm #1259610November 10, 2020 at 5:37 pm #1259633I don’t have Heading section….. I have only Link Setting and developer settings….
I have enfold 4.7.6.1 ….November 10, 2020 at 11:43 pm #1259705if you open the icon-box Element you do not have 3 General Tabs on top ( see screenshot above )
Content, Styling and Advanced !on default the option is not activated ( “Hide template builder developer options” ) – see dashboard – Enfold – Layout Builder:
https://kriesi.at/documentation/enfold/intro-to-layout-builder/#developer-optionsNovember 12, 2020 at 9:28 am #1260055I’ve update Enfold…now is 4.7.6.4
I’ve activated “Hide template builder developer options”
but my icon-box Element is the same….in the Advanced tab there is only link setting…November 12, 2020 at 11:58 am #1260084 -
AuthorPosts
- The topic ‘How to remove H3 in Slider accordeon’ is closed to new replies.