Carousel Mobile

  • Posts: 5
  • Thank you received: 0
1 week 11 hours ago #337391

-- HikaShop version -- : 4.2.3
-- Joomla version -- : 3.9.24
-- PHP version -- : 7.2

I want to add a clickable link "SEE ALL ITEMS" at the bottom of hikashop content module Carousel so that one can click the link and go to the products listing/categories listing to display items in the configured source category of the carousel. I am sure I need to edit code in the carousel.php file; DISPLAY-VIEWS-Carousel for products/categories basing on some parameters like menu and main category to create a clickable link. Please some guidance.

Please Log in or Create an account to join the conversation.

  • Posts: 3381
  • Thank you received: 448
  • MODERATOR
6 days 19 hours ago #337394

Hello,

Before be able to answer you precisely, can you provide your carousel settings screenshot, please ?
This will allow us to better understand your context, and answer you more precisely.

Awaiting your element to progress.
Regards

Please Log in or Create an account to join the conversation.

  • Posts: 5
  • Thank you received: 0
6 days 13 hours ago #337417

Please see attached screen shots. 1-3 in top to bottom order. Carousel is set to Auto.
Thank You.

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 3381
  • Thank you received: 448
  • MODERATOR
5 days 20 hours ago #337434

Hello,

Thank you for your additional information, the best solution is to proceed to an override view from the product/carousel view.
Follow me step by step to learn how to process :
1. Have a look on this tutorial to learn how to create an override view.
2. Then create your button and your url link to redirect the user to your wanted item listing.
By example :
<a class="hikabtn hikacart" href="YourWebsite/product_listing_url">
<span>View all</span>
</a>

In order to use the regular css don't forget to add the class as on my example in red, hikabtn hikacart

And you must insert it at the end of your view.
Hope this will help you to achieved what you need.

Regards

Last edit: 6 days 7 hours ago by Philip.

Please Log in or Create an account to join the conversation.

  • Posts: 5
  • Thank you received: 0
4 days 15 hours ago #337464

Yes that is coding the "View All" clickable link in the Products/Category Carousel view; it works but not a solution when you have multiple instances of the carousel module in the website because it will keep pasting the same link on different carousels.
This is what we need:


<a class="hikabtn hikacart" href="<?php CODE to get the selected menu option in hikashop content module for the products/category listing of the carousel and identify the corresponding menu URL and insert it here ?> ">
<span>View all</span>
</a>

MAY YOU PLEASE GUIDE US ON THE PROPER CODE TO INSERT THE LINK AS ABOVE?

That way each instance of the content module with carousel enabled will have the correct "View All Link". Its a good feature for smaller displays like smart phones and reduce website bounce rates.

Alternatively Hikashop should add a "View All Link" option in the carousel options to ease the process.

Please Log in or Create an account to join the conversation.

  • Posts: 74250
  • Thank you received: 11418
  • MODERATOR
3 days 6 hours ago #337503

Hi,

The code should be something like that:

<?php JRoute::_('index.php?option=com_hikashop&view=product&layout=listing&Itemid='.$this->params->get('itemid')); ?>

Last edit: 3 days 6 hours ago by nicolas.

Please Log in or Create an account to join the conversation.

Time to create page: 0.067 seconds
Powered by Kunena Forum