Closed (works as designed)
Project:
Linkit
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Task
Assigned:
Reporter:
Created:
5 Nov 2010 at 13:23 UTC
Updated:
8 Feb 2011 at 23:55 UTC
I needed the ability to link directly to files so I created a new plugin, Linkit File.
It does not use Pathologic filter as there is no support for a file: prefix.
Perhaps there is a way around this. Anyway, see attached patch.
| Comment | File | Size | Author |
|---|---|---|---|
| linkit_file.patch | 1.84 KB | peter törnstrand |
Comments
Comment #1
anonNice, I will include this into Linkit as its a "drupal core functionality" with upload files.
I have also had some thoughts about the filter problem.
We already have this issue in linkit_views and linkit_panels_pages, and btw, I dont think linkit_views should even be in Linkit core anymore. Views is a optional module to install and not part of the D-core.
I have had some thoughts about making my own filter, pathfilter and pathologic isnt really usefull for anything thas not basically a node or term.
If we do our own filter, this most be very well thought-out, and support backward compatible with the two "older" filters.
Let me give you some example for a filter.
If anyone has some feedback or ideas on this, you are more the welcome!!
Comment #2
peter törnstrand commentedIs it not possible to approach the Pathologic team and perhaps supply a few patches to implement filter support for views, files, panels etc?
Comment #3
anonCould be possible, I havent tried.
Pathologic has 4006 users
Path filter has 4003 user
So I think we should provide patches for both, or just favor one of them really good.
Pathologic seems more active tho, last relese 2010-Oct-29, and last commit 2 weeks ago.
Comment #4
peter törnstrand commentedI think you should focus on one module and my choice would be Pathologic.
Comment #5
anonYour patch is committed to 6.x-1.x-dev. This will be available in the 6.x-1.8 release
Thanks
Comment #7
tseven commentedThe function 'file_create_url' creates a full url. I'm not sure why this is needed. Simply removing this function allows the files relative path of "sites/default/files/filename.pdf" to be used.
This works better with multi-domain sites.
If both methods are desirable, can we add a setting to switch between the two?
Thanks
Comment #8
anonI'm not sure why this is needed
file_create_url()checks if you have public or private filesystem for your site.For D6
http://api.drupal.org/api/drupal/includes--file.inc/constant/FILE_DOWNLO...
http://api.drupal.org/api/drupal/includes--file.inc/constant/FILE_DOWNLO...
Same in D7, But it also "converts" the URI from the database to something usfull.
The URI from the DB is like "public://field/image/images-123.jpg".
Comment #9
anonSee #1055638: Linkit inserts absolute URI to files