$dg = new dg(); $lang = $dg->lang(); // call products $products = $dg->getProducts(); $product = $products[0]; if (isset($_GET['product'])) { $product_id = $_GET['product']; for ($i = 0; $i < count($products); $i++) { if ($product_id == $products[$i]->id) { $product = $products[$i]; } } } // get attribute if (isset($product->attributes->name)) { $product->attribute = $dg->getAttributes($product->attributes); } else { $product->attribute = ''; } $product->attribute .= $dg->quantity($product->min_order, lang('quantity', true), lang('min_quantity', true)); // get getSetting $settings = $dg->getSetting(); // check cookie if (!isset($_COOKIE['design'])) { $user = 0; } else { $user = $_COOKIE['design']; } $settings->site_url = $dg->url(); // load add-on $addons = new addons();