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 ForumsRepositoryRepositoryFILE and URLCONTROLFILE questionsFILE and URLCONTROLFILE questions
Previous
 
Next
New Post
12/18/2009 6:27 PM
 

Hello,

I'd like to use the Repository to hold product information PDFs. I'd like to have the user upload an image of the product and a PDF file with that product's info. Then, I'd like to show the products and have the image be a link to the PDF. I can create the image hyper link using [FILEURL] but it returns the mangled name which is kind of cumbersome for the user.

I've read about using URLCONTROLFILE in the form.html file so that the filename doesn't get mangled but, since the user can basically put the file anywhere, I'm not sure how the display template could figure out where it was to be able to construct a link to it. I'd really rather get the functionality of the DOWNLOAD token (with download counting) but have it attached to my image instead of the word "Download".

Is there a way to do this?

Thanks,

Tom

 
New Post
12/28/2009 8:57 AM
 

when you use the URLCONTROL versions of the upload controls, the file is uploaded and an entry is written to the core Files table. The uploaded file is assigned a unique ID. So if you then look in the Repository tables, instead of a filename, you'll see something like "FileID=22". That tells the repository module to look in the core file table to get all of the information about the file with the ID of 22 to get information about the file, like the actual filename, the folder location where the file can be found, it's size, etc.  The token processor in the module is smart enough to recognize a file uploade by the URL control by seeing the FileID=n format, so the correct information is output to the page.

Not sure exactly what you mean with your second question ...I blogged about using graphics for buttons instead of 'text' (ie: Download) .. here's a link to the blog.  NOTE: There appears to be some navigation issue to older blog posts, so when you click on the link below it will appear to take you to the Reports project page, but just scroll down, you'll see my blog entry

http://www.dotnetnuke.com/Development...

 If you want the thumbnail to trigger the download link., just add a DOWNLOAD setting to the IMAGE token in the template.xml file and set it's value to True, then the thumbnail image will act as the download button

 

 
New Post
1/18/2010 3:13 PM
 

Steve,

First thank you for answering so many questions about the Repository. It's very helpful.

I was able to get the image to be clickable... per your answer. Is there a way to make the thumbnail clickable too? I tried the same thing, but no luck.

   <Object>
  <Token>[IMAGE]</Token>
      <Settings>
         <Setting>
           <Name>DOWNLOAD</Name>
           <Value>true</Value>
         </Setting>
      </Settings>
 </Object>
 <Object>
  <Token>[THUMBNAIL]</Token>
  <Settings>
   <Setting>
    <Name>Width</Name>
    <Value>100</Value>
   </Setting>
  </Settings>
      <Settings>
         <Setting>
           <Name>DOWNLOAD</Name>
           <Value>true</Value>
         </Setting>
      </Settings>
 </Object>

 

Thank you for your time.

 

 
New Post
1/18/2010 4:46 PM
 

There's really not much different between the IMAGE and THUMBNAIL tokens. Actually the only difference is that the IMAGE token support the optional DOWNLOAD setting. 

I'm not sure I see a use case with you would use both the IMAGE and the THUMBNAIL tokens in the same template. There is one image associated with a Repository upload. You should just be able to use the IMAGE token instead of the THUMBNAIL token if you want the image to be used as a download button. 

Both the IMAGE and the THUMBNAIL token will display the one image associated with the upload, so it makes no sense to use both of them at the same time that I can think of.

 
New Post
1/18/2010 5:21 PM
 

I personally don't have a problem with the [IMAGE] token.

I may just be missing something. Is there a way to force the Image to a certain size?

The people uploading images have no idea if they are uploading a 100pxx100px image or a 1000px x 1000px image.

I need to be sure the images show up approximately the same size.

 

 

 
Previous
 
Next
HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsRepositoryRepositoryFILE and URLCONTROLFILE questionsFILE and URLCONTROLFILE questions


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