Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#16 2010-12-03 19:49:51
- redbot
- Plugin Author
- Registered: 2006-02-14
- Posts: 1,410
Re: bot_file_upload: upload and edit files from within the write tab
Version 0.3 released.
This version works only for txp 4.3. For txp 4.2 use v. 0.2.
Changes
- Code partly rewritten – more tidy
- Page elements are targeted using the hooks provided by the new txp 4.3 html markup – simpler code
- Different styling – now it looks more like a ‘typical’ modal window with an opacity layer underneath
- No more need to upload icons – now base64 encoded
- Css can be customized a lot more easily than before
- The file-list in the ‘write’ tab is more compact so can be placed virtually anywere (now defaults under the ‘title’ field)
- File titles are listed insted of descriptions
- Other minor glitches fixed
Download from first post.
Offline
#17 2010-12-06 10:00:33
- jelle
- Member
- Registered: 2006-06-07
- Posts: 165
Re: bot_file_upload: upload and edit files from within the write tab
Thanks for all your work Redbot. Your plugins are standard on my sites.
Offline
Re: bot_file_upload: upload and edit files from within the write tab
Thanks Redbot :)
Offline
#19 2010-12-06 15:55:10
- redbot
- Plugin Author
- Registered: 2006-02-14
- Posts: 1,410
Re: bot_file_upload: upload and edit files from within the write tab
jelle + pieman
Thank you.
BTW in a few days – when I’ll be back home – I’ll upload v. 0.3.1 which should help in case you need to sort files in a specific order.
Last edited by redbot (2010-12-06 15:55:28)
Offline
#20 2010-12-06 16:36:59
- jelle
- Member
- Registered: 2006-06-07
- Posts: 165
Re: bot_file_upload: upload and edit files from within the write tab
Sorting?! Brilliant.
May I also suggest a simple Cancel button or X on top of the dialog for those cases where the user does not want it’s changed saved.
Last edited by jelle (2010-12-06 16:37:10)
Offline
#21 2010-12-06 17:09:09
- redbot
- Plugin Author
- Registered: 2006-02-14
- Posts: 1,410
Re: bot_file_upload: upload and edit files from within the write tab
jelle wrote:
May I also suggest a simple Cancel button or X on top of the dialog for those cases where the user does not want it’s changed saved.
Yes I was suggesting it to myself too.
Unfortunately I wrote the plugin in such a way that the values in the (hidden) custom field are added as soon as a file is checked in the iframe (you can notice it looking throught the opacity layer) so I should rewrite part of the plugin to make it change the values in the cf only when the ‘save’ button is clicked.
Sadly, untill I change the code (probably in some years considering my slowness) you must live with it.
I’ll add it to the todo list though.
Offline
#22 2010-12-09 18:16:22
- redbot
- Plugin Author
- Registered: 2006-02-14
- Posts: 1,410
Re: bot_file_upload: upload and edit files from within the write tab
With version 0.4 this plugin should have reached a mature stage.
Changes
- Now files can be ordered as you like. The file list can then be output in the frontend in the exact order you specified in the backend using the usual <txp:file_download_list /> tag but with an hackish ‘sort’ attribute (this is not really a hack, it’s only an undocumented value )
- Added a ‘cancel’ button as per Jelle’s suggestion
To list the files in a specific order in the frontend you just need to use the ‘sort’ attribute this way;
sort='field(id, <txp:custom_field name=''your_files_cf_name'' />)'
Of course you must replace ‘your_files_cf_name’ with your real custom field name.
Despite I tried to test it deeply it could be I left something. I count on you all for reporting issues.
Last edited by redbot (2010-12-09 23:13:53)
Offline
Re: bot_file_upload: upload and edit files from within the write tab
Quick clarification question: Can this plugin be used with more than one custom field at a time? I have articles that have up to 10 fields that will take file IDs, and I’m looking for a solution so clients don’t have to type in the ID for each field. Thank you.
Offline
#24 2011-03-18 18:29:02
- redbot
- Plugin Author
- Registered: 2006-02-14
- Posts: 1,410
Re: bot_file_upload: upload and edit files from within the write tab
maruchan wrote:
Quick clarification question: Can this plugin be used with more than one custom field at a time?
Er… no, sorry.
I promise I’ll try to add this ability to the next version, together with drag-n-drop sorting a la bot_image_upload.
The only issue is I don’t think I’ll have the time in the next few days.
Offline
Re: bot_file_upload: upload and edit files from within the write tab
That would be awesome. I think I can wait. :-) Thanks. bot_image_upload is terrific.
Offline
#26 2011-07-09 00:06:19
- frickinmuck
- Member

- Registered: 2008-05-01
- Posts: 118
Re: bot_file_upload: upload and edit files from within the write tab
I’m getting an error when I enable this plugin.
Warning: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'from textpattern where `ID` = '2' limit 1' at line 1 select from textpattern where `ID` = '2' limit 1 in /nfs/c07/h02/mnt/109250/domains/softball.bc.ca/html/textpattern/lib/txplib_db.php on line 89
Is this a compatibility issue with Txp 4.4.1?
The AI does not hate you, nor does it love you, but you are made out of atoms which it can use for something else.
Offline
#27 2011-07-09 16:06:12
- redbot
- Plugin Author
- Registered: 2006-02-14
- Posts: 1,410
Re: bot_file_upload: upload and edit files from within the write tab
frickinmuck wrote:
I’m getting an error when I enable this plugin.
Hi Mave, this shouldn’t be a problem with Txp 4.4.1, at least it works for me.
The first thing that comes to mind is whether you created a custom field called “files” or configured the plugin accordingly if you use another name (read instructions in case you need help).
Offline
#28 2011-08-16 06:10:03
- Teemu
- Member
- From: Shanghai
- Registered: 2010-04-27
- Posts: 60
Re: bot_file_upload: upload and edit files from within the write tab
First of all, thanks for a great plugin redbot.
Tried it with glz_custom_fields, but cannot make it work. Should it work?
Offline
#29 2011-08-16 08:03:31
- redbot
- Plugin Author
- Registered: 2006-02-14
- Posts: 1,410
Re: bot_file_upload: upload and edit files from within the write tab
Teemu wrote:
…Tried it with glz_custom_fields, but cannot make it work. Should it work?
Hi,
yes it should work.
Did you create a custom field named “files”?
Did you configure the plugin accordingly if you want to use another cf?
Offline
#30 2011-08-16 08:59:19
- Teemu
- Member
- From: Shanghai
- Registered: 2010-04-27
- Posts: 60
Re: bot_file_upload: upload and edit files from within the write tab
Thanks redbot for prompt response. My bad, I somehow had overlooked the case sensitivity in the field name.
Offline