0

I am new in Magento and now I am trying to disable the price label on the product page. I tried to modify the price.phtml, but I can't find it out.

enter image description here

Chrome Inspect:

<div class="price-box" itemprop="offers" itemscope="" itemtype="http://schema.org/Offer">
 <span class="regular-price" itemprop="price" id="product-price-123">
    <span style="color: #F51361; font-size: 31px; ">MOQ:</span>
    <span class="price">:41.00</span>
 </span>

How can I delete the label? Thx a lot...

  • I posted answer but it seems you need to remove currency sign? – Jai Jan 23 '17 at 12:42
2

Go to this file: Custom THEME:

/app/design/frontend/NAMESPACE/YOUR_THEME/Magento_Catalog/templates/product/view/attribute.phtml 

This is extended file of core file:

vendor/magento/module-catalog/view/frontend/templates/product/view/attribute.phtml

Line no: 36 is displaying code. You can Go to

<strong class="type"><?php /* @escapeNotVerified */ echo $_attributeLabel?></strong>

You can delete above line and label will be deleted. It will solve your problem.

| improve this answer | |
  • Sorry for late reply...I go into that file, but I can't see those code..I will post attributes.phtml on my question..Thx – MRBALL DX Jan 24 '17 at 1:19
  • Its attribute.phtml not attributeS.phtml . plz note its without S. you will get code there. – Jai Jan 24 '17 at 3:51
1

update code

app/design/frontend/package/theme name/template/catalog/product/price.phtml file 

you find the word MOQ: and remove it from that file

| improve this answer | |
  • That is the chrome inspect only... – MRBALL DX Jan 23 '17 at 12:25
0

add this css code in your css file

this will hide the price lable and you dont need to change phtml file , simple solution for you.

.regular-price span:first-child {
    display :none;  
}
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.