![]() |
[AJAX] Edit Attachment Filenames
Edit Attachment Filenames 3.0 About this hack: This hack is a pretty useful hack. It lets you edit filenames of attachments. Only users with 'canmoderateattachments' permissions on the forum that the attachment it posted by will be allowed to edit the filenames. You access the edit by double clicking right near the filename of an attachment. It will bring up an edit box similar to the edit thread title vb feature. You will get an option to save or cancel the edit. Now that you can see a list of all attachments in one thread, you would want to name some attachments differently so they can be identified with out looking at the post. The filename extension cannot be edited. Installation information on hack:
Version 3.0 (05/11/08):
Please post your comments or suggestions for this hack. I read ALL posts. MAKE SURE YOU CLICK INSTALL! You will get an email when a new version is released. |
reserved !!
|
installed!
|
Will this work for attachments as files as well as attachments in the db?
|
I wish you can eliminate the template edits! Can you?
|
Quote:
@Abe1 Better use $vbphrase[save] and $vbphrase[cancel], please. :) Javascript error, if I want inline edit an attachment in postbit template (see attached thumbnail, please): Error: document.getElementById("attachment_filename_" + attachmentid) has no properties Source file: .../clientscript/edit_attachment_filenames.js Line: 9 Code:
document.getElementById('attachment_filename_' + attachmentid).innerHTML = '' Updated templateedits, because copy & paste error. Please download the templateedits-abe1_edit_attachment_name.xml again and reimport. sorry. :( Regards |
Quote:
Quote:
|
Quote:
|
Quote:
|
Thank you very much Abe1 for this hint, this was a typically copy & paste error. Copied twice same text for find and replace :(
Regards |
This looks awfully slick. Nice addition. :)
|
Quote:
|
Quote:
|
Opps.
not working.. It is leading to downloading the file.. And when I ve import the second attachment this is leading to Quote:
Thanks in advance |
Quote:
|
if new attachment filename value including latin characters ( like "ş, ğ, İ" ) it is looking
Quote:
Like ş > s ğ > g İ > i Thanks |
Abe1, any way to get this to work on attachment thumbnail file names?
|
I just recieved a security token error while editing a filename. Here is the info:
Quote:
|
Quote:
|
Not fixed yet, waiting on Abe to do the support thing.
|
Thanks ..
İnstalled Button =} |
How to I can edit one image file name with this tool?
thumbnails are enabled in my board. |
Quote:
Quote:
if you click on page forumdisplay.php on the URL -->> https://vborg.vbsupport.ru/external/2009/05/5.gif <<-- for the thread where you need to edit thumbnail image name then you will be able to do so. 2nd, You can do so... Open template: Code:
postbit_attachmentmoderated Code:
<tr> Code:
<tr<if condition="can_moderate($threadinfo['forumid'], 'canmoderateattachments')"> ondblclick="edit_attachment_name($attachment[attachmentid]);"</if>> Code:
<td><if condition="$show['modattachmentlink']"><a href="attachment.php?$session[sessionurl]attachmentid=$attachment[attachmentid]&d=$attachment[dateline]"<if condition="$show['newwindow']"> target="_blank"</if>>$attachment[filename]</a> ($attachment[filesize])<else />$attachment[filename]</if></td> Code:
<td><if condition="$show['modattachmentlink']"><a href="attachment.php?$session[sessionurl]attachmentid=$attachment[attachmentid]&d=$attachment[dateline]"<if condition="$show['newwindow']"> target="_blank"</if> id="attachment_filename_$attachment[attachmentid]">$attachment[filename]</a><a id="attachment_filename_edit_$attachment[attachmentid]"></a> ($attachment[filesize])<else />$attachment[filename]</if></td>
3rd, You can open the template: Code:
postbit_attachmentthumbnail Code:
<if condition="can_moderate($threadinfo['forumid'], 'canmoderateattachments')"><a id="attachment_filename_$attachment[attachmentid]" ondblclick="edit_attachment_name($attachment[attachmentid]);">$attachment[filename]</a><a id="attachment_filename_edit_$attachment[attachmentid]"></a></if>
I know that it's not beautiful, but I could not find a better way to do so for that template. You can try to add: Code:
<if condition="can_moderate($threadinfo['forumid'], 'canmoderateattachments')"><a id="attachment_filename_$attachment[attachmentid]" ondblclick="edit_attachment_name($attachment[attachmentid]);">*</a><a id="attachment_filename_edit_$attachment[attachmentid]"></a></if> |
Any way you can make it work with vB 4.x???
Thanks |
Any news on this plugin working for vB 4 ?
:) |
please working this plugin for vB 4
|
it is not work on v4 :( please ...
i need this mod for v4 :( |
SECURITY WARNING
This hack allow execute scripts e.t.c try rename file as PHP Code:
same situation in admincp if you view attachements stats |
please make it for vb 4.2
|
All times are GMT. The time now is 03:28 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|