-
AuthorPosts
-
November 13, 2018 at 12:51 pm #1032983
hello
i have a issue when i have an “easy slider full width” with multiple images,
the “previous and next navigation” disappearexemple here :
but it’s working when it’s a vidéo :
can you help me ?
November 15, 2018 at 1:37 pm #1033943ping to enfold’s team !!!
November 15, 2018 at 1:41 pm #1033947Hi,
Please add following code to Functions.php file in Appearance > Editor
add_filter('avia_post_nav_settings','avia_remove_fullwidth_slider_check', 10, 1); function avia_remove_fullwidth_slider_check($settings) { $settings['is_fullwidth'] = false; return $settings; }
Post nav is disabled on portfolio items that has fullwidth elements by default.
Best regards,
YigitApril 16, 2019 at 8:57 am #1091304on 4.5.5 this does not work anymore
April 16, 2019 at 4:09 pm #1091480Hi,
The filter is deprecated and replaced by a more clear solution (see enfold\functions-enfold.php line 570ff):
add_filter('avf_post_nav_settings','avia_remove_fullwidth_slider_check', 10, 1 ); /** * $settings['skip_output'] = true if you want to skip output * $settings['same_category'] = true|false * $settings['excluded_terms'] = array|comma speerated string of id's * * @param array $settings * @return boolean */ function avia_remove_fullwidth_slider_check($settings) { $settings['skip_output'] = false; return $settings; }
Best regards,
GünterApril 18, 2019 at 10:54 am #1092381as usual : top
Thanks –
btw: the pages have that side nav then too – but uncommenting the same_category setting did the job to exclude pages from left/right navigation.
No if clause needed hereApril 27, 2019 at 3:26 pm #1094913Edit: with that new loop function – you have to look again to it. It would be nice to loop in same category !
And on activating both: same category and loop option the page got post_nav tooApril 30, 2019 at 2:17 pm #1095765Hi,
Using
$settings['skip_output'] = false;
forces the script to continue and output the navigation.
Under normal circumstances you do not need to alter this value as Enfold logic is setting this as needed (removes it for hierarchical post types like pages and when fullwidth elements are found (avia_sc_layerslider, avia_sc_slider_full).
If you want e.g. enable nav for all portfolio only (also including fullwidth elements) you can use:
if( false === $settings['skip_output'] ) { return $settings; } if( 'portfolio' == $settings['type'] ) { $settings['skip_output'] = false; } else { $settings['skip_output'] = true; } return $settings;
Hope this helps.
Best regards,
GünterMay 2, 2019 at 10:36 am #1096418Yes that is ok now.
Edit : just a moment – to fast that posting
isn’t this enough – because i think for pages it is standard behavior that they skip – only the general setting to false skip let them get involved in the wrong way.
so if i insert this code to include only the files needed will be ok:
add_filter('avf_post_nav_settings','enfold_customization_postnav', 10, 1); function enfold_customization_postnav($settings){ $settings['same_category'] = true; $settings['is_fullwidth'] = false; if( 'post' == $settings['type'] ) { $settings['skip_output'] = false;} if( 'portfolio' == $settings['type'] ) { $settings['skip_output'] = false;} return $settings; }
Thank you for your patience.
- This reply was modified 5 years, 7 months ago by Guenni007.
May 2, 2019 at 3:18 pm #1096498Hi,
Please check https://github.com/KriesiMedia/enfold-library/blob/master/actions%20and%20filters/Layout/avf_post_nav_settings.php
for an improved version.
Best regards,
GünterNovember 4, 2019 at 10:32 pm #1153780How does this work on a child theme?
November 6, 2019 at 6:35 pm #1154374Hi docperi,
By adding the code to the functions.php file.
If you need further assistance please let us know.
Best regards,
Victoria -
AuthorPosts
- You must be logged in to reply to this topic.