<?php  
class ControllerModuleBpButton extends Controller {
	public function index() {
    	
		if (file_exists(DIR_TEMPLATE . $this->config->get('config_template') . '/stylesheet/bp_button.css')) {
			$this->document->addStyle('catalog/view/theme/' . $this->config->get('config_template') . '/stylesheet/bp_button.css');
		} else {
			$this->document->addStyle('catalog/view/theme/default/stylesheet/bp_button.css');
		}
		
		$this->data['blog'] = $this->url->link('blog/home');
		
		if (file_exists(DIR_TEMPLATE . $this->config->get('config_template') . '/template/module/bp_button.tpl')) {
			$this->template = $this->config->get('config_template') . '/template/module/bp_button.tpl';
		} else {
			$this->template = 'default/template/module/bp_button.tpl';
		}
		
		$this->render();
	}
}
?>