| Server IP : 85.158.181.41 / Your IP : 216.73.217.12 Web Server : Apache System : Linux cloud9-vm129 6.1.178+1-ph #ph SMP PREEMPT_DYNAMIC Wed Jul 29 09:00:54 UTC 2026 x86_64 User : moncbefd ( 1024) PHP Version : 7.3.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/moncbefd/www.moneta.at/admin/includes/classes/ |
Upload File : |
<?php
/* --------------------------------------------------------------
box.php 2017-09-28
Gambio GmbH
http://www.gambio.de
Copyright (c) 2017 Gambio GmbH
Released under the GNU General Public License (Version 2)
[http://www.gnu.org/licenses/gpl-2.0.html]
IMPORTANT! THIS FILE IS DEPRECATED AND WILL BE REPLACED IN THE FUTURE.
MODIFY IT ONLY FOR FIXES. DO NOT APPEND IT WITH NEW FEATURES, USE THE
NEW GX-ENGINE LIBRARIES INSTEAD.
--------------------------------------------------------------
based on:
(c) 2000-2001 The Exchange Project (earlier name of osCommerce)
(c) 2002-2003 osCommerce(box.php,v 1.5 2002/03/16); www.oscommerce.com
(c) 2003 nextcommerce (box.php,v 1.5 2003/08/18); www.nextcommerce.org
(c) 2003 XT-Commerce - community made shopping http://www.xt-commerce.com ($Id: box.php 950 2005-05-14 16:45:21Z mz $)
Released under the GNU General Public License
Example usage:
$heading = array();
$heading[] = array('params' => 'class="menuBoxHeading"',
'text' => BOX_HEADING_TOOLS,
'link' => xtc_href_link(basename($PHP_SELF), xtc_get_all_get_params(array('selected_box')) . 'selected_box=tools'));
$contents = array();
$contents[] = array('text' => SOME_TEXT);
$box = new box;
echo $box->infoBox($heading, $contents);
--------------------------------------------------------------
*/
defined( '_VALID_XTC' ) or die( 'Direct Access to this location is not allowed.' );
class box extends tableBlock {
public function __construct() {
$this->heading = array();
$this->contents = array();
}
public function infoBox($heading, $contents, $additional_heading_classes = array(), $additional_content_classes = array()) {
$this->table_row_parameters = 'class="infoBoxHeading"';
$this->table_data_parameters = 'class="infoBoxHeading ' . implode(' ', $additional_heading_classes) . '"';
$this->heading = $this->get_table_box_string($heading);
$this->table_row_parameters = '';
$this->table_data_parameters = 'class="infoBoxContent ' . implode(' ', $additional_content_classes) . '"';
$this->contents = $this->get_table_box_string($contents);
return $this->heading . $this->contents;
}
public function menuBox($heading, $contents) {
$this->table_data_parameters = 'class="menuBoxHeading"';
if ($heading[0]['link']) {
$this->table_data_parameters .= ' onmouseover="this.style.cursor=\'hand\'" onclick="document.location.href=\'' . $heading[0]['link'] . '\'"';
$heading[0]['text'] = ' <a href="' . $heading[0]['link'] . '" class="menuBoxHeadingLink">' . $heading[0]['text'] . '</a> ';
} else {
$heading[0]['text'] = ' ' . $heading[0]['text'] . ' ';
}
$this->heading = $this->get_table_box_string($heading);
$this->table_data_parameters = 'class="menuBoxContent"';
$this->contents = $this->get_table_box_string($contents);
return $this->heading . $this->contents;
}
}