<?php
/**
  @licence GPL 2005-2010  The osCSS developers - osCSS Open Source E-commerce
  @package osCSS-2 <www http://www.oscss.org>
  @version 2.0.9
  @date  07/06/10, 19:24
  @author oscim <mail aurelien@oscim.fr> <www http://www.oscim.fr>
  @encode UTF-8
*/

for ($i = 0, $n = sizeof($languages); $i < $n; $i++) {
  if(is_dir(DIR_WS_LANGUAGES.$languages[$i]['directory'])){
    $languages_array[] = array('id' => $languages[$i]['code'], 'text' => $languages[$i]['name']);
    if ($languages[$i]['directory'] == $language ) $languages_selected = $languages[$i]['code'];
  }
}

$option_menu_admin['format_line_box_open_entete']='<h3 class="'."%4\$s".'" id="'."%3\$s".'">'."%1\$s".'</h3><div id="'."fils%3\$s".'" class="ssmenu"><ul>'."%2\$s".'</ul></div>' ."\n";
$option_menu_admin['format_line_box_open']='<li class="'."%4\$s".'" id="'."%3\$s".'">'."%1\$s".'<ul id="'."fils%3\$s".'" class="ssmenu">'."%2\$s".'</ul></li>' ."\n";
$option_menu_admin['format_line_box']='<li class="'."%4\$s".'" id="'."%3\$s".'">'."%1\$s".''."%2\$s".'</li>' ."\n";
$option_menu_admin['format_entete']='<a id="'."%1\$s".'" href="'."%2\$s".'" '."%4\$s".'>'."%3\$s".'</a>' ."\n";

/* Boucle calcul stat nbr commande, client, etc*/
$customers_query = tep_db_query("select count(*) as count from " . TABLE_CUSTOMERS);
$customers = tep_db_fetch_array($customers_query);
$products_query = tep_db_query("select count(*) as count from " . TABLE_PRODUCTS . " where products_status = '1'");
$products = tep_db_fetch_array($products_query);
$whos_online_query = tep_db_query("select * from " . TABLE_WHOS_ONLINE);


/* Init menu */
$menu=menu::resetInstance();
$ctr_menu=$menu->cstr($option_menu_admin);
$menu_activ=$menu->in_rub($current_page);

/* Menu bookmarks */
if(isset($navigation->path[count($navigation->path)-1])) {
  $der=$navigation->path[count($navigation->path)-1];
  $Bookmark[]= array('id' =>$der['get']['page_admin'], 'text' => __('heading title') );
}
$Bookmark[]= array('id' =>'index', 'text' => __('Tableau de bord') );
$Bookmark[]= array('id' =>'categories', 'text' => __('Categories'));
$Bookmark[]= array('id' =>'products', 'text' => __('Produits'));
$Bookmark[]= array('id' =>'customers', 'text' => __('Client/membres'));

?>