1
0
Fork 0
mirror of https://github.com/sbrl/Pepperminty-Wiki.git synced 2024-11-22 04:23:01 +00:00

Make page names that are redirects italics in search results.

This commit is contained in:
Starbeamrainbowlabs 2017-03-20 20:21:25 +00:00
parent 8404b0cec6
commit d19d83d99a
4 changed files with 8 additions and 1 deletions

View file

@ -31,6 +31,7 @@
- Changed the way users' data is stored to support arbitrary per-user data - Changed the way users' data is stored to support arbitrary per-user data
- Sorted list of registered actions on the dev help page - Sorted list of registered actions on the dev help page
- The page editor's main content box now automatically expands as you're typing! If you've got a custom theme, you may need to tweak it a bit. Help available on request. - The page editor's main content box now automatically expands as you're typing! If you've got a custom theme, you may need to tweak it a bit. Help available on request.
- Pages that are redirects how have their names appear in italics in search results.
## Fixed ## Fixed
- The login session lifetime is now configurable (defaults to 24 hours), so you won't keep getting logged out all the time (in theory). (#113) - The login session lifetime is now configurable (defaults to 24 hours), so you won't keep getting logged out all the time (in theory). (#113)

View file

@ -2701,6 +2701,9 @@ register_module([
$context .= "..."; $context .= "...";
}*/ }*/
// Make redirect pages italics
if(!empty($pageindex->{$result["pagename"]}->redirect))
$result["pagename"] = "<em>{$result["pagename"]}</em>";
// We add 1 to $i here to convert it from an index to a result // We add 1 to $i here to convert it from an index to a result
// number as people expect it to start from 1 // number as people expect it to start from 1

View file

@ -86,7 +86,7 @@
"author": "Starbeamrainbowlabs", "author": "Starbeamrainbowlabs",
"description": "Adds proper search functionality to Pepperminty Wiki using an inverted index to provide a full text search engine. If pages don't show up, then you might have hit a stop word. If not, try requesting the `invindex-rebuild` action to rebuild the inverted index from scratch.", "description": "Adds proper search functionality to Pepperminty Wiki using an inverted index to provide a full text search engine. If pages don't show up, then you might have hit a stop word. If not, try requesting the `invindex-rebuild` action to rebuild the inverted index from scratch.",
"id": "feature-search", "id": "feature-search",
"lastupdate": 1490040313, "lastupdate": 1490041182,
"optional": false "optional": false
}, },
{ {

View file

@ -170,6 +170,9 @@ register_module([
$context .= "..."; $context .= "...";
}*/ }*/
// Make redirect pages italics
if(!empty($pageindex->{$result["pagename"]}->redirect))
$result["pagename"] = "<em>{$result["pagename"]}</em>";
// We add 1 to $i here to convert it from an index to a result // We add 1 to $i here to convert it from an index to a result
// number as people expect it to start from 1 // number as people expect it to start from 1