The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
Upload a file using the datamanager?
Hello,
I would like to use the vB Datamanager to upload a non-image file for my custom mini mod. I cant find in this forum the tutorial anywhere. Can someone help me? Thank you |
#2
|
|||
|
|||
So you are asking how to integrate the upload-form that Vbulletin has into your custom mini-mod?
You need to list more details on this mod. Is it on Vbulletin or a CMS? Does the user need to be logged into VB to upload/download? How is everything being displayed? Thank you, these answers will help me better assist you. |
#3
|
||||
|
||||
Quote:
Its on vBulletin. It does not matter if the uploader is user or Mod (for all) Just upload the file on to the server. Thats all. |
#4
|
|||
|
|||
I am still a little unclear
Are you looking to just have a file uploaded to any directory? I need details mate. Do you have any examples? |
#5
|
||||
|
||||
Something like this for images: https://vborg.vbsupport.ru/showthrea...ghlight=upload
But I need for all file types. |
#6
|
|||
|
|||
If I go from the source provided in that link, I feel that the only modification that needs to be made is the following:
Code:
if($_POST['do']=="doupload"){ $vbulletin->input->clean_gpc("f","upload",TYPE_FILE); require_once('./includes/class_upload.php'); $upload =& new vB_Upload_Attachment($vbulletin); $upload->path = "./directory/of/choice/"; if (!($upload->process_upload($vbulletin->GPC['upload']))){ eval(standard_error(fetch_error('there_were_errors_encountered_with_your_upload_x', $upload->fetch_error()))); } } Please let me know if this works. Original source: PHP Code:
|
#7
|
||||
|
||||
There is this error:
Fatal error: Call to a member function is_valid_info_extension() on a non-object in C:\AppServ\www\upload\includes\class_upload.php on line 649 |
#8
|
|||
|
|||
Hello mokujin,
-What happened when you used the previous code (which you supplied). Did it properly upload images? -What type of file-extension are you trying to upload? Thank you, |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|