Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2006-11-01 16:54:18

lee
Member
From: Normandy, France
Registered: 2004-06-17
Posts: 831

Download/run a .pps file

Anyone know how get a download link to look like: http://www.website.com/file_download/demo.pps and not http://www.website.com/file_download/1

Clicking on a link with file_download/demo.pps causes PowerPoint to open, the other way it just downloads the file.

(I’ve uploaded demo.pps file in admin)

Thank you, Lee

Offline

#2 2006-11-01 18:36:40

wet
Developer Emeritus
From: Schoerfling, Austria
Registered: 2005-06-06
Posts: 3,330
Website Mastodon

Re: Download/run a .pps file

Either enter a manual link including the filename (Textpattern will allow both /file_download/id and /file_download/filename.ext links), or wait for the next Txp version.

Offline

#3 2006-11-01 18:45:12

lee
Member
From: Normandy, France
Registered: 2004-06-17
Posts: 831

Re: Download/run a .pps file

Thanks Robert. How risky is it to use that latest change set?

Offline

#4 2006-11-01 18:54:51

wet
Developer Emeritus
From: Schoerfling, Austria
Registered: 2005-06-06
Posts: 3,330
Website Mastodon

Re: Download/run a .pps file

No risk, no fun ;-)

But seriously: I use the latest version from SVN on my site, and it just works as expected (though my site is currently in a Jo-Jo mood going up and down all day long, but this is a totally different story on how the leave of a single capable person can affect a whole hosting company).

Give it a try, you can always revert by simply overwriting all files with the released version.

Offline

#5 2006-11-01 19:10:21

lee
Member
From: Normandy, France
Registered: 2004-06-17
Posts: 831

Re: Download/run a .pps file

Cheers, I’ll get it now.

Offline

#6 2006-11-01 19:47:59

lee
Member
From: Normandy, France
Registered: 2004-06-17
Posts: 831

Re: Download/run a .pps file

Robert, I’v got the latest change set installed but haven’t managed to figure out how to include file name in file download url. Any suggestion? There is nothing in the tab builder to include the filename.

Cheers, Lee.

Offline

#7 2006-11-01 19:53:33

wet
Developer Emeritus
From: Schoerfling, Austria
Registered: 2005-06-06
Posts: 3,330
Website Mastodon

Re: Download/run a .pps file

No, the tag builder doesn’t show the new possibilites yet. But if you use <txp:file_download_link id="xxx"> or <txp:file_download_link filename="xxxxxx.ext">, the resulting <a> tag’s href attribute will include a trailing filename.

Last edited by wet (2006-11-01 19:53:48)

Offline

#8 2006-11-01 20:05:52

lee
Member
From: Normandy, France
Registered: 2004-06-17
Posts: 831

Re: Download/run a .pps file

Thanks again, you’re seriously on the ball! Why don’t you see if you can get on the dev team?

Offline

#9 2006-11-01 20:12:00

wet
Developer Emeritus
From: Schoerfling, Austria
Registered: 2005-06-06
Posts: 3,330
Website Mastodon

Re: Download/run a .pps file

Thanks for the flowers ;-)

Offline

Board footer

Powered by FluxBB