Re: [Rest2web-develop] problem with sort order of sections variable
Brought to you by:
mjfoord
|
From: Michael F. <fuz...@vo...> - 2006-11-08 14:13:34
|
Michael Foord wrote:
> martin f krafft wrote:
>
>> Hi there,
>>
>> The sections variable is an OrderedDict. I am, however, confused as
>> to how it's ordered. I have files 1-6.txt (so 1.txt, 2.txt, ...,
>> 6.txt), and they have titles with starting letters G,R,K,P,S,V
>> respectively. Yet, when I iterate sections, the order I get is
>> 4,1,2,3,6,5 (P,G,R,K,V,S). So I guess neither filename nor title
>> actually play a role.
>>
>>
> It *ought* to use the ordering you declare them in the restindex...
>
>
Sorry, I got confused. My answer was only partially helpful.
You can explicitly specify an order for files within a section using the
'section-pages' keyword in the restindex.
section-pages: section-name, page1, page2, page3
If you only use the default section within a directory then you can do :
section-pages: , page1, page2, page3
(Extra leading comma to specify the default section ordering.)
I use this feature a lot where I want to specify the order of pages -
and it usually has little to do with page title or filename.
Fuzzyman
http://www.voidspace.org.uk/index2.shtml
> Fuzzyman
> http://www.voidspace.org.uk/index2.shtml
>
>
>> How can I then influence the sort order of the sections variable,
>> which is used e.g. by minibar.
>>
>> Cheers,
>>
>>
>> ------------------------------------------------------------------------
>>
>> -------------------------------------------------------------------------
>> Using Tomcat but need to do more? Need to support web services, security?
>> Get stuff done quickly with pre-integrated technology to make your job easier
>> Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
>> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
>> ------------------------------------------------------------------------
>>
>> _______________________________________________
>> Rest2web-develop mailing list
>> Res...@li...
>> https://lists.sourceforge.net/lists/listinfo/rest2web-develop
>>
>>
>
>
> -------------------------------------------------------------------------
> Using Tomcat but need to do more? Need to support web services, security?
> Get stuff done quickly with pre-integrated technology to make your job easier
> Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
> _______________________________________________
> Rest2web-develop mailing list
> Res...@li...
> https://lists.sourceforge.net/lists/listinfo/rest2web-develop
>
>
|