![]() |
ask about method for saving attachment on server
Hi everyone
I want Ask About method for saving attachments(files) on server ? I try learn the method . make folder for every member in Attachments folder and named by number id for member and save file uploaded by member in his foder e.x. admin have id 1 then will be folder for his files ( attachments/1/ ) the admin upload image ( vb.png) will saved in his file by id in attachment in data base the directory will be (vb/attachments/1/287.attach) https://vborg.vbsupport.ru/external/2015/11/1.png that's correct ?? thanks |
Basically, but user 111 will have a folder of vb/attachments/1/1/1/123.attach
|
ok bro
But i want programming file(php) make me can get contact the attachment via id user and id attachment .... how i can get it? if i have 300.000 user in my form |
to make sure I am understanding, you want a script which will view an attachment file, in the file system, and return the contact info of the user who posted it?
|
yah :) like
if i have member id is =1 and id for attachment in database is =25 http://site.com/show_attach.php?user=1&attach=25 and sorry for my English language :) |
well, the folder structure will always be 1 digit. So you know user #111's attachments will be in folder attachments/1/1/1/files. user #112 will be in attachments/1/1/2/files. user 345 will be in attachments/3/4/5/files etc
user #3000 = attachments/3/0/0/0/files user #30000 = attachments/3/0/0/0/0/files you can see that the folders stack. Try something like this (stolen from Stack Exchange): PHP Code:
NOTE: This has not been tested by me, so use with caution. |
thank u bro,
I test it, that work for me thanx |
All times are GMT. The time now is 10:20 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:
|