• Closed by: Marek
  • Closed on: 20.09.19, 13:01
  • Reason: Closed
  • Comment: Glad to help!

Ticket #15632 - Link icons

I want to know how I can put an icon to a link created with the Custom Links module.

Attached image as proof.

Thanks and best regards.

Comments

Marek 20 Sep 2019, 11:02

There is no way to assign an icon for created custom link. You can only do that in the file /modules/pk_customlinks/pk_customlinks.tpl

Horticulture Tecnique del Sureste S.L. 20 Sep 2019, 11:43

How can I do it?

Marek 20 Sep 2019, 11:59

Here is an example of the link code you have to add to that file right after </ul> at the line #4

<li class="dib smooth02">
	<a href="#LINK" class="flex-container align-items-center icon-element">
		<svg class="svgic main_color svgic-ICON"><use xlink:href="#si-ICON"></use></svg>
		<span>{l s='TEXT' mod='pk_customlinks'}</span>
	</a>
</li>

Select the icon here http://alysum5.promokit.eu/promokit/documentation/#svg

Horticulture Tecnique del Sureste S.L. 20 Sep 2019, 12:08

Yes, I already did that, attached example:

<li class=”pk_account dd_el dib smooth02”>

   <a href="{$link->getPageLink('/tiendas', true)}" title="{l s='Tiendas' mod='pk_customlinks'}" class="flex-container align-items-center icon-element">
   <div class="principal">
  <div class="icono">
	svg class="svgic main_color svgic-account"><use xlink:href="#si-location"></use></svg>
   </div>
   <span>{l s='My Account' mod='pk_customlinks'}</span>
   </div>
   </a>

</li>

But what I want to know is how can I get the url to take, as it appears in $ link→ getPageLink and also the option to dial it from the Custom Link module.

Marek 20 Sep 2019, 12:34

You have to use variables, here is the list of all available options https://catalogo-onlinersi.net/en/content/33-prestashop-17-global-variables

Horticulture Tecnique del Sureste S.L. 20 Sep 2019, 13:01

Okey, thanks!