equal
deleted
inserted
replaced
518 |
518 |
519 function install_plugin($filename, $plugin_list = null) |
519 function install_plugin($filename, $plugin_list = null) |
520 { |
520 { |
521 global $db, $session, $paths, $template, $plugins; // Common objects |
521 global $db, $session, $paths, $template, $plugins; // Common objects |
522 global $lang; |
522 global $lang; |
|
523 global $cache; |
523 |
524 |
524 if ( defined('ENANO_DEMO_MODE') ) |
525 if ( defined('ENANO_DEMO_MODE') ) |
525 { |
526 { |
526 return array( |
527 return array( |
527 'mode' => 'error', |
528 'mode' => 'error', |
619 'success' => true |
620 'success' => true |
620 ); |
621 ); |
621 |
622 |
622 endswitch; |
623 endswitch; |
623 |
624 |
|
625 $cache->purge('plugins'); |
|
626 |
624 return $return; |
627 return $return; |
625 } |
628 } |
626 |
629 |
627 /** |
630 /** |
628 * Uninstalls a plugin, removing it completely from the database and calling any custom uninstallation code the plugin specifies. |
631 * Uninstalls a plugin, removing it completely from the database and calling any custom uninstallation code the plugin specifies. |
735 $return = array( |
738 $return = array( |
736 'success' => true |
739 'success' => true |
737 ); |
740 ); |
738 |
741 |
739 endswitch; |
742 endswitch; |
|
743 |
|
744 $cache->purge('plugins'); |
740 |
745 |
741 return $return; |
746 return $return; |
742 } |
747 } |
743 |
748 |
744 /** |
749 /** |
959 'success' => true |
964 'success' => true |
960 ); |
965 ); |
961 |
966 |
962 endswitch; |
967 endswitch; |
963 |
968 |
|
969 $cache->purge('plugins'); |
|
970 |
964 return $return; |
971 return $return; |
965 } |
972 } |
966 |
973 |
967 /** |
974 /** |
968 * Re-imports the language strings from a plugin. |
975 * Re-imports the language strings from a plugin. |