1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.5 [solved] New Posts PAGE only: increase number of results

Discussion in 'XenForo Questions and Support' started by creativeforge, Oct 12, 2015.

  1. creativeforge

    creativeforge Active Member

    I've been looking to increase the number of results shown on the PAGE that opens when I click on New Posts. When I do it via the ACP, it changes this for every page throughout the whole forum.

    Could I change this ONLY for the New Posts? If so, how?

    Thanks!

    Andre
     
  2. Chris D

    Chris D XenForo Developer Staff Member

    Would require a code edit or add-on, I'm not aware of an add-on that already exists.

    I would usually advise against code edits, because edits to the code will be overwritten after each upgrade, however, the code edit is relatively simple.

    File: library/ControllerPublic/FindNew.php
    Find:
    PHP:
    $perPage XenForo_Application::get('options')->discussionsPerPage;
    Replace:
    PHP:
    $perPage 50;
    Where "50" is the desired number of items per page.
     
  3. creativeforge

    creativeforge Active Member

    Thanks Chris, so I would replace it with $perPage = 50->discussionsPerPage; ?
     
  4. Chris D

    Chris D XenForo Developer Staff Member

    No. As it says in my example:
    PHP:
    $perPage 50;
     
  5. creativeforge

    creativeforge Active Member

    OK, thanks! it works very well...
     

Share This Page