Ticket #8877 (closed defect: duplicate)

Opened 2 years ago

Last modified 1 year ago

menu item links fail on trac installations in the root of the server.

Reported by: david.killick@wcn.co.uk Assigned to: cbalan
Priority: normal Component: MenusPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.12

Description

In our trac installation, trac is installed at the root of our server.

When an item's href is set to (say)

ticket_defect.href = /newticket?type=defect

The resulting URI is

//newticket?type=defect

which causes the browser to make requests to a non-existent server.

Investigating a similar error in another plugin suggested it may be due to 'ref.href()' returning '/'. Not sure if it is the case here.

Attachments

Change History

12/14/11 07:07:03 changed by rjollos

  • status changed from new to closed.
  • resolution set to duplicate.

12/14/11 07:28:29 changed by rjollos

(In [11038]) Fixes #7399, Refs #7680, #8877, #8953: (0.1.1) Links were invalid when Trac was accessed from the top-most path.

12/14/11 07:45:43 changed by rjollos

(In [11039]) Fixes #7399, Refs #7680, #8877, #8953: (0.1.1) [11038] was the wrong solution. This fix should work better.

01/18/12 09:51:15 changed by rjollos

(In [11154]) Fixes #7399, Refs #7680, #8877, #8953: Allow Href to take care of path joining. Tested in 0.11 and 0.13dev-r10909.

01/18/12 09:57:17 changed by rjollos

(In [11155]) Fixes #7399, Refs #7680, #8877, #8953: Removed egg and pydev files accidentally committed in [11154].

01/18/12 09:58:12 changed by rjollos

(In [11156]) Fixes #7399, Refs #7680, #8877, #8953: Removed egg and pydev files accidentally committed in [11154].

01/20/12 16:04:16 changed by rjollos

(In [11166]) Fixes #7399, Refs #7680, #8877, #8953: Yet another attempt to fix invalid links when req.href = '/'. If the href for a menu item specifies a relative path, the trailing forward slashes are stripped from req.href() so that the two cases are handled: 1) req.href() is '/' and 2) req.href() is '/somepath'.


Add/Change #8877 (menu item links fail on trac installations in the root of the server.)




Change Properties
Action