Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hi, this sounds like a duplicate of other issues, but I have tested all D7 versions of Pathologic and get the same issue:
NB: On my dev machine I do not have clean URLs enabled
When I enable Pathologic it replaces Drupal paths beautifully from node/7 to aliased/path-to-article
BUT images disappear as their src is being changed from /sites/default/files/images/the-image.jpg to /?q=sites/default/files/images/the-image.jpg
I saw a response somewhere else to add file: to the start of the src but that is not an option if the client is going to edit this content.
Thanks
Comment | File | Size | Author |
---|---|---|---|
#2 | pathologic-new-files-logic.diff | 2.91 KB | Garrett Albright |
Comments
Comment #1
Garrett Albright CreditAttribution: Garrett Albright commentedHmm. Thanks for bringing this to my attention. It's kind of tricky because there are conversions that Pathologic may need to do on a path to a file which are legitimate, so we can't just ignore file paths, but at the same time, yeah, things sort of break when clean URLs are not enabled right now, I see. I'll give this a look and see what can be done.
Comment #2
Garrett Albright CreditAttribution: Garrett Albright commentedHmm, well, I made this. Kind of afraid to commit it, though, since I'm afraid it might break things for folks for whom the current functionality with regards to files works just fine. Anyone with such a site out there who might be willing to be a guinea pig for me? =/
Comment #3
Garrett Albright CreditAttribution: Garrett Albright commentedOkay, I bit the bullet and finally made a 7.x-2.0 release today, and I included this patch. Closing this issue for now; please re-open if there are still problems.
Comment #4
Garrett Albright CreditAttribution: Garrett Albright commentedOkay, the fix for this was causing more problems than it fixes, so I had to revert it for now. I'll have to take another look at this in the near future.
Comment #5
Garrett Albright CreditAttribution: Garrett Albright commentedOkay, I've just pushed a new set of possible fixes. If you could, please check out the latest dev release (created after this post) and let me know if it works for you.
Comment #6
Garrett Albright CreditAttribution: Garrett Albright commentedI just created a new release which should incorporate the bug fix for this. Please give it a try. If it still seems broken, please re-open this issue and let me know what's up.
Comment #7
Garrett Albright CreditAttribution: Garrett Albright commentedOops, wrong status.
Comment #9
Andreas Kohlbecker CreditAttribution: Andreas Kohlbecker commentedThis is still not working in the most current versions of the pathologic module 7.x-2.6 and 7.x-2.x-dev (2012-Oct-27).
for example the image path src="/d8/foo/sites/bar/files/images/770.jpg" is converted to http://localhost/d7/foo/?q=d8/foo/sites/bar/files/images/770.jpg
The text format being used in this case is Full HTML and has the following options turned on:
* Convert line breaks into HTML
* Correct URLs with Pathologic
Filter processing order:
* Convert line breaks into HTML
* Correct URLs with Pathologic
neither any of the Processed URL formats works with the following base paths:
* /d8/foo
* http://localhost/d8/foo
* //localhost/d8/foo
The resulting url always contains the "?q=" when clean urls is turned off
Comment #10
Garrett Albright CreditAttribution: Garrett Albright commentedAndreas, in your example above, what is the path to the root level of the Drupal installation? You have http://localhost/d8/foo in your base path field, but your example uses http://localhost/d7/foo/ .
Comment #11
StevenPatzI am using version 7.x-2.10. All my links except for those for images are working correctly. For image paths I get something like this:
http://www.example.com/CLIENT/?q=files/conference-files/conference2013_c...
If I manually through firebug remove the ?q= the image shows up, confirming that the image exists at that path.
In my Pathologic settings I have the first bullet checked ( Full URL (http://example.com/foo/bar ) and in the "All base paths for this site" section I have /CLIENT/
Is this a settings issue? I am willing and able to test patches etc.
Comment #12
Garrett Albright CreditAttribution: Garrett Albright commentedspatz4000, can I have a bit more info? I presume "CLIENT" is the root directory of your Drupal installation, right? What was your input to get that output?
Comment #13
Garrett Albright CreditAttribution: Garrett Albright commentedIs this still a problem?
Comment #15
mgiffordI'm marking this as closed for now. Feel free to reopen.