tags:

views:

74

answers:

4

I want to add a pdf and word format of my resume to my portfolio page and make it downloadable. Does anyone have some simple script?

+2  A: 

Add a link to the file and let the browser handle the download.

You may be over-complicating the problem. It's possible to use a href pointing to the location of the .pdf or .doc file, when a user clicks on this in their browser, generally they will be asked if they would like to save or open the file, depending on their OS/configuration.

If this is still confusing, leave a comment and I'll explain anything you don't get.

Grundlefleck
A: 

You will want to issue or employ the Content-Disposition HTTP header to force the download otherwise some browsers may recognize the common file extensions and try to automatically open the file contents. It will feel more professional if the link actually downloads the file instead of launching an app - important for a resume I think.

Content-Disposition must be generated within the page from the server side as far as I know.

John K
Unfortunately, "professional" may mean "using IE6" in some industries. IE6 content-disposition support appears very flaky (from the link you provided).
Grundlefleck
It's more of a catch-all than not including it. A special footnote can always be mentioned if IE6 is detected by the page.
John K
Heh, I thought of an alternative way to view the problem: we're programmers, if someone's using IE6 to view our CV, we didn't want the job anyway :-p
Grundlefleck
I usually use Safari. Safari opens PDF files seamlessly as if they were just another web page. It's always jarring to click on a PDF and have it download to a file somewhere on my disk, instead of simply displaying in a browser window (where I can "Save As" if I want to keep a copy).
Greg Hewgill
+1  A: 

Create the PDF. Upload it. Add a link.

Save yourself 30 minutes tossing around with PDFGEN code.

Oli
A: 

Option:

  • Upload your resume to Google Docs.

  • Add a link to the file on your portfolio page just as I do in the menu of my blog:

  • Use Google Docs Viewer passing to it the URL of the PDF as you can see in this link.

Leniel Macaferi