Img path and description

This commit is contained in:
Michael RICOIS 2017-08-28 12:32:45 +02:00
parent 8d7ccb4d3f
commit fcf69fedec
2 changed files with 5 additions and 3 deletions

View File

@ -238,6 +238,7 @@ class AdminAdvSliderController extends ModuleAdminController
$this->fields_form['input'][] = array(
'type' => 'file',
'label' => $this->l('Image'),
'desc' => $this->l('Image de 940 x 300 px'),
'name' => 'image',
'display_image' => TRUE,
'lang' => TRUE,
@ -249,7 +250,8 @@ class AdminAdvSliderController extends ModuleAdminController
$this->fields_form['input'][] = array(
'type' => 'file',
'label' => $this->l('Image Mobile 900x900'),
'label' => $this->l('Image Mobile'),
'desc' => $this->l('Image de 300 x 200 px'),
'name' => 'image_mobile',
'display_image' => TRUE,
'lang' => TRUE,

View File

@ -4,7 +4,7 @@
<div id="slider_home" class="clearfix snotmobile">
<div class="clearfix owl">
{foreach from=$slides item=slide key=key name=slider}
<div class="col-sm-12 slide-home item" style="height:300px;background: url('{$img_ps_dir}tmp/advslider_{$slide.id_slide}.jpg') no-repeat left top; background-size: 100% auto;">
<div class="col-sm-12 slide-home item" style="height:300px;background: url('{$img_ps_dir}slider/{$slide.id_slide}.jpg') no-repeat left top; background-size: 100% auto;">
{if isset($slide.url) && $slide.url}
<a href="{$slide.url}" style="width:100%;height: 100%;display: block;" {if isset($slide.title) && $slide.title}title="{$slide.title}"{/if}></a>
{/if}
@ -16,7 +16,7 @@
<div id="slider_home_mobile" class="clearfix smobile">
<div class="clearfix owl">
{foreach from=$slides item=slide key=key name=slider}
<div class="col-sm-12 slide-home item" style="height:200px;background: url('{$img_ps_dir}tmp/advslider_mini_{$slide.id_slide}_1.jpg') no-repeat center top; background-size: contain;">
<div class="col-sm-12 slide-home item" style="height:200px;background: url('{$img_ps_dir}slider/{$slide.id_slide}_1.jpg') no-repeat center top; background-size: contain;">
{if isset($slide.url) && $slide.url}
<a {if !$cookie->logged}onclick="window.location.href='{$link->getPageLink('authentication', true)|escape:'html':'UTF-8'}';"{else}href="{$slide.url}"{/if} style="width:100%;height: 100%;display: block;" {if isset($slide.title) && $slide.title}title="{$slide.title}"{/if}></a>
{/if}