1.4.6 - sort type and sort direction

vincent3569 Member, Translator

Theme changes
[...]
The sort type and direction parameters to the various next_XXXX functions are deprecated. There have always been issues with these as they do not go into effect until that function call, but the sorting criteria are needed for other items like pagination computations. The objects now have methods for setting the sorttype and sortdirection. These should be used at the beginning of the theme script to insure consistent ordering of the objects.
[...]

Object model sorttype and sortdirection changes
Various functions which have sorttype and sortdirection as parameters have now deprecated these parameters. Instead the type and direction of sorts shoud be set in the object at the start of theme scripts that require special sorts.

If this is not done then there will be inconsistencies with such things as pagination and content display.

Can you explain this a little more ?
As far I can see in 1.4.6 core code, sort type and direction parameters to the various next_XXXX functions are still here...
I am trying to understand this and to see if my themes need some rewrite.

Comments

  • acrylian Administrator, Developer
    Formerly you could set the order etc directly on the next_xxx functions. But that would mean for example the pagination that comes before those function calls does not know about it.

    So now you need to set any sorting via the object model before calling any functions, e.g. at the beginning of the theme page. Then all "know what to do" when they are used.
  • Of course if you never passed those parameters there is nothing to be concerned with. Usually themes would not supply the parameters.

    The parameters are still available for transition. However you will get a "deprecated" message if you pass them and have not disabled the message.
Sign In or Register to comment.