While using Wikitools, I noticed that this module should add the Custom Path as a default value in the 'Add Page' form. The attached patch should be applied to version Wikitools-6.x-1.1.
I done two simple things, that should be validated by code owners: I created the wikitools_get_page_name() function with wikitools_handle_request() excerpt, that returns the page name and the subpage values, and then used this function in wikitools_form_alter() to include the wikitools Custom Path as a default value.
By adding the Custom Path as a default value, it would improve the Wikitools usability a lot, as the user does not need to include this value by hand for every page added.
| Comment | File | Size | Author |
|---|---|---|---|
| wikitools-6.x-1.1-path.patch | 3.91 KB | guibv |
Comments
Comment #1
cwgordon7 commentedThank you for sharing this patch. Unfortunately, it will cause problems if the path module is not enabled. I'm also not altogether convinced that this is a good change, as many sites may have pathauto set up to set the path automatically (possibly to something different from the wikitools path.