When Drupal is installed in a sub directory the links in the book navigation block have the sub directory name included twice.
e.g. Drupal installed at http://localhost/drupal-8.0.x/, the book navigation block links all start with http://localhost/drupal-8.0.x/drupal-8.0.x/

Steps to reproduce:
1. Install Drupal in a sub directory
2. Activate the book module
3. Create a book page
4. Activate the Book Navigation Block
5. Click on the link to the book page.

Expected Result:
The book page is displayed.

Actual Result:
"Page not found" is displayed. The path is invalid with the sub directory included twice.

Comments

dawehner’s picture

The problematic line is:

$element['#href'] = $node->url();
inside BookManager::bookTreeOutput()

This now returns a full rendered URL, not just the system path as before, which then is passed to theme_book_link(). The best solution would be to use urlInfo() and use that url object inside theme_book_link()

undertext’s picture

Assigned: Unassigned » undertext
undertext’s picture

Assigned: Unassigned » undertext
undertext’s picture

Status: Active » Needs review
StatusFileSize
new1.99 KB
m1r1k’s picture

Issue tags: +#ams2014contest
juxelle’s picture

Assigned: undertext » Unassigned
Status: Needs review » Fixed
Issue tags: -

I just tested the latest drupal 8.0.x code and the issue is fixed.

Thanks for your patch undertext but it looks like this got fixed as part of another issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.