News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Terminate & Reverse MOD Installation If Not Using mySQL Database

Started by Randem, December 04, 2017, 08:25:11 AM

Previous topic - Next topic

Randem

I have looked and found nothing on this topic, so I am asking how can I Terminate & Reverse MOD Installation If Not Using mySQL Database?

Basically in the code directive section of the Package-info.xml.file in the code I basically want to do something like this:


if (($db_type != 'mysql') && ($db_type{!= 'mysqli')){
fatal_lang_error 'Only mySQL database supported at this time!', false);
}


But instead of the return, I want to exit and have the Package Manager not to continue installation of the MOD and to reverse anything that was done.
How can this be achieved?
Scams - How to Protect Yourself
Why Professionals Should Not Use Free Email Accounts

Always ignore those who attempt to tell you what to think and believe those who will allow you think for yourself

Arantor

You can try putting it in the install.php file instead and document it on the mod's page.

In reality the number of non-MySQL users is sufficiently small that it shouldn't be much of a problem, and SMF provides a decent amount of abstraction functionality to help.

Advertisement: