Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#85 2009-01-11 00:13:31

mrjysta
Member
Registered: 2008-09-22
Posts: 89

Re: [plugin] [ORPHAN] upm_file: Associate single or multiple files with an article.

Hi, I have the plug-in working with a custom field and will be adding 2 different files (1 pdf and 1 mpegVideo) each with a different category. My problem is I’m not sure how to apply a different class to each? (using the if/else tags or file_category eg:

<ul class=“pfile_links”>
<li><a class=“cv” href =”#”>Download CV</a></li>
<li><a class=“showreel” href =”#”>Download Showreel</a></li>
</ul>

Can I use something like:
<txp:if_upm_article_file_list category=“cvs”><txp:upm_article_file_list class=“cv” wraptag=“a” break=“li” /><txp:else/>…

OR
<txp:upm_article_file_list file_category=“cvs” limit=“1” class=“cv” wraptag=“a” break=“li” />
<txp:upm_article_file_list file_category=“showreel” limit=“1” class=“showreel” wraptag=“a” break=“li” />

prob a newbie question but this is the first time I have played with download lists and this plug-in/

Thanks

Offline

#86 2009-01-11 20:13:06

Mary
Sock Enthusiast
Registered: 2004-06-27
Posts: 6,236

Re: [plugin] [ORPHAN] upm_file: Associate single or multiple files with an article.

Off the top of my head:

<txp:upm_article_file_list sort="category asc" form="files" wraptag="ul" class="pfile_links" break="li" />

“files” form:

<a class="<txp:file_download_category />" href="<txp:file_download_link />" Download <txp:file_download_category title="1" /></a>

Last edited by Mary (2009-01-11 20:14:33)

Offline

#87 2009-01-11 20:27:49

mrjysta
Member
Registered: 2008-09-22
Posts: 89

Re: [plugin] [ORPHAN] upm_file: Associate single or multiple files with an article.

Ah! – Brilliant, thanks Mary!

Offline

#88 2009-01-28 14:40:51

amordecosmos
Plugin Author
From: London (Hometown: Vancouver)
Registered: 2004-08-03
Posts: 106
Website

Re: [plugin] [ORPHAN] upm_file: Associate single or multiple files with an article.

Does this work with 4.0.8?

I have installed the plugin, chosen my custom field, but there is no file picker in the write tab.

And replacing ‘txp:article’ with ‘upm_file_article’ results in a blank.

Offline

#89 2009-01-28 18:56:19

Mary
Sock Enthusiast
Registered: 2004-06-27
Posts: 6,236

Re: [plugin] [ORPHAN] upm_file: Associate single or multiple files with an article.

Don’t know, haven’t tested it. Could likely be it needs updating, since the two recent updates made changes to articles.

Offline

#90 2009-01-29 09:02:32

redbot
Plugin Author
Registered: 2006-02-14
Posts: 1,410

Re: [plugin] [ORPHAN] upm_file: Associate single or multiple files with an article.

amordecosmos wrote:

Does this work with 4.0.8?
I have installed the plugin, chosen my custom field, but there is no file picker in the write tab.
And replacing ‘txp:article’ with ‘upm_file_article’ results in a blank.

Seems to work ok for me. Keep in mind though, that I’m using only the “upm_article_file_list” tag.
Regarding the file picker you should install another plugin upm_file_popper.

Offline

#91 2009-01-30 11:11:19

amordecosmos
Plugin Author
From: London (Hometown: Vancouver)
Registered: 2004-08-03
Posts: 106
Website

Re: [plugin] [ORPHAN] upm_file: Associate single or multiple files with an article.

Thank you Redbot, that was clear and helpful. Works great now.

Offline

#92 2009-02-08 15:35:02

midmood
Member
From: Rome, Italy
Registered: 2007-07-20
Posts: 68
Website

Re: [plugin] [ORPHAN] upm_file: Associate single or multiple files with an article.

I have a problem with the plugin

here it works:
http://www.womm.it/artre/progetti/32/un-progetto-psicologia-scolastica

here it doesn’t work (error 403 forbidden)
http://www.artre.coop/cooperativa/5/organizzazione

The second one is a different installation of textpattern, the first one were some design experiment before putting the site online.

I suppose the problem is given by some interaction with plugin i installed in the second installation and not in the first (i.e. hak_tinymce, or rss_admin_show_adv_opts, or lam_image_uploader).

Anyway… even upm_file_popper has a different behaviour: instead of popping me the window with the file picker, it opens a different tab in my firefox…
( i tried with different browsers in case was a security issue, but no)

can you help me please? it’s really important

UPDATE: tried reinstalling upm_file and upm_file_popper, but no result…

Last edited by midmood (2009-02-08 15:53:41)

Offline

#93 2009-02-08 16:28:53

midmood
Member
From: Rome, Italy
Registered: 2007-07-20
Posts: 68
Website

Re: [plugin] [ORPHAN] upm_file: Associate single or multiple files with an article.

OK, i found the problem. Hope this helps

I inserted the upm_file tag in a page which need username and password to access to,

so, in every page, even the public ones, i can download the file by clicking it only if i’m logged in (doesn’t matter what user i am and which privileges i have)

I need the files in public pages to be downloaded by every visitor, even if not logged
Is there a way to fix this?

thank you
Simone (Italy)

UPDATE: please note: right clicking the file i can download something, but the file downloaded is corrupted

Last edited by midmood (2009-02-08 16:30:29)

Offline

#94 2009-02-08 22:04:22

Mary
Sock Enthusiast
Registered: 2004-06-27
Posts: 6,236

Re: [plugin] [ORPHAN] upm_file: Associate single or multiple files with an article.

I’m confused.

Are you saying your entire site is password protected but you want file downloads to not be? If so, it would depend upon how you’re achieving the password protection. That’s really outside the scope of the plugin support (since it’s nothing to do with the plugin itself), but I can see if I can help you figure it out.

If that’s not what you mean, can you elaborate further?

Offline

#95 2009-02-08 22:12:42

midmood
Member
From: Rome, Italy
Registered: 2007-07-20
Posts: 68
Website

Re: [plugin] [ORPHAN] upm_file: Associate single or multiple files with an article.

Mary wrote:

I’m confused. Are you saying your entire site is password protected but you want file downloads to not be?

No, I wasn’ìt clear cause of my bad english :-)
but now i have more information!

only a single template page is password protected. But the plugin behaviour is the same in the whole website

every single download, even in the public pages, needs the visitor to be logged as ADMIN in the private page to work fine.

i can’t give you my admin password but trust me, i created a user for each privs level and the only one that work is admin. for the other users and the generic visitor downloads are forbidden.

thank you for your reply anyway :-)

Last edited by midmood (2009-02-08 22:28:51)

Offline

#96 2009-02-08 23:39:51

Mary
Sock Enthusiast
Registered: 2004-06-27
Posts: 6,236

Re: [plugin] [ORPHAN] upm_file: Associate single or multiple files with an article.

So this would be a Textpattern core tag or plugin tag that is doing the password protection? You don’t need to give me passwords or anything, but how your protection works is relevant.

The actual download of files is handled by Textpattern itself (and it doesn’t protect file downloads in any manner), all my plugin does is provide links to them.

Offline

Board footer

Powered by FluxBB