發表主題   回覆主題  
 

自訂風格管理 - 圖片縮放問題

2015/04/01 09:36 由 sa

 

 

如果您有自訂網站的 css,並且商品圖片縮放有問題,請嘗試以下修改

 

 

  1. 進入風格管理,點擊「綠色齒輪」進入編輯

 

 

 

  1. 找到 .portal_items .itemBase .itemCover img 標籤的位置


修改成以下程式碼

.portal_items .itemBase .itemCover img {

float: none;

width: auto;

           }

 

 

 

  1. 找到 #item-body .itemList .itemSpace .itemBlock .itemImgThumb img 標籤的位置,並將其刪除

 

 

 

  1. 找到 .itemImgThumb img 標籤的位置


修改成以下程式碼

.itemImgThumb img {

float: none;

width: auto;

           }

 

 

 

  1. 在 css 最後加入以下程式碼

#content #contentMain .itemContent .itemDesc img {

max-width: 100%;

}

 

.item_img_parent {

position: relative;

}

 

.item_img_resize {

width: auto;

height: auto;

max-width: 100%;

max-height: 100%;

position: absolute;

top: 0;

left: 0;

right: 0;

bottom: 0;

margin: auto;

           }