2015-04-05 10:59:53 -07:00
|
|
|
<?php
|
|
|
|
/*
|
|
|
|
* e107 website system
|
|
|
|
*
|
2016-12-02 20:44:17 +00:00
|
|
|
* Copyright (c) 2008-2016 e107 Inc (e107.org)
|
2015-04-05 10:59:53 -07:00
|
|
|
* Released under the terms and conditions of the
|
|
|
|
* GNU General Public License (http://www.gnu.org/licenses/gpl.txt)
|
|
|
|
*
|
|
|
|
* Custom FAQ install/uninstall/update routines
|
|
|
|
*
|
|
|
|
*/
|
2018-09-30 08:36:52 +02:00
|
|
|
e107::includeLan(e_PLUGIN.'rss_menu/languages/'.e_LANGUAGE.'_admin_rss_menu.php');
|
2015-04-05 10:59:53 -07:00
|
|
|
|
|
|
|
class rss_menu_setup
|
|
|
|
{
|
|
|
|
/*
|
|
|
|
function install_pre($var)
|
|
|
|
{
|
|
|
|
// print_a($var);
|
|
|
|
// echo "custom install 'pre' function<br /><br />";
|
|
|
|
}
|
|
|
|
*/
|
|
|
|
function install_post($var)
|
|
|
|
{
|
|
|
|
$sql = e107::getDb();
|
|
|
|
$mes = e107::getMessage();
|
|
|
|
|
|
|
|
$insert = array(
|
2016-02-25 18:43:49 -08:00
|
|
|
'rss_id' => 0,
|
2018-09-30 08:36:52 +02:00
|
|
|
'rss_name' => RSS_NEWS,
|
2016-02-25 18:43:49 -08:00
|
|
|
'rss_url' => 'news',
|
|
|
|
'rss_topicid' => '',
|
|
|
|
'rss_path' => 'news',
|
2018-09-30 08:36:52 +02:00
|
|
|
'rss_text' => RSS_PLUGIN_LAN_7,
|
2016-02-25 18:43:49 -08:00
|
|
|
'rss_datestamp' => time(),
|
|
|
|
'rss_class' => '0',
|
|
|
|
'rss_limit' => '9'
|
2015-04-05 10:59:53 -07:00
|
|
|
);
|
2016-02-25 18:43:49 -08:00
|
|
|
|
|
|
|
|
|
|
|
// $mes->addInfo(print_a($insert,true));
|
|
|
|
|
2015-04-05 10:59:53 -07:00
|
|
|
$status = ($sql->insert('rss', $insert)) ? E_MESSAGE_SUCCESS : E_MESSAGE_ERROR;
|
2016-12-02 20:44:17 +00:00
|
|
|
$mes->add(LAN_DEFAULT_TABLE_DATA.": rss",$status);
|
2015-04-05 10:59:53 -07:00
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
/*
|
|
|
|
function uninstall_options()
|
|
|
|
{
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
function uninstall_post($var)
|
|
|
|
{
|
|
|
|
// print_a($var);
|
|
|
|
}
|
|
|
|
|
|
|
|
function upgrade_post($var)
|
|
|
|
{
|
|
|
|
// $sql = e107::getDb();
|
|
|
|
}
|
|
|
|
*/
|
|
|
|
}
|