Linux mail.vriendennsm.nl 6.1.0-51-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.177-1 (2026-07-16) x86_64
Apache/2.4.68 (Debian)
Server IP : 217.154.75.17 & Your IP : 216.73.216.195
Domains :
Cant Read [ /etc/named.conf ]
User : www-data
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
var /
www /
vnsm /
plugins /
j2store /
app_diagnostics /
Delete
Unzip
Name
Size
Permission
Date
Action
app_diagnostics
[ DIR ]
drwxr-xr-x
2025-02-08 22:29
app_diagnostics.php
5.8
KB
-rwxr-xr-x
2022-02-20 10:42
app_diagnostics.xml
661
B
-rwxr-xr-x
2022-02-20 10:42
index.html
249
B
-rwxr-xr-x
2022-02-20 10:42
Save
Rename
<?php /** * @package J2Store * @copyright Copyright (c)2014-17 Ramesh Elamathi / J2Store.org * @license GNU GPL v3 or later */ /** ensure this file is being included by a parent file */ defined('_JEXEC') or die('Restricted access'); require_once(JPATH_ADMINISTRATOR.'/components/com_j2store/library/plugins/app.php'); class plgJ2StoreApp_diagnostics extends J2StoreAppPlugin { /** * @var $_element string Should always correspond with the plugin's filename, * forcing it to be unique */ var $_element = 'app_diagnostics'; /** * Overriding * * @param $options * @return unknown_type */ function onJ2StoreGetAppView( $row ) { if (!$this->_isMe($row)) { return null; } $html = $this->viewList(); return $html; } /** * Validates the data submitted based on the suffix provided * A controller for this plugin, you could say * * @param $task * @return html */ function viewList() { $app = JFactory::getApplication(); $option = 'com_j2store'; $ns = $option.'.tool'; $html = ""; JToolBarHelper::title(JText::_('J2STORE_APP').'-'.JText::_('PLG_J2STORE_'.strtoupper($this->_element)),'j2store-logo'); JToolBarHelper::back('J2STORE_BACK_TO_DASHBOARD', 'index.php?option=com_j2store'); $vars = new JObject(); $this->includeCustomModel('AppDiagnostics'); $this->includeCustomTables(); //$model = F0FModel::getTmpInstance('ToolDiagnostics', 'J2StoreModel'); $vars->info = $this->getInfo(); $id = $app->input->getInt('id', '0'); $vars->id = $id; $form = array(); $form['action'] = "index.php?option=com_j2store&view=app&task=view&id={$id}"; $vars->form = $form; $html = $this->_getLayout('default', $vars); return $html; } public function getInfo() { $info = array(); $version = new JVersion; $platform = new JPlatform; $db = JFactory::getDbo(); if (isset($_SERVER['SERVER_SOFTWARE'])) { $sf = $_SERVER['SERVER_SOFTWARE']; } else { $sf = getenv('SERVER_SOFTWARE'); } $info['php'] = php_uname(); $info['dbversion'] = $db->getVersion(); $info['dbcollation'] = $db->getCollation(); $info['phpversion'] = phpversion(); $info['server'] = $sf; $info['sapi_name'] = php_sapi_name(); $info['version'] = $version->getLongVersion(); $info['platform'] = $platform->getLongVersion(); $info['useragent'] = isset($_SERVER['HTTP_USER_AGENT']) ? $_SERVER['HTTP_USER_AGENT'] : ""; $info['j2store_version'] = $this->getJ2storeVerion(); $info['is_pro'] = J2Store::isPro(); $info['curl'] = $this->_isCurl(); $info['json'] = $this->_isJson(); $config = JFactory::getConfig(); $info['error_reporting'] =$config->get('error_reporting'); $caching = $config->get('caching'); $info['caching'] = ($caching) ? JText::_('J2STORE_ENABLED') : JText::_('J2STORE_DISABLED') ; $cache_plugin = JPluginHelper::isEnabled('system', 'cache'); $info['plg_cache_enabled'] = $cache_plugin; $info['memory_limit'] = ini_get('memory_limit'); return $info; } function _isCurl(){ return (function_exists('curl_version')) ? JText::_('J2STORE_ENABLED'): JText::_('J2STORE_DISABLED') ; } function _isJson(){ return (function_exists('json_encode')) ? JText::_('J2STORE_ENABLED'): JText::_('J2STORE_DISABLED') ; } public function getJ2storeVerion(){ $version =''; $db = JFactory::getDbo(); $query = $db->getQuery(true); $query->select($db->quoteName('manifest_cache'))->from($db->quoteName('#__extensions'))->where($db->quoteName('element').' = '.$db->quote('com_j2store')); $db->setQuery($query); $result = $db->loadResult(); if($result) { $manifest = json_decode($result); $version = $manifest->version; } return $version; } public function onJ2StoreProcessCron($command){ if($command == 'clear_cart'){ $this->clear_outdated_cart_data(); } } /** * Task to clear the old cart data * */ public function clear_outdated_cart_data(){ $app = JFactory::getApplication(); $clear_time = $app->input->getInt('clear_time',0); if($clear_time <= 0){ $j2params = J2Store::config(); $no_of_days_old = $j2params->get('clear_outdated_cart_data_term',90); //convert to seconds $clear_time = ($no_of_days_old*1440); } $tz = JFactory::getConfig()->get('offset'); $formattedDate = JFactory::getDate('now -'.$clear_time.' minutes', $tz)->toSql(true); $db = JFactory::getDbo(); $query = $db->getQuery(true); $query->select('ab.j2store_cart_id')->from('#__j2store_carts as ab'); $query->where('ab.cart_type = '.$db->q('cart')); $query->where('ab.created_on <= '.$db->q($formattedDate)); $db->setQuery($query); $old_cart_items_exists = $db->loadObjectList(); if ( count($old_cart_items_exists) > 0 ) { $cart_ids = array(); foreach ($old_cart_items_exists as $cart_id){ $cart_ids[] = $cart_id->j2store_cart_id; } //clear cart details $delete_cartitems_qry = "delete from #__j2store_cartitems where cart_id in (".implode(',',$cart_ids).");"; $db->setQuery($delete_cartitems_qry); try { $db->execute(); }catch (Exception $e) { } $delete_carts_qry = "delete from #__j2store_carts where #__j2store_carts.cart_type=".$db->q('cart') ." AND created_on <= ".$db->q($formattedDate).";"; $db->setQuery($delete_carts_qry); try { $db->execute(); }catch (Exception $e) { } } } }