Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#1 2007-01-29 09:13:05
- azw
- Member
- Registered: 2007-01-29
- Posts: 279
SOLVED: Want to link to a PDF file in an article. What's best method?
I want to briefly describe a PDF and give a link to it that will open in the same browser window. How do I link to it?
This page was helpful: http://rpc.textpattern.com/help/?item=link
Using that I tried these code (along with uploading the PDF to TXP):
"LINK TEXT(hover text)":/file_download/1
The problem is that only available as a download.
Can I store the PDF in TXP and have it open automatically in the browser?
Is there a better way to do this?
Last edited by azw (2007-01-30 02:25:30)
Offline
Re: SOLVED: Want to link to a PDF file in an article. What's best method?
"link text":/path-to-file/filename.pdf
Offline
#3 2007-01-29 19:20:53
- azw
- Member
- Registered: 2007-01-29
- Posts: 279
Re: SOLVED: Want to link to a PDF file in an article. What's best method?
Thanks for replying, Wet.
Is there a way to do this within Textpattern? Or do you have to upload the file by an external FTP program?
Offline
Re: SOLVED: Want to link to a PDF file in an article. What's best method?
You can upload the file within Textpattern. Check the Content/File tab.
Offline
#5 2007-01-30 01:28:48
- azw
- Member
- Registered: 2007-01-29
- Posts: 279
Re: SOLVED: Want to link to a PDF file in an article. What's best method?
Thanks for the response, Jeremie.
I must be misunderstanding something.
If I FTP my .PDF to the server, I can open it in a link just fine. In that case, I write the link like this:
"A title for the file(some hover text for the file)":http://myURL.com/Folder/FileNamei.pdf
That works, but the file isn’t uploaded and stored within TXP.
So how do I like to a file uploaded in TXP? I’ve tried this:
"A title for the file(some hover text for the file)":/file_download/1
Clicking the resulting link brings up a small window asking if I want to save the file to my hard drive. I want it to open in the browser window, no questions asked.
Last edited by azw (2007-01-30 01:29:21)
Offline
Re: SOLVED: Want to link to a PDF file in an article. What's best method?
"A title for the file(some hover text for the file)":/files/name-of-your-file.pdf
(assuming you’ve installed txp in your webservers root, otherwise it would be, /pathtoyoursite/files/ )
Last edited by sthmtc (2007-01-30 01:54:42)
Offline
#7 2007-01-30 02:25:10
- azw
- Member
- Registered: 2007-01-29
- Posts: 279
Re: SOLVED: Want to link to a PDF file in an article. What's best method?
Okay, I’ve got it!
Thanks for the help, Sthmtc, Jeremie, & Wet.
One of the problems was that I had forgotten that I gave an uploaded file folder a non-standard name.
By the way, it appears that Sthmtc’s first solution:
"A title for the file(some hover text for the file)":/files/name-of-your-file.pdf
works equally well if TXP is installed on a subdomain, which is as it should be.
Thanks again!
Offline