|
Autor |
Nachricht |
Makc666
|
Titel: Users can delete their images?
Verfasst am: Do, 04 Mai 2006, 23:46 |
|
|
I just found out that users can't delete their images.
Why?
Is there any way to implement?
|
|
Nach oben |
|
boris
Beiträge: 11154
|
Titel: Re: Users can delete their images?
Verfasst am: Fr, 05 Mai 2006, 08:45 |
|
|
Makc666 @ Fr, 05 Mai 2006, 00:46 gab folgendes von sich: |
Is there any way to implement? |
Basically: yes, practically: no - at least not with the current version.
The reason: users should not delete images that are in use. If they change (or delete) on of their posts that has an image which was uploaded with UploadPic, it will be deleted if the admin starts the "delete unused pictures"-function anyways.
To have the users delete their images (e.g. from the gallery) I'd have to check, if the pictures are in use whenever somebody calls the gallery - and that for all messages, PM, Knowledge Base, Lexicon, easyCMS, etc. etc.
Imagine having a huge forum with a couple of thousands (maybe even ten thousands) users and even more messages - if only a handfull of users call the gallery at the same time and each of them has a load of pictures in the gallery, the forum will probably not be able to handle all those requests.
Whenever I get the next version done with database-support (all pictures are stored in a database, so I don't have to use file-functions that often), I'll think about the delete-function for users, but with the current version it'll be too risky.
____________ beehave - home of humbug ... [we can't afford to be neutral]
|
|
Nach oben |
|
Makc666
|
Titel: Re: Users can delete their images?
Verfasst am: Fr, 05 Mai 2006, 10:14 |
|
|
boris @ Fri, 05 May 2006, 09:45 gab folgendes von sich: |
Makc666 @ Fr, 05 Mai 2006, 00:46 gab folgendes von sich: |
Is there any way to implement? |
Basically: yes, practically: no - at least not with the current version.
The reason: users should not delete images that are in use. If they change (or delete) on of their posts that has an image which was uploaded with UploadPic, it will be deleted if the admin starts the "delete unused pictures"-function anyways.
To have the users delete their images (e.g. from the gallery) I'd have to check, if the pictures are in use whenever somebody calls the gallery - and that for all messages, PM, Knowledge Base, Lexicon, easyCMS, etc. etc.
Imagine having a huge forum with a couple of thousands (maybe even ten thousands) users and even more messages - if only a handfull of users call the gallery at the same time and each of them has a load of pictures in the gallery, the forum will probably not be able to handle all those requests. |
Why do you want to ckeck?
Why not just delete them?
Read below my idea.
boris @ Fri, 05 May 2006, 09:45 gab folgendes von sich: |
Whenever I get the next version done with database-support (all pictures are stored in a database, so I don't have to use file-functions that often), I'll think about the delete-function for users, but with the current version it'll be too risky. |
Stop! Stop! Stop!
Images in database?
No. Never. Bad idea.
Images in database overload it!!!
I know a lot of people who tries to keep images in databases.
They sputtered of this function.
About my idea.
Do you ever seen how Upload function was made in upcoming phpBB 3?
Here is the screenshot.
Do you see.
They use special bbCode.
Why not use the same like:
[upp=13221] or some more specific so forum can parse it.
The URLs for images will be stored in databeses.
The images it self on HDD.
If some one deletes some image, say number 99999
And other man has [upp=99999] in his post.
Then when you will get a warning that picture has been deleted.
I think this will a very good idea.
|
|
Nach oben |
|
boris
Beiträge: 11154
|
Titel: Re: Users can delete their images?
Verfasst am: Sa, 06 Mai 2006, 23:13 |
|
|
Makc666 @ Fr, 05 Mai 2006, 11:14 gab folgendes von sich: |
Images in database? No. Never. Bad idea. |
Relax
What I meant: just the name, date, size, user and checksum in the database, not the whole image-files.
Makc666 gab folgendes von sich: |
If some one deletes some image, say number 99999
And other man has [upp=99999] in his post.
Then when you will get a warning that picture has been deleted. |
I don't really like that idea:
1. I would have to dig into the BBCode thing to make that possible, which means a lot of work for me and more things to change in the phpBB-code, which results in more errors while installing, more questions, more support, more work for me
2. the HD-load for uploaded pictures will double (!) for each picture as I have to check if the file exists first and then display the picture or the warning ...
That's why I won't let people delete any pictures - I don't think it's necessary. If you don't want the picture any more, edit your post, remove it and it will be deleted as soon as the admin clicks "remove unused pictures".
Without the extra checking, if the picture exists (before displaying it), I could not display a warning. And as the HD-access is the slowest possible function on the server (again: imagine a thread with a lot of pictures !), I will slow down the script and put a lot of load on the server - and that's just what I'm trying to get away from.
____________ beehave - home of humbug ... [we can't afford to be neutral]
|
|
Nach oben |
|
|
|
ähnliche Beiträge |
|
Schreiben: nein. Antworten: nein. Bearbeiten: nein. Löschen: nein. Umfragen: nein.
|