• Welcome to WebsiteBaker Community Forum. Please log in or sign up.
Welcome, Guest
News
Support WebsiteBaker
Your donations will help to:
PayPal
  • Pay for our dedicated server
  • Pay for domain registration
  • and much more!
You can donate by clicking on the button below.

Neuster Eintrag beim Accordion Modul erscheint dummerweise als letzter Punkt

Started by Lara, February 16, 2023, 02:52:48 PM  ( Read 9,130 times )

Lara

Ich möchte gerne das Modul Accordion benutzen.
Kann mir jemand sagen, wo ich ändern oder einstellen kann, dass der neuste Beitrag jeweils zuoberst und nicht unten angezeigt wird?

Für einen Tipp wäre ich dankbar.

    Gast

    Das gibt es auch noch?

    also: es geht nur zu ändern, wenn du es im Code direkt machst, denn das Modul hat dafür keine Einstellungen

    Falls du dich traust...

    Datei view.php // Zeile 51

    der Original-Code:
    // Loop through existing questions
    $sSql = 'SELECT * FROM `'.TABLE_PREFIX.'mod_accordion_questions` WHERE `section_id` = '.(int)$section_id.' ORDER BY `pos` ASC';


    das ACS ASC am Ende bestimmt die Sortierung. Ändere es in DESC und du hast eine umgekehrte Reihenfolge (zuletzt eingetragenes Item an erster Stelle

    // Loop through existing questions
    $sSql = 'SELECT * FROM `'.TABLE_PREFIX.'mod_accordion_questions` WHERE `section_id` = '.(int)$section_id.' ORDER BY `pos` DESC';


      dbs


      \n\n