• Priority: 0
  • Status: Closed
  • Theme: Alysum
  • Assigned To: Fred
  • Private: No
  • Open Date: 19.08.23, 10:53
  • Opened by: Mariano Scalcon
  • Closed by: Anonymous Submitter
  • Closed on:
  • Reason: Not a bug

Ticket #24889 - Show price of product ID

I need to show the price of a specific product (ID) on the home page in a custom area.
Do I have to use the “short code” component? And Which php function Do I use?


Fred 19 Aug 2023, 18:45

Hi, Mariano Scalcon.
We don’t have such shortcode. Can’t you add the price there just as a static string like “$100”?

Mariano Scalcon 21 Aug 2023, 17:12

Because if I update the price of the product or it changes with a promotion, I don’t want to change the homepage which is made in multiple languages… Could I create a custom widget?

Fred 21 Aug 2023, 17:52

Yes, you can, it’s pretty easy
Create widget instruction:
- go to /modules/pkelements/classes
- create a new widget file based on some simple widget like WidgetPktitle.php
- write all logic there and display price