Using `getPrev` and `getNext` with entries sorted by SuperSort plugin? I applied the superSort plugin function to a list of entries and it works perfectly:

{% set entries = craft.entries.section('sectionName').type('entryType').order('entryTitle')|supersort('natsort') %}


Trying to apply it to an entry page with this code to get the previous and next entry. It does not work:

{% set arrowParams = craft.entries.section('sectionName').type('entryType').order('entryTitle')|supersort ('natsort') %}
{% set prevEntry = entry.getPrev(arrowParams) %}{% set nextEntry = entry.getNext(arrowParams) %}
  {% if prevEntry %}
    &lt;a href="{{ prevEntry.url }}"&gt;{{ prevEntry.title }}&lt;/a&gt;
  {% endif %}

  {% if nextEntry %}
    &lt;a href="{{ nextEntry.url }}"&gt;{{ nextEntry.title }}&lt;/a&gt;
  {% endif %}


Thanks for helping!
It won't work with getPrev and getNext, as they only work with ElementCriteriaModels and not with an array of Entry models.

But that is what you get returned from the plugin. Supersort converts your craft.entries ElementCriteriaModel into an array of Entry models. This is necessary so that it can do the sorting.

The only workaround I know of would be to get the IDs of your supersorted entries and pass them to the ID param of a new ElementCriteriaModel.

{% set entries = craft.entries.section('sectionName').type('entryType') %}
{% set entriesSorted = entries|supersort('natsortAs', '{title}') %}

{% set entryIds = [] %}
{% for entry in entriesSorted %}
    {% set entryIds = entryIds|merge([entry.id]) %}
{% endfor %}

{% set arrowCriteria = craft.entries.id(entryIds).fixedOrder(true) %}


Now you have an ElementCriteriaModel arrowCriteria, prepared to get entries in the desired sort order. So now you can use arrowCriteria with your entry methods.

{% set prevEntry = entry.getPrev(arrowCriteria) %}
{% set nextEntry = entry.getNext(arrowCriteria) %}

{% if prevEntry %}
    &lt;a href="{{ prevEntry.url }}"&gt;{{ prevEntry.title }}&lt;/a&gt;
{% endif %}

{% if nextEntry %}
    &lt;a href="{{ nextEntry.url }}"&gt;{{ nextEntry.title }}&lt;/a&gt;
{% endif %}