Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.6 > vBulletin 3.6 Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
[AJAX] Edit Attachment Filenames Details »»
[AJAX] Edit Attachment Filenames
Version: 2.0, by Abe1 Abe1 is offline
Developer Last Online: Jun 2010 Show Printable Version Email this Page

Category: Moderators Functions - Version: 3.6.8 Rating:
Released: 09-17-2006 Last Update: 04-15-2007 Installs: 66
Uses Plugins Template Edits
Additional Files  
No support by the author.

CLICK HERE FOR A LATER VERSION OF THIS HACK

Edit Attachment Filenames 2.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:
  • Files edited: 0
  • Templates edited: 2
  • Files to upload via FTP: 1
  • Time to install: 1 minute max
Updates:

Version 1.0 (09/18/06):
  • First release of this hack.

Version 2.0 (04/16/07):
  • Re-wrote most of the code to optimize AJAX code.

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.

Supporters / CoAuthors

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #22  
Old 05-08-2007, 12:02 PM
Surviver's Avatar
Surviver Surviver is offline
 
Join Date: Feb 2006
Location: Bonn, Germany
Posts: 382
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

In the js File, ist the following Code:

Code:
function post_thanks_give(postid, integrate)
{
	fetch_object('post_thanks_button_' + postid).style.display = 'none';

	if (integrate == true)
	{
		fetch_object('post_groan_button_' + postid).style.display = 'none';
	}
	
	do_thanks_add = new vB_AJAX_Handler(true);
	do_thanks_add.postid = postid;
	do_thanks_add.onreadystatechange(thanks_add_Done);
	do_thanks_add.send('post_thanks.php?do=post_thanks_add&using_ajax=1&p=' + postid);
}
function thanks_add_Done()
{
	if (do_thanks_add.handler.readyState == 4 && do_thanks_add.handler.status == 200)
	{
		fetch_object('post_thanks_box_' + do_thanks_add.postid).innerHTML = do_thanks_add.handler.responseText;
	}
}
function post_thanks_remove_all(postid, integrate)
{
	do_thanks_remove_all = new vB_AJAX_Handler(true)
	do_thanks_remove_all.postid = postid
	do_thanks_remove_all.onreadystatechange(thanks_remove_all_Done)
	do_thanks_remove_all.send('post_thanks.php?do=post_thanks_remove_all&using_ajax=1&p=' + postid)

	fetch_object('post_thanks_button_' + postid).style.display = ''

	if (integrate == true)
	{
		fetch_object('post_groan_button_' + postid).style.display = '';
	}
}
function thanks_remove_all_Done()
{
	if (do_thanks_remove_all.handler.readyState == 4 && do_thanks_remove_all.handler.status == 200)
	{
		fetch_object('post_thanks_box_' + do_thanks_remove_all.postid).innerHTML = do_thanks_remove_all.handler.responseText
	}
}
function post_thanks_remove_user(postid, integrate)
{
	do_thanks_remove_user = new vB_AJAX_Handler(true)
	do_thanks_remove_user.postid = postid
	do_thanks_remove_user.onreadystatechange(thanks_remove_user_Done)
	do_thanks_remove_user.send('post_thanks.php?do=post_thanks_remove_user&using_ajax=1&p=' + postid)

	fetch_object('post_thanks_button_' + postid).style.display = ''

	if (integrate == true)
	{
		fetch_object('post_groan_button_' + postid).style.display = '';
	}	
}
function thanks_remove_user_Done()
{
	if (do_thanks_remove_user.handler.readyState == 4 && do_thanks_remove_user.handler.status == 200)
	{
		fetch_object('post_thanks_box_' + do_thanks_remove_user.postid).innerHTML = do_thanks_remove_user.handler.responseText
	}
}
Ist this Correct?
Reply With Quote
  #23  
Old 05-08-2007, 10:46 PM
Abe1's Avatar
Abe1 Abe1 is offline
 
Join Date: Feb 2004
Location: I LOVE New York!
Posts: 2,886
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

How did post thanks hack get it's way into this thread?
Reply With Quote
  #24  
Old 05-09-2007, 10:29 AM
Triky's Avatar
Triky Triky is offline
 
Join Date: Mar 2007
Location: [Italy]
Posts: 728
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Nice hack, Abe1.
Reply With Quote
  #25  
Old 10-06-2007, 09:01 PM
millionart millionart is offline
 
Join Date: Feb 2007
Posts: 4
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Abe1 View Post
Sorry, I have no way to test it.
You can rename any attachment to "中文附件名测试" for testing.
(The character means by "the Chinese attachment name test".

Hope you can fix it , theanks.
Reply With Quote
  #26  
Old 05-12-2008, 01:01 AM
Abe1's Avatar
Abe1 Abe1 is offline
 
Join Date: Feb 2004
Location: I LOVE New York!
Posts: 2,886
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Version 3.0 (05/11/08):
  • First release of this hack for vb 3.7.

https://vborg.vbsupport.ru/showthread.php?t=178937
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 06:23 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04174 seconds
  • Memory Usage 2,260KB
  • Queries Executed 23 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_code
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (6)post_thanks_box
  • (6)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (6)post_thanks_postbit_info
  • (5)postbit
  • (6)postbit_onlinestatus
  • (6)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete