moose1 Posted September 4, 2015 Share Posted September 4, 2015 Hello, ProcessWire novice here trying to help document managing and linking a bit easier for our site editors. When our editors upload documents to a document container page in the ProcessWire editor and need to grab the URL of any of those documents, they normally just view that document page in a browser and copy the link it from there with a right-click: What I'd like to do is also display these URLs within the editor so people can grab the full URL from there without having to look at it in a browser. From what I can tell, ProcessWire doesn't have an admin field that would allow me to display the results of something like this when a file has been uploaded. echo "<a href=$file->url'>$file->name</a> Should I look for a module for something like? Or is there a way to do this already? Thanks in advance for any suggestions. Russ Link to comment Share on other sites More sharing options...
tpr Posted September 4, 2015 Share Posted September 4, 2015 Kinda hack but I would perhaps just include a js and append the links with jQuery each(). Provided if the full url is constructable on the admin page. Link to comment Share on other sites More sharing options...
LostKobrakai Posted September 4, 2015 Share Posted September 4, 2015 Just click on the filename in the backend. It's a link to the file / image. Link to comment Share on other sites More sharing options...
moose1 Posted September 4, 2015 Author Share Posted September 4, 2015 Just click on the filename in the backend. It's a link to the file / image. This is normally what I'd tell people to do, but we created a function that takes the file upload path and creates a base URL for that document that ends in /download/ instead of the actual file name. This way, once someone uploads a new version of that file, they don't have to hunt down the links to it to update the file extension. For example, this: http://mysite.com/site/assets/files/20008/idf_v2.pdf Gets changed to this: http://mysite.com/site/assets/files/identity-finder/download/ The /download/ URL is available for people to copy from the browser, but I can't figure out how to display this link in the editor, which would save a step. Link to comment Share on other sites More sharing options...
adrian Posted September 4, 2015 Share Posted September 4, 2015 I wonder if the easiest way might be with kongondo's brand new module: https://processwire.com/talk/topic/10804-module-runtimemarkup-fieldtype-inputfield/ 2 Link to comment Share on other sites More sharing options...
moose1 Posted September 4, 2015 Author Share Posted September 4, 2015 I wonder if the easiest way might be with kongondo's brand new module: https://processwire.com/talk/topic/10804-module-runtimemarkup-fieldtype-inputfield/ Ah, yes, this might be the ticket. Thanks very much for the suggesstion, Adrian. I will certainly take a look!. Link to comment Share on other sites More sharing options...
Mats Posted September 4, 2015 Share Posted September 4, 2015 This module renders a download link for imagefields. https://github.com/madebymats/ImageDownload 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now