miniDLNA: How to sort titles by track number: adding force_sort_criteria to config

I had the problem with miniDLNA on OpenWrt that when playing a directory, the music tracks are sorted alphabetically by name and not by track number. This makes it impossible to listen to operas or concept albums, for example, in the correct order.

The needed option of miniDLNA is force_sort_criteria='+upnp:class,+upnp:originalTrackNumber,+dc:title' ,
but you can't insert this in the LuCi web interface.

The addition of another line
option force_sort_criteria '+upnp:class,+upnp:originalTrackNumber,+dc:title'
in

/etc/config/minidlna

alone is not enough, because it is not supported by the startup-script

/etc/init.d/minidlna

The additional option is skipped.

As a hot-fix I added the following line to /etc/init.d/minidlna
minidlna_cfg_addstr "$cfg" force_sort_criteria

deleted the database and restarted minidlna.

I would be grateful if this important configuration option would be added as standard to the 2023 release of OpenWrt/miniDLNA .

How about renaming the track with 01, 02 etc as a prefix, thus.....

01_sibelius_symphony6_allegro molto moderato.

The tracks (=the files) are named in a similar way as you suggested. But when the title (= the information coded within the binary files) are like "Allegro molto moderato", then "03_sibelius_symphony6_adagio.mp3" would (with OpenWrt standard sorting) be played before track "01_sibelius_symphony6_allegro molto moderato.mp3", because "Adagio ..." comes alphabetically before "Allegro ..."

Interesting.....I didnt know that...i only got this idea because i have named files as Episode_01 etc and it works