Closed (works as designed)
Project:
Pathauto
Version:
7.x-1.2
Component:
Code
Priority:
Major
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
19 Dec 2012 at 20:48 UTC
Updated:
27 Dec 2012 at 20:11 UTC
When using path auto relative links break.
e.g.
If you have a block with an img that looks like:
<img src="sites/default/files/img.jpg">
Then visit some content that uses the alias content/node
the alias content is inserted into the img path, it comes up as content/sites/default/files/img.jpg which breaks the links.
Absolute links don't break or have the alias inserted. Only occurs when the actual domain is visited, not on temporary domains.
Not sure if clean urls affects it or not.
Comments
Comment #1
dave reidThis is how 'href' values in links and images work by default. If you don't provide a prefix of a slash character (e.g.
) then browsers interpret the links (such as
) as relative to the current page/URL.
You can also use a module like Pathologic to convert inline links to full URLs.
Comment #2
nicxvan commentedThank you! I actually knew that, but for some reason I didn't make the connection.
Pathlogic looks great too.
Comment #2.0
nicxvan commentedfixed code tag