*

fabio

  • ***
  • 40 posts
Image and partner links
« on: May 10, 2017, 10:45:01 AM »
I would like to include links for each image
Also change the image
I do not know how to change footer.php
Can you help me please

http://prntscr.com/f6477p

*

MB Themes

Re: Image and partner links
« Reply #1 on: May 10, 2017, 10:56:53 AM »
@fabio
In file oc-content/themes/veronika/footer.php

Following code needs to be changed:
Code: [Select]
      <?php 
        $partner_path 
osc_base_path() . 'oc-content/themes/' osc_current_web_theme() . '/images/partner-logos'
        
$partner_url osc_base_url() . 'oc-content/themes/' osc_current_web_theme() . '/images/partner-logos'
        
$partner_images scandir($partner_path);

        if(isset(
$partner_images) && !empty($partner_images) && $partner_images <> '') {
          foreach(
$partner_images as $img) {
            
$ext strtolower(pathinfo($partner_path '/' $imgPATHINFO_EXTENSION));
            
$allowed_ext = array('png''jpg''jpeg''gif');

            if(
in_array($ext$allowed_ext)) {
              echo 
'<img class="partner-image" src="' $partner_url '/' $img '" alt="' __('Our partner logo''veronika') . '" />';
            }
          }
        }
      
?>

to something like this:
Code: [Select]
<a href="http://www.your_url.com"><img class="partner-image" src="http://www.your_url.com/my_image.jpg" /></a>

you need to define it for each logo image and change link in href and src tags.
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

fabio

  • ***
  • 40 posts
Re: Image and partner links
« Reply #2 on: May 10, 2017, 01:28:31 PM »
But where I must enter the code:
<a href="http://www.your_url.com"> <img class = "partner-image" src = "http://www.your_url.com/my_image.jpg" /> </a>

*

MB Themes

Re: Image and partner links
« Reply #3 on: May 10, 2017, 03:48:13 PM »
@fabio
In footer instead of first part of code I have posted in previous post (starting with <?php, ending with ?>)
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots