Sindbad~EG File Manager

Current Path : /home/sarayaglobal/sarayamystair.in/plugins/fields/location/
Upload File :
Current File : /home/sarayaglobal/sarayamystair.in/plugins/fields/location/script.php

<?php

defined('_JEXEC') or die;

class plgFieldsLocationInstallerScript
{
    public function install($parent) {}

    public function uninstall($parent) {}

    public function update($parent) {}

    public function preflight($type, $parent) {}

    public function postflight($type, $parent)
    {
        if (!in_array($type, ['install', 'update'])) {
            return;
        }

        JFactory::getDBO()->setQuery(
            "UPDATE #__extensions SET "
            .($type == 'install' ? 'enabled = 1, ' : '')
            ."ordering = 0 WHERE type = 'plugin' AND folder = 'fields' AND element = 'location'"
        )->execute();
    }
}

Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists