Manually Removing Joomla Components

I’ve helped with a Joomla-based hobby site for several years. Another developer I work with added some custom-developed components that were manually added without install/uninstall scripts. All was well, but when the time eventually came that we no longer wanted these components in place, there was no obvious way to remove them from the administrative menus. Removing the component files wasn’t enough.
I had run into this problem before with older versions of Joomla so I knew the basic idea of deleting items from the extensions table, assets, etc. But I never got around to actually doing it for this site. Then I stumbled upon this handy article at MassMediums and I knew the time was right.
Summarizing here in case the link goes dark.
DATA
- Run these queries in your phpMyAdmin
- Manual removal com_EXTENSION_NAME from Joomla! database
- Change the #__ to your Joomla! prefix, e.g. #__extensions to jos_extensions
DELETE FROMjos_schemasWHEREextension_id= (SELECTextension_idFROMjos_extensionsWHEREtype= 'component' ANDname= 'com_EXTENSION_NAME'); DELETE FROMjos_extensionsWHEREname= 'com_EXTENSION_NAME'; DELETE FROMjos_assetsWHEREname= 'com_EXTENSION_NAME'; DELETE FROMjos_menuWHEREtype= 'component' ANDtitleLIKE '%com_EXTENSION_NAME%'; DELETE FROMjos_sessionWHEREdataLIKE '%com_EXTENSION_NAME%';
FOLDERS
- components/com_EXTENSION_NAME
- administrator/components/com_EXTENSION_NAME
- media/com_EXTENSION_NAME
FILES
- language/en-GB/en-GB.com_EXTENSION_NAME.ini
- language/en-GB/en-GB.com_EXTENSION_NAME.sys.ini
- administrator/language/en-GB/en-GB.com_EXTENSION_NAME.ini
- administrator/language/en-GB/en-GB.com_EXTENSION_NAME.sys.ini

