08 March 2010

Deleting uploaded files from MediaWiki

We had a request this morning for the deletion of a file a user had uploaded to our internal MediaWiki site. There didn't seem to be any straightforward [Delete] button anywhere. But where there's a will, there's a way. Here's how to delete an uploaded file:
  1. Ensure you have "sysop" permissions and you're logged in.
  2. Select "Special Pages" from the toolbox on the left-hand side of the screen.
  3. Click on "Unused files" or "File list," depending on whether you want to delete an unused file or see all the files uploaded to the wiki.
  4. Find the file you wish to delete.
  5. Click the "(desc)" link that appears before the filename.
  6. Now click "(Delete all revisions of this file)".
  7. Confirm your choice and provide a reason for the deletion.
That's all! I wish it was more intuitive, but there you have it :)


Anonymous said...

that doesn't really delete the file, its still there and can be restored back, to fully delete it you have to go into the directory, MediaWiki is installed on and delete the file from there/

Anonymous said...

Also, don't forget that the MySQL database still references the file.

Yunrui Zhang said...

But I don't see the link...? I am logged in. It is something about user rights? I am so confused.
By the way the page belongs to a class I took, but the files belongs to me..

Alex C said...

Hi Yunrui. You must be part of the "sysops" group to be able to delete files.