我一直在擺弄我的Pytheas theme再次。這一次,我正在嘗試在我的頁面和帖子的背景上插入一張2色gif(適合拼貼)。請注意,我做的不是是指整個頁面的背景。那就是,應該保持黑色。相關網站/示例帖子是here。如何將重複的平鋪圖像插入WordPress頁面或帖子的背景(而非頁面背景)?
我已經進行了廣泛調查,因爲我可以給我的編碼缺陷。目前,我一直在編輯styles.css文件。我換成這個默認代碼:
/* Body & Main
================================================== */
body { background: #eee url("images/main-bg.png") repeat; nowhitespace: afterproperty; font: 12px/1.8 'Helvetica Neue', Helvetica, Arial, sans-serif; color: #444; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: 100%; }
body a { color: #f15a23 } /*main link color*/
body a:hover { text-decoration: none; color: #000 }
與此修訂代碼,我與我的CSS的朦朧認識拼湊起來。
body {
background: url("http://longgame.org/wp-content/uploads/grid-paper-2color-start.gif") repeat; nowhitespace: afterproperty;
background-repeat: repeat;
background-color:rgba(255,255,255,0.0);
font: 12px/1.8 'Helvetica Neue', Helvetica, Arial, sans-serif; color: #444; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: 100%;
}
我的想法是,我需要的是RGBA位,以確保顏色是透明的(如果紋理是「落後」的話)。我不知道。我正在擲飛鏢。也許它是在錯誤的地方。也許這只是錯誤的。 :)
我轉向你更合格的人來幫助我。預先感謝您提供的任何指導。
完美!那是不快的。非常感謝你,metadept。 – DocBadwrench
@DocBadwrench非常歡迎:) – metadept