Menu

#33 PageList.FillFromPageLinks returns unsuitable title

closed-fixed
None
5
2015-03-07
2015-02-22
No

In some cases, a returned pagetitle is correct found and shown but not suitable to work with. For instance: Login to German Wikibooks and read the PageList by FillFromPageLinks("Wikijunior Europa"). One item is shown as "/_Projektdefinition". That is correct because the page includes an abbreviated link "[[/_Projektdefinition|Co-Autoren ...]]". I suggest to complete this title to "Wikijunior Europa/ Projektdefinition".

This situation may occur in many Wikibooks projects because WB often uses subpages as chapters. Authors may use this MediaWiki feature (slash instead of the full book pagename) to simplify the table of contents.

Thank you, Juergen

Discussion

  • Juergen Thomas

    Juergen Thomas - 2015-02-23

    Another problem in the same circumstances: Double links give two items in the pagelist. See the same example "Wikijunior Europa": That page contains [[Wikijunior_Europa/_Vereinigtes Königreich|Großbritannien]] and [[Wikijunior_Europa/_Vereinigtes Königreich|Vereinigtes Königreich]]. Please, check the best way to handle this problem: double items (I don't see a situation where this is useful), pages.Add(p) only if not pages.Contains(p), additional bool parameter "withDoubles". Juergen

     
  • CodeDriller

    CodeDriller - 2015-02-23
    • status: open --> accepted
     
  • CodeDriller

    CodeDriller - 2015-02-23

    Ok, the function will resolve relative links and remove duplicates.

     
  • Juergen Thomas

    Juergen Thomas - 2015-02-23

    Thank you, don't hurry up. Juergen

     
  • CodeDriller

    CodeDriller - 2015-03-07
    • status: accepted --> closed-fixed
    • assigned_to: CodeDriller
     
  • CodeDriller

    CodeDriller - 2015-03-07

    Implemented in v3.14.

     

Log in to post a comment.