Will Rossiter
0b91b91e33
Kill DocumentationService in favour of config API.
...
This continues on the migration to the Manifest. Instead of using calls to a `Service` now all file related lookups are done through the `DocumentationManifest`
2014-09-07 17:09:28 +12:00
Will Rossiter
43b6d42719
Overhaul of module to use DocumentationManifest
...
This major update changes the behaviour of the docviewer module to use a cached manifest rather than on demand. This allows us to simplify the URL matching and store 'nice' URL configuration rather than altering handleAction().
2014-09-07 11:26:12 +12:00
Will Rossiter
e80edc445e
Move advanced form out to it's own class
...
Make page title customizable through the Config system (Fixes #44 )
2014-09-06 11:22:05 +12:00
Will Rossiter
2c00a3b20f
New theme.
...
Clean up of existing theme, implementation of a new easier to integrate layout.
2014-09-06 11:13:12 +12:00
Will Rossiter
fab0cba8a8
Add bash syntax brush ( Fixes #45 )
2014-09-06 09:20:05 +12:00
Will Rossiter
1b0a5c519d
Use erusev/parsedown as the Markdown parser. ( Fixes #31 )
2014-07-27 12:39:44 +12:00
Will Rossiter
d5d346ace8
Fix incorrect code block generation when previous line contains whitespace ( Fixes #39 )
2014-07-27 11:26:10 +12:00
Dan Brooks
a6dead1fa2
Regex change to support combo of tab & space in md
2014-03-14 17:05:32 +00:00
Sam Minnee
b6b753ee4c
FIX: Fixed encoding of & in OpenSearchDescription URLs.
...
Without this fix, the & was then passed to urlencode(), which escaped the ; and make invalid
XML. This keeps XML out of the source URL (so the & is just a raw & in the code) and relies on
the template engine to escape XML as needed (the .XML on the end of the variables).
2014-02-14 09:38:37 +13:00
Will Rossiter
d68e523e72
Workaround search result matching.
2014-01-14 21:16:39 +13:00
Will Rossiter
95b982353b
NEW: Add static publisher option
2014-01-14 20:41:59 +13:00
Will Rossiter
c8ba3ffd2a
Fix 404 page not including requirements.
2014-01-11 16:20:53 +13:00
Trevor
501d4216c8
Fix/support dash in relative links
...
Currently if you go had something like this: `[Some Link](../)`
and you were in `http://devsite.dev/dev/docs/my_module/en/server-setup/location-specific/ `
The parser will resolve the link as: `http://devsite.dev/dev/docs/my_module/en/server-setup/location- `
This is because the regex is only matching *Any word character (letter, number, underscore)*. I've added the dash.
2013-11-05 15:12:26 +11:00
Ingo Schommer
b3d4e402a5
Allow absolute paths in DocumentationSearch::$index_location
2013-10-04 10:55:44 +02:00
Ingo Schommer
2d7c1499d7
Merge pull request #30 from Martimiz/meta-sort-20130522
...
MAJOR: enable the use of custom metadata and page sorting
2013-06-10 00:42:32 -07:00
Ingo Schommer
bd186a0a73
BUG Index relative URLs
...
Avoids clashes between CLI and web modes (e.g. wrongly configured
$_FILE_TO_URL_MAPPING lookups).
2013-05-29 18:17:14 +02:00
martimiz
227289575a
MEDIUM: remove metadata from the current page
2013-05-22 21:35:03 +02:00
martimiz
5400ba2afc
MAJOR: enable the use of custom metadata and page sorting
2013-05-22 18:35:26 +02:00
Ingo Schommer
cdb55f94f8
Create index location if it doesn't exist
2013-05-17 10:27:21 +02:00
Ingo Schommer
6227e1eb68
Allow symlinks in repo locations (don't resolve on image src)
2013-05-15 15:51:27 +02:00
Ingo Schommer
032a49d929
3.1/3.2 compat
2013-03-26 11:16:46 +01:00
Sean Harvey
0350495d20
Fixing DocumentationViewer::handleAction() to work with SS 3.1
2013-02-20 10:05:05 +13:00
Will Rossiter
3b27cd6b2b
NEW: Github style code fence blocks. ( Fixes #22 )
2013-02-19 22:23:22 +13:00
Sean Harvey
9cf85b0c19
If no versions registered for a module, don't show empty versions in template
2013-02-12 13:43:32 +13:00
Will Rossiter
389269936b
Merge pull request #21 from Martimiz/search-20130107
2013-02-07 17:53:41 -08:00
Sean Harvey
4a1e5436eb
BUG Fixing search not working when no specific versions of docs
2013-01-24 11:16:47 +13:00
Sean Harvey
927e1b0724
Fixing functions called statically to be declared as such
2013-01-23 16:22:27 +13:00
Will Rossiter
73a66da658
Merge pull request #23 from sdiel/patch-1
...
Update code/controllers/DocumentationViewer.php
2013-01-11 13:53:43 -08:00
Sebastian Diel
5cc766583d
Update code/controllers/DocumentationViewer.php
...
BUGFIX: fixed mechanism to get nested page entities when using upper case chars as the first char of a markdown files name or a folders name
2013-01-11 11:02:49 +01:00
Sebastian Diel
7d5ee2a249
Update code/controllers/DocumentationViewer.php
...
BUGFIX: fixed false variable name in DocumentationViewer::set_recursive_submenu()
2013-01-11 10:40:59 +01:00
martimiz
9f1f70a065
Enhancement: allow for enabling/disabling advanced search
...
The advanced searchbox only really functions properly for multiple
entities if they all have similar versions. If not, it will let you
search on entity-version combinations that might not even exist, which
can get confusing..
In such cases optionally disabling it could be a solution, waiting for
a better solution (possibly
2013-01-07 17:26:39 +01:00
martimiz
0bd844e139
Fix: no search results found on documentation homepage
...
On the homepage there are no searchedEntities nor searchedVersions
defined, so the searchForm creates empty hiddenfields. PerformSeach
creates subqueries for thes empty values resulting in the return of an
'Empty' query object.
Solution: do not create these fields when there are no entities/versions
2013-01-07 16:53:33 +01:00
martimiz
5bf5da4c92
Minor: add whitespace after comma in module/entity summary
2013-01-07 16:44:00 +01:00
martimiz
58d4f242b0
Fix: Search returns no results for auto-registered modules
...
Automatic registration sets the version to '' (empty). This breaks the
search as Lucene Search will return an Empty query object if a subquery
has an empty key.
Fix: register the modules as 'current' instead of ''. Setting the
version title to 'current' in DocumentViewer->getVersions() is now no
longer necessary.
2013-01-07 16:41:07 +01:00
martimiz
5d9feb3fe5
Fix: Search error on autoregistered entities
...
Error: [Warning] array_combine() [function.array-combine]: Both
parameters should have at least 1 element
HandleRequest for submitted forms returns before the automatic
registration of modules is performed, so no entities can be found.
Fixed by moving DocumentationService::load_automatic_registration();
to the top of the function
2013-01-07 16:31:12 +01:00
martimiz
88660f12f5
Fix: Mark DocumentationSearch::get_index_location() as static
2013-01-07 15:16:21 +01:00
Simon Welsh
6df20c1f73
Adds missing brace
2012-11-14 23:06:26 +13:00
Will Rossiter
0eadf2d174
Merge pull request #20 from Martimiz/master-update-121112
...
Styling 404 and selecting toplevel pages without children
2012-11-12 21:05:55 -08:00
martimiz
3dcf210045
changed getSubmenu to getSubmenuLocation
...
Because it doen't return the submenu itself, it returns the preferred
location
2012-11-13 18:04:05 +13:00
martimiz
0df804f86c
Allow for either nested or separate submenu form template. Include recursive option
...
Default setting: separate submenu, no recursion.
Setting recursion fetches all children, to allow for JavaScript-powered
submenus (script not included). If recursion is enabled, separate menus
are disabled.
2012-11-13 18:04:05 +13:00
martimiz
27a4f91d70
Fix: missing 'current' linking mode in top-level menu
...
If there are no children, the LinkingMode was set to 'link' and never
to 'current'
2012-11-12 16:19:44 +01:00
Sam Minnee
67ff61a756
FIX: Fixed E_STRICT error - static function not marked as such.
2012-11-12 11:26:44 +13:00
Will Rossiter
9aaeadd7ff
Migrated theme from doc.ss back to the module
2012-11-10 11:12:30 +13:00
martimiz
262b035fb5
FIX: IsFolder -> isFolder
...
commit 9672f2862c
introduced an error in
getter/setter
2012-11-10 09:27:28 +13:00
martimiz
1f6c5deda7
Minor: coding conventions and javascript, also added submenu title
2012-11-10 09:27:28 +13:00
martimiz
7e7b67548e
Mark submenu items with children as folders
...
Add an arrow to submenuitems that have undelying pages
2012-11-10 09:27:27 +13:00
martimiz
027b63ea0b
FIX: remove version from the breadcrumb url for the stable version
...
Same as in the menu links. fixes multiple urls for the same content
2012-11-10 09:27:27 +13:00
martimiz
62dd4e92f7
Relocate breadcrumbs to the top of the document
...
Remove breadcrumbs from the searchbar to the top of the page content,
and make sure they only display if there is more then the current link.
Wrap the module and version selectors to fill the gap in the searchbar.
2012-11-10 09:27:27 +13:00
Will Rossiter
317dbb1774
Method visibility
2012-11-10 09:27:10 +13:00
Will Rossiter
74b91a1dd1
NEW Yaml highlighting
2012-09-25 19:36:43 +12:00
Will Rossiter
4ffa1c71e6
FIX: prevent notice while doing search request.
2012-09-09 18:05:06 +12:00
Will Rossiter
b4dc440650
FIX: function is named getLink()
2012-09-09 17:13:51 +12:00
Will Rossiter
5d7bf64e73
Design tweaks
2012-09-05 21:42:06 +12:00
Will Rossiter
3a9a384ca4
NEW: Add set_edit_link() and getEditLink() to DocumentViewer to allow adding edit links to be displayed on documentation pages
2012-09-03 22:02:42 +12:00
Stig Lindqvist
fa646cdbf6
BUGFIX: Deprecation errors and strict warnings breaks the docsviewer
2012-05-18 09:48:57 +12:00
Will Rossiter
ae092ebf19
BUGFIX: ensure E_STRICT compatibility with docsviewer and 3.0 handleRequest().
2012-04-14 18:02:53 +12:00
Will Rossiter
dd84574b8d
BUGFIX: upgrade module to fit 3.0 api.
2012-04-14 17:00:22 +12:00
Will Rossiter
1e28e8252f
MINOR: rename from docviewer to docsviewer
2012-04-08 21:36:16 +12:00
Will Rossiter
a87094fb16
BUGFIX: check for valid directory before opening
2012-04-08 21:27:53 +12:00
Will Rossiter
34d46b7a5b
MINOR: update references to sapphiredocs to docviewer. ENHANCEMENT: introduce DOCVIEWER_PATH and DOCVIEWER_DIR consts
2012-04-08 21:23:49 +12:00
Will Rossiter
7381733b4c
BUGFIX: fixed search index field naming from module to entity to be consistent. BUGFIX: fixed url for opensearch description. ENHANCEMENT: moved author information to meta_data
2011-08-11 17:03:42 +12:00
Will Rossiter
a12169c9e0
MINOR: include own syntax highlighting theme for ssdoc.
2011-08-11 13:32:09 +12:00
Will Rossiter
85e5b1b72d
FEATURE: added advanced search form to allow searching by module and version
2011-08-04 10:04:53 +12:00
Will Rossiter
0ba6d8d338
Merge branch 'master' of github.com:silverstripe/silverstripe-sapphiredocs
2011-08-02 15:31:38 +12:00
Will Rossiter
56578742f4
MINOR: merging changes from ss2doc back. APICHANGE: renamed DocumentationOpenSearch_Controller to DocumentationOpenSearchController. MINOR: renamed left and right column to more generic content/sidebar columns
2011-08-02 15:30:58 +12:00
Marcus Nyeholt
c9f35cebbb
BUGFIX: Changed the base URL for the search so it hits the correct action
2011-07-25 14:35:11 +10:00
Marcus Nyeholt
99951426ed
BUGFIX: Change the doc folder search to use the correct folder name variable.
...
BUGFIX: Use the full path to the basefolder when searching for folders; cwd is actually sapphire, so this ends up looking in the wrong path otherwise
2011-07-25 14:34:30 +10:00
Will Rossiter
959cb16534
FEATURE: added automatic notifications about accessing outdated or unreleased versions. ( Fixes #6320 )
2011-07-08 14:42:52 +12:00
Will Rossiter
96ac20a15c
BUGFIX: fixed bug with linking to internal assets.
2011-07-04 16:58:15 +12:00
Will Rossiter
cb19549a97
ENHANCEMENT: if viewing site on current version, do not include version in the parsed links
2011-07-04 12:05:22 +12:00
Will Rossiter
762eb2323b
APICHANGE: Renamed internal references of modules to entities and related method naming. FEATURE: added entity navigation in header. BUGFIX: fixed version links so that they redirect to the version of the current page rather than home page
2011-07-01 18:49:31 +12:00
Will Rossiter
4830e09bad
ENHANCEMENT: moved 404 page out to a separate template and altered DocumentationViewer to throw 404s on pages which do not resolve to anything. Fixes : #6616
2011-07-01 14:37:55 +12:00
Will Rossiter
15244a9934
ENHANCEMENT: rolled out basic versioning support.
2011-07-01 13:19:35 +12:00
Will Rossiter
aa0297d52a
Cherry picked changes from doc.silverstripe.org. FEATURE: added boost options to promoting or removing listings from the search. ENHANCEMENT: use a breadcrumb trail for search title to provide additional context
2011-04-29 14:41:30 +12:00
Will Rossiter
ef5664f777
BUGFIX: fixed encoding of special characters when not in code snippets.
2011-04-05 14:17:25 +12:00
Will Rossiter
cfaa08d858
ENHANCEMENT: fixed default homepage template to include links to individual modules rather than blank pages. BUGFIX: fixed doc viewer to not throw 404 error when no module provided
2011-03-12 17:14:37 +13:00
Will Rossiter
bbc657acfc
MINOR: changed theme to a darker one to help with readability
2011-03-07 09:55:29 +13:00
Will Rossiter
ac608190c6
MINOR: update links to use atom rather than RSS
2011-02-25 11:53:17 +13:00
Will Rossiter
bb35223fea
MINOR: changed pipe to dash. Easier on the eyes.
2011-02-25 09:22:36 +13:00
Ingo Schommer
b1c93bd27a
BUGFIX Allowing 'trunk' and 'master' as version numbers
2011-02-24 17:54:44 +13:00
Will Rossiter
94121f0a66
BUGFIX: fixed link to search query from opensearch description
2011-02-11 15:28:26 +13:00
Will Rossiter
13fdb8dd80
APICHANGE: refactored DocumentationSearch to go back to a simple class rather than a controller. All requests interfacing with the search should go through DocumentationViewer. APICHANGE: migrated DocumentationSearch::opensearch() to its own controller. BUGFIX: declare default meta_data in the function rather than using the api to prevent inclusion order issues
2011-02-11 01:29:25 +00:00
Will Rossiter
166fb8dff3
FEATURE: implemented initial cut of open search output and description functionality.
2011-01-21 04:10:41 +00:00
Ingo Schommer
24ebc64945
BUGFIX Showing proper 404s
2011-01-17 06:00:16 +00:00
Ingo Schommer
b61e4e9057
BUGFIX Absolute include paths so phpunit executable doesnt barf
2011-01-17 06:00:16 +00:00
Ingo Schommer
5d48bc97de
BUGFIX Fixed 404 display
2011-01-16 20:17:57 +00:00
Ingo Schommer
e024be8806
BUGFIX Fixed relative and absolute links
2011-01-16 20:17:56 +00:00
Ingo Schommer
089c844892
MINOR Making anchors more readable and predictable by using lowercase only
2011-01-15 21:47:43 +00:00
Will Rossiter
e571b5973f
FEATURE: added parser for metadata inside documentation. MINOR: removed outdated code
2011-01-14 03:29:14 +00:00
Will Rossiter
768345a8b9
ENHANCEMENT: contrary to r115556, display a listing of files within an empty folder index rather than defaulting to the first file. Fixes #6347
2011-01-14 02:16:03 +00:00
Will Rossiter
2a7b7ee83d
ENHANCEMENT: if a folder is missing an index.md file load the first file as a failback
2011-01-14 01:48:36 +00:00
Will Rossiter
fc8ab96c51
ENHANCEMENT: use urls in the format module/lang/version rather than version first. Tweaks to the parser to prevent infinite loops
2011-01-14 01:03:46 +00:00
Will Rossiter
24f1b13233
FEATURE: added $PageTitle output for nicer bookmarked urls
2011-01-13 20:34:55 +00:00
Will Rossiter
9bd43ae7ad
BUGFIX: only strip off dot and trailing string if it is a possible extension
2011-01-13 08:34:33 +00:00
Ingo Schommer
160b527dfc
BUGFIX Fixed DocumentationViewer->_getModulePagesNested(), wasn't comparing anything lower than first level properly
2011-01-13 08:27:27 +00:00
Ingo Schommer
ac5b0e53e8
MINOR Documentation
2011-01-13 08:27:26 +00:00
Ingo Schommer
e0c8b6e9e0
BUGFIX Added DocumentationPage->getRelativeLink(), which opposing to getRelativePath() excludes the extension
2011-01-13 08:27:25 +00:00
Ingo Schommer
652f7c3898
BUGFIX Fixed anchor parsing in headlines ( fixes #6342 )
2011-01-13 07:20:55 +00:00
Ingo Schommer
8e69d51af7
MINOR Fixed syntaxhighlighter brush paths
2011-01-11 19:44:56 +00:00
Will Rossiter
221cd700b6
ENHANCEMENT: included zend/search/lucene with the module to avoid including the entire lucene module. ENHANCEMENT: added hourly task as well as buildtask for dealing with cron updates. MINOR: updated documentation
2011-01-11 01:35:59 +00:00