Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#133 2017-10-20 06:51:21
- quiris
- New Member
- Registered: 2015-12-31
- Posts: 8
Re: [plugin] [ORPHAN] upm_file: Associate single or multiple files with an article.
After upgrading Textpattern to 4.6.2 the upm_article_file_list tag throws errors similar to:
<b>Fatal error</b>: Uncaught ArgumentCountError: Too few arguments to function file_download_link(), 0 passed in /bip/textpattern/publish/taghandlers.php(4337) : eval()'d code on line 1 and at least 1 expected in /bip/textpattern/publish/taghandlers.php:4794 Stack trace: #0 /bip/textpattern/publish/taghandlers.php(4337) : eval()'d code(1): file_download_link() #1 /bip/textpattern/publish/taghandlers.php(4337): eval() #2 [internal function]: php(Array, 'echo file_downl...') #3 /bip/textpattern/vendors/Textpattern/Tag/Registry.php(83): call_user_func('php', Array, 'echo file_downl...') #4 /bip/textpattern/lib/txplib_publish.php(514): Textpattern\Tag\Registry->process('php', Array, 'echo file_downl...') #5 /bip/textpattern/lib/txplib_publish.php(463): processTags('php', '', 'echo file_downl...') #6 /bip/textpattern/lib/txplib_misc.php(1782) : eval()'d code(87): parse('<a href="<txp:p...') #7 [internal function]: upm_article_file_list(Array, NULL) #8 /bip/textpattern/vendors/Textpattern/Tag/Registry.php(83): call_user_func('upm_arti in <b>/bip/textpattern/publish/taghandlers.php</b> on line <b>4794</b><br />
Any suggestions?
Offline
#134 2017-10-20 08:41:47
Re: [plugin] [ORPHAN] upm_file: Associate single or multiple files with an article.
upm_file is very old. Can you post the form you are using with upm_article_file_list and the output you expect to receive and we can perhaps suggest a replacement that uses the regular txp tags?
TXP Builders – finely-crafted code, design and txp
Offline
#135 2017-10-20 10:55:44
Re: [plugin] [ORPHAN] upm_file: Associate single or multiple files with an article.
Not sure it’s a plugin error, probably 4.6 Textile parser is just more strict and requires wrapping txp tags between ==
or in notextile.
section.
Offline
#136 2017-10-20 12:16:48
- quiris
- New Member
- Registered: 2015-12-31
- Posts: 8
Re: [plugin] [ORPHAN] upm_file: Associate single or multiple files with an article.
jakob wrote #307480:
upm_file is very old. Can you post the form you are using with upm_article_file_list and the output you expect to receive and we can perhaps suggest a replacement that uses the regular txp tags?
Thank you for the tip. I replaced upm_article_file_list with following code:
<p>Do pobrania:</p> <txp:file_download_list id='<txp:custom_field name="pliki" />' wraptag="ul" break="li"> <txp:file_download_link> <txp:file_download_description /> </txp:file_download_link> </txp:file_download_list>
It works fine now :)
Offline
#137 2017-10-20 16:58:06
Re: [plugin] [ORPHAN] upm_file: Associate single or multiple files with an article.
quiris wrote #307482:
I replaced upm_article_file_list with following code…
Yes, exactly what I was thinking. Well done!
TXP Builders – finely-crafted code, design and txp
Offline