<?php
/*
  www.oscGold.com (C) Kamelia-Net Jacek Krysiak
  modul oscGold wer 4.0
*/

    $boxHeading = BOX_HEADING_THEMES;
    $corner_left = 'rounded';
    $corner_right = 'rounded';
    $box_base_name = 'themes'; // for easy unique box template setup (added BTSv1.2)
    $box_id = $box_base_name . 'Box';  // for CSS styling paulm (editted BTSv1.2)
    $boxContent_attributes = ' align="center"';

    if(file_exists(DIR_WS_TEMPLATES_BASE . 'get_themes.php')) require(DIR_WS_TEMPLATES_BASE . 'get_themes.php');
    //$boxContent = tep_draw_form('themes', tep_href_link(basename($PHP_SELF), '', $request_type, false), 'get');
    $boxContent = tep_draw_form('themes', tep_href_link(basename($PHP_SELF), tep_get_all_get_params(), $request_type, false), 'get');
    //$boxContent .= tep_hidden_all_get_params();

    //$tmpl_name=explode ( '/', $tplDir);
    $boxContent .= tep_templates_pl_menu('tplDir', get_themes(), $tplDir, 'onChange="this.form.submit();"');
	
	if (isset($HTTP_GET_VARS['cPath'])) {
		$boxContent .= '<input type="hidden" name="cPath" value="' . $HTTP_GET_VARS['cPath'] . '">';
	}
	if (isset($HTTP_GET_VARS['products_id'])) {
		$boxContent .= '<input type="hidden" name="products_id" value="' . $HTTP_GET_VARS['products_id'] . '">';
	}	
	if (isset($HTTP_GET_VARS['pages_id'])) {
		$boxContent .= '<input type="hidden" name="pages_id" value="' . $HTTP_GET_VARS['pages_id'] . '">';
	}	
	if (isset($HTTP_GET_VARS['newsdesk_id'])) {
		$boxContent .= '<input type="hidden" name="newsdesk_id" value="' . $HTTP_GET_VARS['newsdesk_id'] . '">';
	}		
    $boxContent .= '</form>';

// bof BTSv1.2
    if(file_exists(DIR_WS_BOX_TEMPLATES . $box_base_name . '.tpl.php')) {
    // if exists, load unique box template for this box from templates/boxes/
        require(DIR_WS_BOX_TEMPLATES . $box_base_name . '.tpl.php');
    }
    else {
    // load default box template: templates/boxes/box.tpl.php
        require(DIR_WS_BOX_TEMPLATES . TEMPLATENAME_BOX);
    }
// eof BTSv1.2

  $boxContent_attributes = '';

?>