Page 1 of 1

2 Column product view in mobile phones are not aligned

Posted: Sun May 24, 2020 5:53 pm
by azonicdh
Hello. So I changed the \catalog\view\javascript\common.js file specifically the line from 'col-xs-12' to 'col-xs-6'

Code: Select all

if (cols == 2) {
			$('#content .product-list').attr('class', 'product-layout product-grid col-lg-6 col-md-6 col-sm-12 col-xs-6');
		} else if (cols == 1) {
			$('#content .product-list').attr('class', 'product-layout product-grid col-lg-4 col-md-4 col-sm-6 col-xs-6');
		} else {
			$('#content .product-list').attr('class', 'product-layout product-grid col-lg-3 col-md-3 col-sm-6 col-xs-6');
It is now showing two columns of products but the alignment seems to be messed up. Does anyone know where I can change this so it will be aligned. Please see attached screenshot from my mobile phone.

Re: 2 Column product view in mobile phones are not aligned

Posted: Tue Sep 22, 2020 6:02 pm
by anung
Add this CSS code to the /catalog/view/theme/default/stylesheet/stylesheet.css file

Code: Select all

.caption h4 {
    min-height: 125px;
}
.caption p:nth-of-type(1) {
    min-height: 125px;
}

Re: 2 Column product view in mobile phones are not aligned

Posted: Tue Jan 12, 2021 1:08 pm
by azonicdh
anung wrote:
Tue Sep 22, 2020 6:02 pm
Add this CSS code to the /catalog/view/theme/default/stylesheet/stylesheet.css file

Code: Select all

.caption h4 {
    min-height: 125px;
}
.caption p:nth-of-type(1) {
    min-height: 125px;
}
Thanks for the help. It works.