[Skip to main content](#vessel-content)

#   Price per unit and price per meter

##

- **[nina2011](/forum/user/762-nina2011 "View nina2011's Profile")**
- [![nina2011's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar762.gif)](/forum/user/762-nina2011 "View nina2011's Profile") Topic Author
- [ Offline](/forum/user/762-nina2011)

Less More

- Posts: 13
- Thank you received: 0
-
-

15 years 9 months ago [\#5788](#5788) by [nina2011](/forum/user/762-nina2011 "View nina2011's Profile")  *[Price per unit and price per meter](/forum/4-how-to/5788-price-per-unit-and-price-per-meter#5788 "Hi,  I need to have price per unit on some of my products and price per unit on others. I cannot find anywhere to set it on the individual products, only for the entire shop. Can I change this?  Thanks")* was created by *[nina2011](/forum/user/762-nina2011 "View nina2011's Profile")*

Hi,

I need to have price per unit on some of my products and price per unit on others. I cannot find anywhere to set it on the individual products, only for the entire shop. Can I change this?

Thanks

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzU3ODgtcHJpY2UtcGVyLXVuaXQtYW5kLXByaWNlLXBlci1tZXRlcj90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nina2011](/forum/user/762-nina2011 "View nina2011's Profile")**
- [![nina2011's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar762.gif)](/forum/user/762-nina2011 "View nina2011's Profile") Topic Author
- [ Offline](/forum/user/762-nina2011)

Less More

- Posts: 13
- Thank you received: 0
-
-

15 years 9 months ago [\#5789](#5789) by [nina2011](/forum/user/762-nina2011 "View nina2011's Profile")  Replied by *[nina2011](/forum/user/762-nina2011 "View nina2011's Profile")* on topic *[Re: Price per unit and price per meter](/forum/4-how-to/5788-price-per-unit-and-price-per-meter#5789 "Hi,  I need to have price per unit on some of my products and price per unit on others. I cannot find anywhere to set it on the individual products, only for the entire shop. Can I change this?  Thanks")*

Per unit and per meter of course...

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzU3ODgtcHJpY2UtcGVyLXVuaXQtYW5kLXByaWNlLXBlci1tZXRlcj90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86292
- Thank you received: 14271
-
-

15 years 9 months ago [\#5793](#5793) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Re: Price per unit and price per meter](/forum/4-how-to/5788-price-per-unit-and-price-per-meter#5793 "Hi,  I need to have price per unit on some of my products and price per unit on others. I cannot find anywhere to set it on the individual products, only for the entire shop. Can I change this?  Thanks")*

Hi,

Not easily. If can edit the file listing_price of the view product via the menu Display-&gt;Views in order to add a condition on the display of the price so that you could change the text:
echo JText::_('PER_UNIT');

You could for example add a custom product field (available in the commercial versions via the menu Display-&gt;Custom fields) radio button to select which type of text to display. Suppose that you call that custom field "meter", you could use the code:
if($this-&gt;row-&gt;meter){
echo ' per meter';
}else{
echo JText::_('PER_UNIT');
}

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzU3ODgtcHJpY2UtcGVyLXVuaXQtYW5kLXByaWNlLXBlci1tZXRlcj90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[b3n.maclean](/forum/user/8377-b3n-maclean "View b3n.maclean's Profile")**
- [![b3n.maclean's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/8377-b3n-maclean "View b3n.maclean's Profile")
- [ Offline](/forum/user/8377-b3n-maclean)

Less More

- Posts: 1
- Thank you received: 0
-
-

14 years 1 month ago [\#65541](#65541) by [b3n.maclean](/forum/user/8377-b3n-maclean "View b3n.maclean's Profile")  Replied by *[b3n.maclean](/forum/user/8377-b3n-maclean "View b3n.maclean's Profile")* on topic *[Re: Price per unit and price per meter](/forum/4-how-to/5788-price-per-unit-and-price-per-meter#65541 "Hi,  I need to have price per unit on some of my products and price per unit on others. I cannot find anywhere to set it on the individual products, only for the entire shop. Can I change this?  Thanks")*

Hi Nicolas

I've been trying to work this out also. Could you please elaborate on the above - ie where does the above code actually go? I am very new to PHP and joomla in general. I have Hikashop Essential so should be able to do this, just not sure about the code.

Thanks
Ben

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzU3ODgtcHJpY2UtcGVyLXVuaXQtYW5kLXByaWNlLXBlci1tZXRlcj90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86292
- Thank you received: 14271
-
-

14 years 1 month ago [\#65731](#65731) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Re: Price per unit and price per meter](/forum/4-how-to/5788-price-per-unit-and-price-per-meter#65731 "Hi,  I need to have price per unit on some of my products and price per unit on others. I cannot find anywhere to set it on the individual products, only for the entire shop. Can I change this?  Thanks")*

Hi,

I explained it all in my message.
You need to edit the file listing_price of the view product via the menu Display-&gt;Views.
Then, replace the code:
echo JText::_('PER_UNIT');

by:
if($this-&gt;row-&gt;meter){
echo ' per meter';
}else{
echo JText::_('PER_UNIT');
}

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzU3ODgtcHJpY2UtcGVyLXVuaXQtYW5kLXByaWNlLXBlci1tZXRlcj90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop- Install &amp; Update- Product &amp; Category Display- Content Creation- Sales and Orders- - Orders management- - Reports &amp; Statistics- Customers- Checkout- Payment Methods- Shipping Methods- Import &amp; Export (CSV, XLS…)- Specific Features- - Affilation- - Taxes- - Wishlist- - Vote- - Carousel &amp; Slider- - Mass Actions- - Filters &amp; Search- - Discount &amp; Coupon- - Feature Request- Integrations- Showcase- General Talk about HikaShop- Development- - HikaShop 3.0 Beta- Translation- Commercial Jobs HikaShop Components- HikaMarket- - Market: Feature requests- - Market: How to?- - Market: Bug Report- HikaSerial- - General talk about HikaSerial- - Serial: Bug Report- - Serial: How to?- - Support en Français de HikaSerial (French Support)- - HikaSubscription- HikaAuction- - Auction: Feature requests- - Auction: How to?- - Auction: Bug report Hikashop around the world- Support en Français (French Support)- Russian- - FAQ. Курс выживания с Hikashop. Частые вопросы и о- - Расширения Hikashop- - Наши сайты на Hikashop- 日本語版サポート(Japanese Support)- Thai- German Archives- Bug Report- How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.192 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)

[](#top)
