Ticket #641 (closed defect: invalid)

Opened 2 months ago

Last modified 2 months ago

Navigation items for pages should be inserted in the order they were created, not the other way around

Reported by: Stellaris Owned by:
Priority: major Milestone:
Component: Habari Core Software Version: 0.5
Keywords: navigation,order,link weight Cc: Stellaris

Description

Navigation items for pages should be inserted in the order they were created, not the other way around. Alternatively, allow some "link weight" to be set perhaps?

I just populated the navigation with a few standard page links like "info", "contact", .... and found that the link order was wrong. The first link I inserted ended up on the right-hand side while all other links ended up on the left-hand side.

Intended order: Blog - Info - Contact - Imprint Wrong order: Blog - Imprint - Contact - Info

I checked with the K2 and Charcoal theme, same display. A workaround is to reverse the order of creation for inserted links so the desired final order is achieved.

Change History

Changed 2 months ago by miklb

  • status changed from new to closed
  • resolution set to invalid

you can add 'orderby' => 'pubdate ASC' to the theme.php template to achieve this (line 61-ish of k2 for example)

$this->assign('pages', Posts::get( array( 'content_type' => 'page', 'status' => Post::status('published'), 'nolimit' => 1,'orderby' => 'pubdate ASC' ) ) );
Note: See TracTickets for help on using tickets.