How to Upload and Link to a PDF File in KompoZer and Nvu

Publishing a PDF Ebook on Your Website

How to Upload and Link to a PDF File (or PDF Ebook) in KompoZer and Nvu

by Christopher Heng,

Following my article on How to Upload and Link to a PDF File (or PDF Ebook) with Dreamweaver, I was asked for the procedure for doing the equivalent using a free web editor. This article provides a step by step guide for publishing your own PDF ebook on your website using either KompoZer or Nvu.


The Use and Abuse of PDF Files

PDF files are handy for publishing electronic books (ebooks) on a website. For example, some authors, in addition to selling their printed book, also provide an electronic version on their website. Others publish a few chapters of their book in a PDF form, as a form of teaser for their printed copy. These are acceptable uses of the PDF format.

Do not, however, use the PDF format to substitute for things that should be ordinary web pages. For example, don't make your entire website a PDF file or a series of inter-linked PDF files. PDF files create a poor user experience on your website. Using them for your ebook is great, but don't use them to replace your normal web pages.

Guide on Linking and Publishing a PDF File with KompoZer or Nvu

  1. Copy your PDF file into the folder on your own computer where you placed a copy of your website. To make it less likely that you'll make a mistake later, you should probably place the PDF file into the very same folder which contains the web page linking to it. Note that I'm talking about your own computer, and not your web host's computer. If you have followed my main KompoZer tutorial series, you will have a copy of your website located somewhere on your own computer. To repeat: place the PDF file in the same folder as the page where you plan to place the link.

    If you don't know how to copy a file and you use Windows XP, click the Start menu, followed by "My Computer" on the menu that appears. Vista users will have to click the multi-coloured round button/icon on the bottom left of your monitor, followed by "Computer" on the menu that appears. A window will open. Navigate to the place where you have currently saved your PDF file. (I can't tell you where you saved it since I'm not psychic, so you'll just have to find it yourself. Start by looking in your Desktop folder and your Documents (or My Documents) folder since chances are higher that it is somewhere there.)

    Once you've found the file, right click the file. That is, click your right mouse button when your mouse cursor is over the file. A menu will appear. Click the "Copy" item on the menu that appears.

    Then using the same window, navigate to the folder where you keep the web page that will link to the PDF file. Again, I can't tell you where that is; only you will know where you've placed it. The folder probably has other files inside, including a file called "index.html" or "index" (depending on whether you've configured windows to show you the full filename).

    Right click in a blank spot in that folder, and in the menu that appears, click "Paste". Windows will copy the file to that folder.

  2. Start up either KompoZer or Nvu and open the web page where you want to place the link.

    Note: if you don't know how to do the above, please read the main KompoZer or Nvu tutorial series first.

  3. Select the words on the page that you wish to make into a link to point to the PDF file. For example, if you want to change the words "Download my PDF eBook" into a clickable link leading to your PDF ebook, drag your mouse over those words to highlight them. If you haven't written any relevant phrases that you can change into a link, type some now (eg, type "Download my ebook") and select them.

  4. With the words selected, click "Insert | Link...". That is, click "Insert" from the menu, and then click "Link..." on the menu that appears. A dialog box entitled "Link Properties" will appear.

  5. If you use Nvu, click the "Choose File..." button. KompoZer users should click the folder icon beside the blank "Link location" box. A dialog box labelled "Open HTML File" will appear.

  6. Near the bottom of that dialog box, click the down arrow for the "Files of type" field to reveal a drop down box. Select "All Files" from that box. The list of files in the box will now show files of any sort that are present in that folder. If you have followed my instructions earlier and copied your PDF file into the same folder as the page you're linking from, you should be able to see it now. Click it to select it, followed by the "Open" button. Then click the "OK" button.

  7. The web editor should now show a blue underlined link in place of the normal text. (You can't click it yet, of course, since you're still in an editor, and not a web browser.)

    Save the page and publish it. KompoZer and Nvu will proceed to publish your web page onto your website. At this point, however, your PDF file has not yet been uploaded. Unlike the Dreamweaver web editor, neither KompoZer (as of version 0.7.10) nor Nvu will upload the PDF file for you. You will need to manually upload it yourself.

    To do this, please see my guide How to Upload a File to Your Website Using the FileZilla FTP Client. The article is a general guide on how to upload any file using a special type of program called an FTP client. Simply follow its instructions to upload your PDF file. Be sure to upload it to the correct folder on your web host; as mentioned before, put it in the same folder as the web page linking to it.

    Note: if your site is a "live" website with an existing stream of visitors, you may want to defer the publication of your web page till after you upload your PDF file. That is, first use the FTP client to upload your PDF file, and, after it's done, use KompoZer to publish your web page. Otherwise, visitors arriving at the page between the time you published it and the time you uploaded the PDF file may click the link only to get your 404 File Not Found error page.

That's it. Once you've uploaded everything, start up your web browser and test the uploaded page. Click the link to the PDF file. Depending on how you have configured it, your browser will either open the file within its window or offer to save it onto your hard disk. If either of these things occur, it means that you have successfully published your PDF file and linked to it.

Copyright © 2009-2013 by Christopher Heng. All rights reserved.
Get more free tips and articles like this, on web design, promotion, revenue and scripting, from

thesitewizard™ News Feed (RSS Site Feed)  Subscribe to newsfeed

Do you find this article useful? You can learn of new articles and scripts that are published on by subscribing to the RSS feed. Simply point your RSS feed reader or a browser that supports RSS feeds at You can read more about how to subscribe to RSS site feeds from my RSS FAQ.

Please Do Not Reprint This Article

This article is copyrighted. Please do not reproduce or distribute this article in whole or part, in any form.

Related Pages

New Articles

Popular Articles

How to Link to This Page

It will appear on your page as:

How to Upload and Link to a PDF File (or PDF Ebook) in KompoZer and Nvu

Link to Us
Site Map

Getting Started
Web Design
Search Engines
Revenue Making
Web Hosting
Perl / CGI
.htaccess / Apache


Free webmasters and programmers resources, scripts and tutorials Free How-To Guides
Site Design Tips at
Find this site useful?
Please link to us.