Wikka Mod 041
Type: Feature AdditionCredit
Mark Kasper and GmBowen (main credit for the idea and initial code)AHerdOfTurtles (for helping me see that this is a cool idea)
Jason Tourtelotte (major refinement to the code -- almost a complete rewrite)
Description
This modification adds the ability to show an index listing of pages that start with a certain letter. There is also an alphabetical heading at the top of each listing. Just click a letter to see pages that start with that letter.
For example:
Usage:
{{pageindex letter="d"}}
Outcome:
Page Index
This is an alphabetical list of pages you can read on this server.
S
SafeHTML [SafeHTML]
SamClayton [SamClayton] . . . . Owner: SamClayton
SamuelDr [SamuelDr] . . . . Owner: SamuelDr
SandBox [Hey, what happened to the SandBox?] . . . . Owner: DarTar
SandBoxHeader [SandBoxHeader] . . . . Owner: DarTar
SansSerif [SansSerif] . . . . Owner: BrianKoontz
SanTika [SanTika] . . . . Owner: SanTika
Sara [Sara] . . . . Owner: BoinkFella
ScRa [ScRa] . . . . Owner: ScRa
SeanBonner [SeanBonner] . . . . Owner: SeanBonner
SearchEngines [SearchEngines] . . . . Owner: DavidReisner
SearchHelp [SearchHelp]
SearchHelpFR [SearchHelpFR] . . . . Owner: PivWan
SearchHighlighter [SearchHighlighter] . . . . Owner: RolandStens
SearchTags [SearchTags] . . . . Owner: IntElf
SebCls [SebCls] . . . . Owner: SebCls
SectionEditing [SectionEditing] . . . . Owner: NilsLindenberg
SecurityInfo [SecurityInfo]
SecurityInfoES [SecurityInfoES] . . . . Owner: YanB
SecurityModules [SecurityModules] . . . . Owner: JavaWoman
SecuritySandBox [SecuritySandBox] . . . . Owner: JsnX
SeitiYamashiro [SeitiYamashiro] . . . . Owner: SeitiYamashiro
SelectTemplateOnPageCreation [Select Template on Page Creation] . . . . Owner: MasinAlDujaili
SemanticMarkup [SemanticMarkup] . . . . Owner: IanAndolina
SEOHacks [SEO Hacks] . . . . Owner: BrianKoontz
ServerErrorWorkaround [ServerErrorWorkaround] . . . . Owner: JavaWoman
ServerProblems [ServerProblems] . . . . Owner: DarTar
ServertimeOffsetWorkaround [ServertimeOffsetWorkaround] . . . . Owner: SparkOut
ShadowPages [ShadowPages] . . . . Owner: MasinAlDujaili
ShareOnLinkedIn [ShareOnLinkedIn] . . . . Owner: RolandStens
ShaunC [ShaunC] . . . . Owner: ShaunC
ShopRocker [ShopRocker] . . . . Owner: ShopRocker
ShoTanaka [ShoTanaka] . . . . Owner: ShoTanaka
ShowCodeInfo [ShowCodeInfo] . . . . Owner: DarTar
ShowCodeInfoFR [ShowCodeInfoFR] . . . . Owner: PivWan
ShowCommentsHandler [ShowCommentsHandler] . . . . Owner: SamuelDr
ShowCsv [ShowCsv] . . . . Owner: NilsLindenberg
ShowRecentChangesMindMapAction [ShowRecentChangesMindMapAction] . . . . Owner: NickDamoulakis
ShowVisioAction [ShowVisioAction] . . . . Owner: NickDamoulakis
ShU [ShU] . . . . Owner: ShU
SiddharthUpmanyu [SiddharthUpmanyu] . . . . Owner: SiddharthUpmanyu
SidenoteActions [SidenoteActions] . . . . Owner: JasonHuebel
SidenoteActionsTormodHaugen [SidenoteActionsTormodHaugen] . . . . Owner: JasonHuebel
SiDoNeY [SiDoNeY] . . . . Owner: SiDoNeY
SifrIntegration [SifrIntegration] . . . . Owner: DarTar
SigAction [SigAction] . . . . Owner: PezHore
Signature [Signature] . . . . Owner: AndrewJanuary
SimonKnight [SimonKnight] . . . . Owner: SimonKnight
SimpleMathFormula [SimpleMathFormula] . . . . Owner: GmBowen
SimpleTableOfContents [SimpleTableOfContents] . . . . Owner: FatherNitwit
SimpleTables [SimpleTables] . . . . Owner: TormodHaugen
SimpleViewer [SimpleViewer] . . . . Owner: DonSuper
SimplifiedWikiCategory [SimplifiedWikiCategory] . . . . Owner: DarTar
skrap [skrap] . . . . Owner: skrap
SlavaBarbash [SlavaBarbash] . . . . Owner: SlavaBarbash
Slideshow2Handler [Slideshow2Handler] . . . . Owner: DomBonj
Slideshow2HandlerInfo [Slideshow2HandlerInfo] . . . . Owner: DomBonj
SlideshowExample [SlideshowExample] . . . . Owner: DomBonj
SlideshowGallery [SlideshowGallery] . . . . Owner: YodaHome
SlideshowHandler [SlideshowHandler] . . . . Owner: GmBowen
SlugFace [SlugFace] . . . . Owner: SlugFace
SmartTitle [SmartTitle] . . . . Owner: DarTar
SmartTitlesInfo [SmartTitlesInfo] . . . . Owner: NilsLindenberg
SmartyPants [SmartyPants] . . . . Owner: DarTar
SmaugDragon [SmaugDragon] . . . . Owner: SmaugDragon
SmiliesAction [SmiliesAction] . . . . Owner: GiorgosKontopoulos
SocialSoftware [SocialSoftware] . . . . Owner: DarTar
SocialSoftwareFR [SocialSoftwareFR] . . . . Owner: RadioGrraphie
SolidarityEconomy [SolidarityEconomy] . . . . Owner: QuetzalRieur
SomaCarisoprodol [SomaCarisoprodol]
SomeCallMeTim [SomeCallMeTim] . . . . Owner: SomeCallMeTim
SoWhatAreTheNews [SoWhatAreTheNews] . . . . Owner: ChristianBarthelemy
SpamBlacklist [SpamBlacklist] . . . . Owner: MreimeR
SpamSafeEmail [SpamSafeEmail] . . . . Owner: FrankChestnut
SpanishLanguage [SpanishLanguage] . . . . Owner: PedroM
SparkOut [SparkOut] . . . . Owner: SparkOut
SpectreMoo [SpectreMoo] . . . . Owner: SpectreMoo
SpedoMeter [SpedoMeter] . . . . Owner: PaulBelgian
SpeedInfo [SpeedInfo] . . . . Owner: DarTar
SpeedInfoES [SpeedInfoES] . . . . Owner: YanB
SpeedInfoFR [SpeedInfoFR] . . . . Owner: PivWan
SpellcheckHack [SpellcheckHack] . . . . Owner: SpectreMoo
SpifFin [SpifFin] . . . . Owner: SpifFin
SpreadTheWord [SpreadTheWord] . . . . Owner: DarTar
StanPacMatt [StanPacMatt] . . . . Owner: StanPacMatt
StaraliciA [StaraliciA] . . . . Owner: StaraliciA
StatsFooter [StatsFooter] . . . . Owner: WillyPs
StayingLoggedIn [StayingLoggedIn] . . . . Owner: NilsLindenberg
StephenMatthaey [StephenMatthaey] . . . . Owner: StephenMatthaey
SteveB [SteveB] . . . . Owner: SteveB
SteveKra [SteveKra] . . . . Owner: SteveKra
StoneHead [StoneHead] . . . . Owner: StoneHead
StoryIdeas [StoryIdeas] . . . . Owner: CaryCollett
StructDataAction [StructDataAction] . . . . Owner: DomBonj
StructDataActionInfo [StructDataActionInfo] . . . . Owner: DomBonj
StubText [StubText] . . . . Owner: DavePreston
StylingWikka [StylingWikka] . . . . Owner: WillyPs
SuddenPrism [SuddenPrism] . . . . Owner: SuddenPrism
SuFu [SuFu] . . . . Owner: SuFu
SuggestionBox [SuggestionBox]
SuggestionsArchive [SuggestionsArchive] . . . . Owner: NilsLindenberg
SuggestionsBoard [SuggestionsBoard] . . . . Owner: GeorgePetsagourakis
SumSung [SumSung] . . . . Owner: SumSung
SupportingWikka [SupportingWikka] . . . . Owner: BrianKoontz
SvgAction [SvgAction] . . . . Owner: MasinAlDujaili
SvgActionInfo [SvgActionInfo] . . . . Owner: MasinAlDujaili
SymCo [SymCo] . . . . Owner: SymCo
SyndicatingWikka [SyndicatingWikka] . . . . Owner: DarTar
SyntaxHighlighter [SyntaxHighlighter] . . . . Owner: JsnX
SysInfo [SysInfo] . . . . Owner: JsnX
SysInfoActionInfo [SysInfoActionInfo] . . . . Owner: DarTar
SysInfoActionInfoFR [SysInfoActionInfoFR] . . . . Owner: PivWan
SystemRequirements [SystemRequirements] . . . . Owner: RoseHa
SystemRequirementsDE [SystemRequirementsDE] . . . . Owner: YvesFischer
SystemRequirementsES [SystemRequirementsES] . . . . Owner: InterCaps
SystemRequirementsFR [SystemRequirementsFR] . . . . Owner: PivWan
SzalokiLaszlo [SzalokiLaszlo] . . . . Owner: SzalokiLaszlo
Code
[26/9/04] actions/pageindex.php file after this mod:
<?php if ($pages = $this->LoadAllPages()) { if (isset($_REQUEST["letter"])) $requested_letter = $_REQUEST["letter"]; else $requested_letter = ''; if (!$requested_letter && isset($letter)) $requested_letter = strtoupper($letter); $cached_username = $this->GetUserName(); $user_owns_pages = false; $link = $this->href("", "", "letter="); $index_header = "<strong><a href='$link'>All </a></strong> \n"; $index_output = ""; $current_character = ""; $character_changed = false; foreach ($pages as $page) { $page_owner = $page["owner"]; // $this->CachePage($page); $firstChar = strtoupper($page["tag"][0]); if (!preg_match("/[A-Za-z]/", $firstChar)) $firstChar = "#"; if ($firstChar != $current_character) { $index_header .= "<strong><a href='$link$firstChar'>$firstChar</a></strong> \n"; $current_character = $firstChar; $character_changed = true; } if ($requested_letter == '' || $firstChar == $requested_letter) { if ($character_changed) { $index_output .= "<br />\n<strong>$firstChar</strong><br />\n"; $character_changed = false; } $index_output .= $this->Link($page["tag"]); if ($cached_username == $page_owner) { $index_output .= "*"; $user_owns_pages = true; } elseif ($page_owner != '(Public)' && $page_owner != '') { $index_output .= " . . . . Owner: ".$page_owner; } $index_output .= "<br />\n"; } } $index_header .= "<br />"; if ($user_owns_pages) $index_output .= "<br />\n* Indicates a page that you own.<br />\n"; print $index_header.$index_output; } else { print("<em>No pages found.</em>"); } ?>