[Super Deal] Up to 50% OFF on Any Single Products & Subscriptions!
0
Your Cart is currently empty!
Product update
Coupon
add
Coupon code invalid! Please re-enter!
AJAX loader
You are here: HomeForum

We are here to serve :)

Our support team is currently online to solve your issues.

Our support team is currently offline

Our support heroes might not be around this hour. Please expect some delays.

Our support is available from

Monday - Friday 8am - 5:30pm GMT+7

Your time: 00:00:00
Our time: 00:00:00

Welcome, Guest

Image of the k2 element with a link to this element
(1 viewing) (1) Guest
  • Page:
  • 1

TOPIC: Image of the k2 element with a link to this element

Image of the k2 element with a link to this element 2 months ago #41891

Image of the k2 element with a link to this element. How to do it in this module? Just like in the demo: demo.smartaddons.com/extensions/joomla3/sj-k2-slick-slider. Thank you for your help.

Re: Image of the k2 element with a link to this element 2 months ago #41892

Yes, you can link the image of an article to the article itself. /templates/[YOUR-THEME]/html/mod_sj_k2_slickslider/default.php
<?php 
					$img = K2SlickSliderHelper::getK2Image($item, $params);					
					$img = ImageHelper::init($img)->src();
					
					if(!file_exists($img)){
						$img = 'modules/'.$module->module.'/assets/images/nophoto.jpg';
					}
					
					$img = (strpos($img,'http://') !== false || strpos($img,'https://') !== false)?$img:(JURI::root().$img);
					
    		if ($img): ?>
    		<div class="item-image">
    			<div class="item-image-inner">
					<a href="<?php echo $item->link; ?>" title="<?php echo $item->displaytitle; ?>" <?php echo K2SlickSliderHelper::parseTarget($params->get('item_link_target')); ?> >					
		            	<img alt="<?php echo $item->displaytitle;?>" src="<?php echo $img;?>"/>					
					</a>
				</div>
			</div>
			<?php endif; ?>
The following user(s) said Thank You: andrzejgajewski

Re: Image of the k2 element with a link to this element 2 months ago #41894


It works! Thank you very much!

Re: Image of the k2 element with a link to this element 2 months ago #41908

That's great.
  • Page:
  • 1
Time to create page: 0.41 seconds

Notification

Please find your issue via Suggested Posts before submitting your question. We have solved the most of issues and maybe your issue was solved before.
Up to 50% OFF Storewide on Thanksgiving, Black Friday & Cyber Monday

Suggested Posts

(/)
Result not found!

Latest My Topics

No posts to display.

Love all our templates?

Join our membership clubs starting at $49 only for access to all of our templates

Join Now
Magento Themes Magento Extensions Free Magento Extensions Prestashop Themes Prestashop Modules Magento 2 Themes
Quà Tết Cao Cấp Hộp quà tết Giỏ quà tết Túi quà tết