integration new theme standard
git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@8169 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
Binary file not shown.
|
After Width: | Height: | Size: 1.9 KiB |
@@ -0,0 +1,98 @@
|
||||
<?php
|
||||
/*
|
||||
* 2007-2010 PrestaShop
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.txt.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* http://opensource.org/licenses/osl-3.0.php
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to http://www.prestashop.com for more information.
|
||||
*
|
||||
* @author Prestashop SA <contact@prestashop.com>
|
||||
* @copyright 2007-2010 Prestashop SA
|
||||
* @version Release: $Revision: 1.4 $
|
||||
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
exit;
|
||||
|
||||
class blockcontact extends Module
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
$this->name = 'blockcontact';
|
||||
$this->tab = 'front_office_features';
|
||||
$this->version = '1.0';
|
||||
|
||||
parent::__construct();
|
||||
|
||||
$this->displayName = $this->l('Block contact');
|
||||
$this->description = $this->l('Allows you to add extra information about customer service');
|
||||
}
|
||||
|
||||
public function install()
|
||||
{
|
||||
return (parent::install() AND Configuration::updateValue('blockcontact_telnumber', '') AND Configuration::updateValue('blockcontact_email', '') AND $this->registerHook('rightColumn'));
|
||||
}
|
||||
|
||||
public function uninstall()
|
||||
{
|
||||
//Delete configuration
|
||||
return (Configuration::deleteByName('blockcontact_telnumber') AND Configuration::deleteByName('blockcontact_email') AND parent::uninstall());
|
||||
}
|
||||
|
||||
public function getContent()
|
||||
{
|
||||
// If we try to update the settings
|
||||
if (isset($_POST['submitModule']))
|
||||
{
|
||||
Configuration::updateValue('blockcontact_telnumber', (preg_match('/^[0-9]+/', $_POST['telnumber']) ? $_POST['telnumber']: ''));
|
||||
Configuration::updateValue('blockcontact_email', (($_POST['email'] != '') ? $_POST['email']: ''));
|
||||
echo '<div class="conf confirm"><img src="../img/admin/ok.gif"/>'.$this->l('Configuration updated').'</div>';
|
||||
}
|
||||
|
||||
return '
|
||||
<h2>'.$this->displayName.'</h2>
|
||||
<form action="'.Tools::htmlentitiesutf8($_SERVER['REQUEST_URI']).'" method="post">
|
||||
<fieldset class="width2">
|
||||
<label for="telnumber">'.$this->l('Telephone number : ').'</label>
|
||||
<input type="text" id="telnumber" name="telnumber" value="'.((Configuration::get('blockcontact_telnumber') != "") ? Configuration::get('blockcontact_telnumber') : "").'" />
|
||||
<div class="clear"> </div>
|
||||
<label for="email">'.$this->l('Email : ').'</label>
|
||||
<input type="text" id="email" name="email" value="'.((Configuration::get('blockcontact_email') != "") ? Configuration::get('blockcontact_email') : "").'" />
|
||||
<div class="clear"> </div>
|
||||
<br /><center><input type="submit" name="submitModule" value="'.$this->l('Update settings').'" class="button" /></center>
|
||||
</fieldset>
|
||||
</form>
|
||||
<div class="clear"> </div>
|
||||
<fieldset>
|
||||
<legend>Addons</legend>
|
||||
'.$this->l('This module has been developped by PrestaShop and can only be sold through').' <a href="http://addons.prestashop.com">addons.prestashop.com</a>.<br />
|
||||
'.$this->l('Please report all bugs to').' <a href="mailto:addons@prestashop.com">addons@prestashop.com</a> '.$this->l('or using our').' <a href="http://addons.prestashop.com/contact-form.php">'.$this->l('contact form').'</a>.
|
||||
</fieldset>';
|
||||
}
|
||||
|
||||
public function hookRightColumn()
|
||||
{
|
||||
global $smarty;
|
||||
|
||||
$smarty->assign(array(
|
||||
'telnumber' => Configuration::get('blockcontact_telnumber'),
|
||||
'email' => Configuration::get('blockcontact_email')
|
||||
));
|
||||
return $this->display(__FILE__, 'blockcontact.tpl');
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,35 @@
|
||||
{*
|
||||
* 2007-2011 PrestaShop
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Academic Free License (AFL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.txt.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* http://opensource.org/licenses/afl-3.0.php
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to http://www.prestashop.com for more information.
|
||||
*
|
||||
* @author PrestaShop SA <contact@prestashop.com>
|
||||
* @copyright 2007-2011 PrestaShop SA
|
||||
* @version Release: $Revision: 6594 $
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*}
|
||||
|
||||
<div id="contact_block" class="block">
|
||||
<h4>{l s='Contact us' mod='blockcontact'}</h4>
|
||||
<div class="block_content clearfix">
|
||||
<p>{l s='Our hotline' mod='blockcontact'}<br />{l s='is available 24/24' mod='blockcontact'}</p>
|
||||
{if $telnumber != ''}<p class="tel">{l s='Phone : ' mod='blockcontact'}{$telnumber}</p>{/if}
|
||||
{if $email != ''}<a href="mailto:{$email}">{l s='Contact' mod='blockcontact'}<br/> {l s='our hotline' mod='blockcontact'}</a>{/if}
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<module>
|
||||
<name>blockcontact</name>
|
||||
<displayName><![CDATA[Block contact]]></displayName>
|
||||
<version><![CDATA[1.0]]></version>
|
||||
<description><![CDATA[Allows you to add extra information about customer service]]></description>
|
||||
<author><![CDATA[]]></author>
|
||||
<tab><![CDATA[front_office_features]]></tab>
|
||||
<is_configurable>1</is_configurable>
|
||||
<need_instance>1</need_instance>
|
||||
<limited_countries></limited_countries>
|
||||
</module>
|
||||
@@ -0,0 +1,19 @@
|
||||
<?php
|
||||
|
||||
global $_MODULE;
|
||||
$_MODULE = array();
|
||||
$_MODULE['<{blockcontact}prestashop>blockcontact_2c4eb35e7132cbb2dce2f3a72cbb4787'] = 'Bloc contact';
|
||||
$_MODULE['<{blockcontact}prestashop>blockcontact_df000a5bfb01a3605e4d9343561a0d3d'] = 'Permet d\'ajouter des informations supplémentaires concernant le service client';
|
||||
$_MODULE['<{blockcontact}prestashop>blockcontact_20015706a8cbd457cbb6ea3e7d5dc9b3'] = 'Module mis à jour';
|
||||
$_MODULE['<{blockcontact}prestashop>blockcontact_85d1aa4e14d72add27a7c236962627e9'] = 'Numéro de téléphone';
|
||||
$_MODULE['<{blockcontact}prestashop>blockcontact_b17f3f4dcf653a5776792498a9b44d6a'] = 'Mettre à jour';
|
||||
$_MODULE['<{blockcontact}prestashop>blockcontact_1b9441f293cd7307b59296f616bb858a'] = 'Ce module a été développé par PrestaShop et est uniquement vendu sur';
|
||||
$_MODULE['<{blockcontact}prestashop>blockcontact_6df4dad510fb08e2e6df44b53cb2ce29'] = 'Veuillez nous signaler tout bogue à ';
|
||||
$_MODULE['<{blockcontact}prestashop>blockcontact_d575acff7e1035a4212d2a53d5a8c115'] = 'ou en utilisant notre';
|
||||
$_MODULE['<{blockcontact}prestashop>blockcontact_23372c0d3713719764670087006fc1b6'] = 'formulaire de contact';
|
||||
$_MODULE['<{blockcontact}prestashop>blockcontact_02d4482d332e1aef3437cd61c9bcc624'] = 'Contactez-nous';
|
||||
$_MODULE['<{blockcontact}prestashop>blockcontact_6e6a51212bd633f9901a22cea27194d8'] = 'Une conseillère';
|
||||
$_MODULE['<{blockcontact}prestashop>blockcontact_689681c4a40a1e95c35a83771253e8fd'] = 'à votre disposition 24/ 24h';
|
||||
$_MODULE['<{blockcontact}prestashop>blockcontact_6e6c05a143d676b33ca265b0306813fb'] = 'Tél :';
|
||||
$_MODULE['<{blockcontact}prestashop>blockcontact_bbaff12800505b22a853e8b7f4eb6a22'] = 'Contacter';
|
||||
$_MODULE['<{blockcontact}prestashop>blockcontact_e9376117c97ae76d0eefdc3e1f4486e7'] = 'notre conseillère';
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 824 B |
Reference in New Issue
Block a user