Viewing 18 posts - 1 through 18 (of 18 total)
  • Author
    Posts
  • #1290372

    Hi,

    I would to know how to change following topics :
    – archive title category
    – posts per page
    – pagination (enable / disable)

    If necessary specific hook / filter to code.

    Best regards

    Jorge

    #1291193

    Hey Jorge,

    Sorry for the late reply. I’m not sure I understand your intentions, could you try to explain them a bit further please?

    Best regards,
    Rikard

    #1291285

    Hi Rikard,

    I noticed that archive title category have a prefix (“Archive for: ”) which I would like to remove. After further research I found the solution … on your site. By using hook filter called ‘avf_which_archive_output’ with function called ‘avia_new_archive_output’. But I spent a lot of time to find it.

    Do you have an exhaustive hook and function list (Ava, avf,avia) on your website ? Because I did not found it on your Hook and Filter page (https://kriesi.at/documentation/enfold/hooks-and-filters/).

    In addition, I would like to change default values for ‘posts per page’ and ‘pagination’ (enable / disable) for ‘blog posts’ element.

    For instance, the following code does not work within a function triggered by filter hook ‘avia_post_slide_query’ :
    $query[‘posts_per_page’] = 24;
    $query[‘nopaging’] = true;
    I used this filter and function to filter some posts by author (which works fine).

    In the same way, I am trying to filter posts with ‘masonry grid’ and I’m wondering which filter to use because ‘avf_masonry_loop_prepare’ does not allow to filter.

    Hope my explanations are more clear this time.

    Best regards

    Jorge

    #1291930

    Hi,

    Thank you for the update.

    Which posts element are you actually using? You should be able to use the avia_blog_post_query filter to adjust the default query of a specific Blog Posts element. The pagination option can be enabled/disabled in the Blog Posts settings, under the Styling tab.

    Best regards,
    Ismael

    #1291990

    Hi Ismael,

    Thank you for your feedback.

    I’m using the following posts elements : magazine (homepage), masonry (News), blog posts (Community, Recipes).

    Changing options has no effect in the Blog Posts settings. The option ‘post_per_page’ is always set to 5 whatever the input value. I do not know why.

    Please have a look on my website by clicking on the widget categories in the footer, more specifically with categories having more than 5 posts).

    Best regards.

    Jorge

    #1292633

    Hi,

    Thank you for the update.

    The number of items shown in the main blog page can be controlled in the Settings > Reading panel, but only if the Enfold > Blog Layout > Blog Layout settings is not set to the last option (“Use the advance layout builder..”). If it is, you have to edit the posts element directly in the blog page.

    We created a test page, inserted a few posts elements and the selected options are applied including the number of posts per page. However, a weird thing happen when we added the Blog Posts element. It looks different from the default. Did you modify the Blog Posts shortcode? We posted the link of the test page in the private field.

    Best regards,
    Ismael

    #1292823

    Hi Ismael,
    I did not modify the Blog Posts shortcode. So I do not understand why I still have this limit of 5 of posts per page (when clicking on archives and Categories pages).
    I agree with you it is weird.
    Best regards.
    Jorge

    #1293180

    Hi,

    Thank you for the info.

    The markup of the Blog Posts element is different from the default layout. We may need to access the file server in order to check the issue further — the Appearance > Editor panel is not accessible.

    Please post the FTP details in the private field, or enable the default file editor in the dashboard.

    Best regards,
    Ismael

    #1293763
    This reply has been marked as private.
    #1293764
    This reply has been marked as private.
    #1294031

    Hi,

    Thank you for the info.

    We have found a lot of unused themes in the /lamp0/web/vhosts/default/htdocs/wp-content/themes/ folder. Is that the correct directory? Would you mind removing the themes that you are not planning to use and leave Enfold and its child theme? If it is a multisite, then it’s fine.

    Looks like the page per posts option is now working, we set it to 6, but the pagination is still not showing. It shows back only after we disabled the filter in the functions.php file.

    //add_filter('avia_post_slide_query', 'lili_post_slide_query', 10, 2);
    

    Best regards,
    Ismael

    #1294059

    Hi Ismael,
    I thank you for your feedback.
    Correct, this is a WordPress Multisite but you’re right, there is a lot of unused themes to remove.
    Regarding the ‘ lili_post_slide_query’, I need it to filter authors posts depending on the page (Community page for friends recipes and Recipes page for current logged-in user only). Except if you have another solution to filter posts by author, I have to enable it. I have no choice.
    Many thanks for your help.
    Best regards
    Jorge

    #1294318

    Hi,

    Did you completely remove the lili_post_slide_query? It is not in the functions.php file anymore. We might be able to edit it so that it does not affect the pagination. Do you still need it?

    Please also note that we set the Enfold > Blog Layout > Blog Layout from Grid Layout to the last option (Use the advance layout builder..). This is to enable the ALB for the blog page and to actually show its content.

    Thank you for your patience.

    Best regards,
    Ismael

    #1294340

    Hi Ismael,
    Function lili_post_slide_query is still present in the functions.php file. And Yes, I still need it.
    Many thanks for your help.
    Best regards.
    Jorge

    #1294341

    Line 294

    #1295256

    Hi,

    Looks like this is working properly now. The posts limit in the archive pages (see private field) can be adjusted in the Settings > Reading panel. Look for the Blog pages show at most field or option.

    And if you want to disable or toggle the pagination, use this filter in the functions.php file.

    add_filter("avf_post_slider_args", function($atts) {
    	$atts["paginate"] = "no";
    	return $atts;
    }, 10, 1);
    

    Set paginate again to “yes” if you want to enable it back.

    Best regards,
    Ismael

    #1335002

    Hi Ismael,
    Please close this topic.
    Kind regards
    Jorge

    #1335032

    Hi,

    Thanks for the update, I’ll close this thread for now then. Please open a new thread if you should have any further questions or problems.

    Best regards,
    Rikard

Viewing 18 posts - 1 through 18 (of 18 total)
  • The topic ‘Archive settings – How to change’ is closed to new replies.