3

Is it possible to move up label, below the fields? And where I can find it? I tried in validation.js, but didn't have much luck.

enter image description here

  • Already warning message are showing at correct place in my case. Did you changed anything before or you can check console errors – Nitin Pawar Nov 22 '16 at 11:54
  • No, I didn't change anything. Other warnings are fine, but only this one is move down. Have no idea how to move it up, since it's all added via js. – codeIT Nov 22 '16 at 11:57
2

By default this warning message comes from core module Magento Swatches.

vendor/magento/module-swatches/view/frontend/web/js/swatch-renderer.js

Override core js file into your theme,

/app/design/frontend/{Packagename}}/{themename}}/Magento_Swatches/web/js/swatch-renderer.js

Replace

 if ($widget.productForm) {
    $widget.productForm.append(input);
    input = '';
}

with,

if ($widget.productForm) {
    $widget.productForm.find('#product-options-wrapper').after(input);
    input = '';
}
| improve this answer | |
  • Thank youu, a lot! – codeIT Nov 22 '16 at 12:01

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.