There probably is a module (maybe even multiple ones) to do this, but I can't seem to find it.

I want to add something to my Drupal install so that when I'm editing the content on a page, I can upload and then link to a PDF for that page. Seems like this should be really easy and/or already built in but I can't seem to find how to make it happen. Anyone out there know the quickest, easiest way to do this?

Let me know,
Shaun

Edited by: VeryMisunderstood; Moved to appropriate forum

Comments

vm’s picture

In the future please tag your threads with the version of Drupal in use.

To attach files to nodes, you can enable the upload.module (part of core) and enable attachments on your content types in administer -> content types -> edit content type of choice.

If you want something more advaned you can use the filefield.module and add a field to your content type to allow uploading as well.

shaunwo’s picture

Sorry... we are using Drupal 6.12 on this site.

I think we already have what you described, but I'm looking for something better than that. What you described will list all the attached files at the bottom of the page, won't it? I would like up upload a PDF and have the link to it inline with the rest of the text, behind a 'click for the full report' link or something like that.

So is THAT possible with an additional module on Drupal?

Thanks,
Shaun

WorldFallz’s picture

Once the file has been attached via the upload module, you'll see a url underneath it-- you can simply use that to create an inline link anywhere you want.

Alternatively you might want to checkout the http://drupal.org/project/inline module.

shaunwo’s picture

Argh... I must be missing something, and I really can't see what that might be.

I've installed, enabled and configured BOTH the filefield and inline modules, and according to the documentation on the filefield module page, it works with CCK. And sure enough, it looks like I have everything checked on / enabled there as well when I go to Site Building > Modules, it appears that everything that should be is selected. I've created a few screen shots to help illustrate my problem / what I'm trying to do, and here's the first that illustrates this point: http://www.designchemistry.com/forums/drupal_screen_1.jpg

So then I go to edit a page (we're using the TinyMCE 3.2.4.1 editor), highlight a link and want to revise the link for it: http://www.designchemistry.com/forums/drupal_screen_2.jpg

I am given a pop-up screen, and I see how I can click on the one button to upload a new file: http://www.designchemistry.com/forums/drupal_screen_3.jpg

However, this doesn't give me any options other than for a new image. I want to upload a PDF, and it would be nice to be able to put all documents in their own folder as well, separate from all the images. Here's what I'm currently getting from the upload screen: http://www.designchemistry.com/forums/drupal_screen_4.jpg

I think I'm just missing... something. I'm a Drupal newbie and eager to learn more, but I need another pointer or two in the right direction to get this wrapped up for my client.

Thanks,
Shaun

vm’s picture

The problem is likely editor related. filefield and cck are intended for creating content types and allowing the uploading of files directly through the content type itself using fields.

What it sounds like you need is the ability for the editor in use to upload files other than images. That said you may have to look into adding the IMCE.module to your editor.

I've not used any of "heavy" editors (TinyMCE / FCKeditor) in quite awhile but you will have to find a method to tie into the editor.

In future when you've employed an editor on a drupal installation, make that known right away as it totally changes the responses you will get from those supporting the forums. We'd never have mentioned CCK.module or filefield.module had we known you were trying to tie into an editor.

WorldFallz’s picture

First thing-- I get permission denied on your image links. It would help a great deal if you could fix that so I could see them.

Second, filefield and inline know nothing about tinymce and vice versa. Simply enabling filefield and inline won't add any capabilities to tinymce (which I believe comes with it's own upload and link plugins/buttons). I would recommend reviewing the docs for both the filefield and inline modules.

Also, you can use the filefield_paths module to be able to setup different filefields to store their files in separate locations (but again, tinymce has nothing to do with this).