All questions about EDocman extension

Link to document direct from Article

  • Janet Pearson
  • Topic Author
  • Offline
  • New Member
  • New Member
More
9 years 9 months ago #46814 by Janet Pearson
Link to document direct from Article was created by Janet Pearson
Is there any way to link from an article directly to a document WITHOUT being transferred to the download page (with its info on hits, created dates etc) so that it just starts the download immediately?
We use eDocman on a site to manage all its PDF forms in one place (using the standard download documents table) but when we want to insert a particular PDF file into an article using the eDocman plugin, anyone clicking on the resulting link should be able to just download the PDF. they don't understand why they must be transfered to another page full of info they don't understand or need to know to then have to click a download button to get the document.
I'd really like to see a way to bypass this step. Is it possible?
I realise that we could just use the media manager but for the most part, eDocman is a great repository and it is occasionally that we need to link to one or two documents from an article.
Love to know if there is a workaround, even if we need to put in a code over-ride to do so.

Please Log in or Create an account to join the conversation.

More
9 years 9 months ago #46858 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Link to document direct from Article
Hi Janet

Go to Extensions -> Plugins Manager, find the plugin "EDocman Document Link", Click on it to edit. There is a parameter called Link Type. Please set it to Add Link to Download Document

From now on, when you insert link into article, users can click on that link to download document without having to be redirected to document detail page.

Please try it and let me know the result

Regards,

Tuan
The following user(s) said Thank You: Janet Pearson

Please Log in or Create an account to join the conversation.

  • Janet Pearson
  • Topic Author
  • Offline
  • New Member
  • New Member
More
9 years 9 months ago #46864 by Janet Pearson
Replied by Janet Pearson on topic Link to document direct from Article
Worked beautifully!

Please Log in or Create an account to join the conversation.

More
9 years 9 months ago #46865 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Link to document direct from Article
Thanks Janet. Hope you like my extension. If you have few minutes (and haven't rated for EDocman before), please help us by giving EDocman your rating and review at extensions.joomla.org/extensions/directo...tion/downloads/18008 to support my development.

Hope you will give it a 5 stars rating :).

Regards,

Tuan

Please Log in or Create an account to join the conversation.

More
9 years 6 months ago #50374 by mike
Replied by mike on topic Link to document direct from Article
Hello,

In my case, insted of downloading the document directly after clicking the link, I want the pdf doc to be shown at browser and visitor can read the pdf doc without download.
How can I configure it?

Regards

Please Log in or Create an account to join the conversation.

More
9 years 6 months ago #50400 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Link to document direct from Article
Hi Mike

In this case, we will need to edit the plugin code to change the link from download to view document. Please submit a support ticket sending us super admin and FTP account of your site so that we can help you to do that.

Also, please note that when view the document, it is the web browser rendering the PDF document for viewing and it always display an option to allow users to save/download the document and we could not prevent it.

So even the document will be opened for viewing, users will still be able to save it if they want

Tuan

Please Log in or Create an account to join the conversation.

More
7 years 7 months ago - 7 years 7 months ago #87220 by Reto Cotting
Replied by Reto Cotting on topic Link to document direct from Article
Hello,
Sorry for digging up an old thread.. I am in the exact same situation as OP: I need to change the direct download document links in articles to open in a new tab (=change from download to view). Could you quickly point me in the right direction for which files I would need to edit?
Thanks in advance!
--Edit: Nevermind, after a bit more digging I found it out on my own.
Last edit: 7 years 7 months ago by Reto Cotting.

Please Log in or Create an account to join the conversation.

More
7 years 6 months ago #88273 by Vladimir Stupar
Replied by Vladimir Stupar on topic Link to document direct from Article
Hello Reto,
can you please share what did you do. I need exactly the same funcionality.
Thanks

Please Log in or Create an account to join the conversation.

More
7 years 6 months ago #88282 by Reto Cotting
Replied by Reto Cotting on topic Link to document direct from Article
Hey, sorry I can't help much, I did this directly on a live server and I can't tell you exactly what files I modified - there was no Version control for this.

But I found this file that I edited: edocman.php (don't know where exactly it is).

I replaced the line 23:
Code:
var tag = '<a href='+'\"index.php?option=com_edocman&amp;task=document.download&amp;id='+id+'\">'+title+'</a>';
with
Code:
var tag = '<a href='+'\"index.php?option=com_edocman&amp;view=document&amp;id='+id+'\">'+title+'</a>';

Sorry I can't be much help, I hope this might point you in the right direction.

Please Log in or Create an account to join the conversation.

More
7 years 6 months ago #88333 by Vladimir Stupar
Replied by Vladimir Stupar on topic Link to document direct from Article
Hi Reto, thanks for your answer, it really did pointed me in the right direction, so I think I managed to find a solution.
The file I edited (edocman.php) is in home/plugins/editors-xtd/edocman, but instead of line 23 I modified line 25 (probably different version of Edocman).

Instead:
Code:
var tag = '<a href='+'\"index.php?option=com_edocman&amp;task=document.download&amp;id='+id+'\">'+title+'</a>';

I put:
Code:
var tag = '<a href='+'\"index.php?option=com_edocman&amp;task=document.viewdoc&amp;id='+id+'\" target=\"_blank\">'+title+'</a>';

This way, instead of downloading, files are being opened in the new tab.

Please Log in or Create an account to join the conversation.

Moderators: Mr. Dam