Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsRepositoryRepositoryLink to document in repositroyLink to document in repositroy
Previous
 
Next
New Post
12/6/2007 2:53 PM
 

I have seen several threads on this, but no real answers.  I have a repository setup with about 50 pdf documents in it.  I would like to link from another page to the directly to the individual document in the repository module.  If the surfer wants he can then download.  What I have setup now is a link to the repository page and then the surfer needs to locate the correct document.  If I could link to the individual document I would be golden.  Any ideas???

 
New Post
12/6/2007 3:43 PM
 

here's the definitive answer ...

it depends on what you mean by "directly to the individual document".

That can be intepreted 2 ways. 

1) when a user clicks on a link, they should be redirected to the page with the repository module that contains the document and that document should be displayed, at which point they can download the file by clicking on the DOWNLOAD link associated with that item.

2 ) when a user clicks on the link, they should see the File Save Dialog box popup and they should be able to open or save the document without them being redirected to another page. 

You CAN do #1 right now. By including a [PERMALINK] tag in your repository template.html file. The tag will generate a URL that use can then use on any page or other module. So, to use the [PERMALINK] feature you would do the following...

1. add a [PERMALINK] tag to your template.html file in the location where you want the hyperlink generated
2. upload item(s) to your repository module
3. for each item displayed you will see a hyperlink titled 'Permalink'. Right-click on the hyperlink and select "Copy Shortcut" .. or just click on the Permalink hyperlink and then when the repository page is displayed, copy the URL from the Address bar.
4. now, on another page, you can insert a link in an HTML/Text module or any other type of module and paste the Permalink URL.

When a user clicks on that hyperlink, they will be redirected to the page with the repository module and ONLY that specific file will be displayed, they do NOT have to search for it. The Permalink will filter the repository module to only display that one item. The user can then download the file associated with the item by clicking on the DOWNLOAD link.

if you are looking for #2 ... then no, you cannot craft a link ( and by link I mean a standard URL that could be used in an HTML/Text module or any other moduel ) that will result in a repository document being directly downloaded without redirecting to the page where the repository module resides.

So, the obvious question is ... why the hell not???

answer: the current version of the repository module ( and I am only referring to the current version, all of this will be thrown out the window when 4.00.00 is release which is a complete re-design of the module ) there are a couple of features that the module adds above and beyond a simple documents module. The first is security. Security is enforced at runtime when the repository page is displayed. The current user's security roles are compared to the module's settings to see if the user should be able to download items from that particular repository. Since the code to do this validation is part of the repository module, having a URL link on another page that attempts to access a physical file stored within the portal's folder structure will not execute that code so there is no way to enforce any security restrictions. Secondly is counting the number of downloads. Again, the logic to increment the number of times a file is downloaded is implemented within the repository module's code. So if the repository module itself is not being displayed, then it's code is not being executed, and the code that updates the number of downloads is not being executed, so you lose that basic functionality with a direct link.

I hope that's clear and you understand the issue, and hopefully, option #1 will suffice for now. And as I said, with 4.00.00 it will be a whole new ballgame, but that's not going to help you today.

 
New Post
12/7/2007 11:17 AM
 

Scenario 1 is exactly what I need.  I tried adding the [PERMALINK] tag to the niftytoggle template.html, but it doesn't show up on anything.  Do I need to refresh?  Do I need to add something somwhere else.  I am a newbie and am learning as I go, but I guess I am a little dense and I am not really a programmer, I just follow directions and sometimes I can get it to work.  Any additional help would be appreciated.

 
New Post
12/12/2007 10:31 AM
 
 
New Post
12/18/2007 11:30 AM
 

I have read thru the thread you sent.  It does not explain how to setup the permalink so it displays.  I tried adding [PERMALINK] token to my html template, but nothing shows up.  I am at a loss and my client is very anxious.  Can you give me any further help????

 
Previous
 
Next
HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsRepositoryRepositoryLink to document in repositroyLink to document in repositroy


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out