2013-08-28 19 views
3

我一直在努力解決這個問題,我會非常感激一些指導。
我試圖重新創建黑圈,與MM/DD/YY一起,如本主題:http://www.bluchic.com/how-to-change-header-text-to-a-logo-image-for-adelle-theme在WordPress的CSS Circle Mods,在哪裏插入代碼?

所以我抓住下面的代碼

} .post-date { 
background: #000; 
border-radius: 100px; 
float: left; 
font-size: 12px; 
font-size: 1.2rem; 
line-height: 1.1; 
margin-right: 0.667em; 
padding: 0.95em 1.05em; 
text-align: center; 
text-transform: uppercase; 
width: 48px; 
} 
.post-date a { 
color: #ddd; 
} 
.post-date span { 
display: block; 
} 
.post-date .entry-day { 
color: #fff; 
font-size: 21px; 
font-size: 2.1rem; 
} 

我想把它放到這個主題中:http://sandbox.erinchambers.com/

但是,在過去的幾年中,我已經離開了CSS,下面是我認爲我應該使用的代碼片段?我很困惑,因爲CSS版本看起來不一樣?

/* .article */ 

.article .article-content {width: 680px; float: right;} 
    .article .post-header {margin-bottom: 30px; padding-top: 5px; border-top: 5px solid #000; border- bottom: 1px solid #000;} 
    .article .post-meta {width: 240px; float: left; overflow: hidden;} 
    .article ul.post-info-meta {overflow: hidden; font-size: .9em; margin: 5px 0; list-style: none;} 
    .article ul.post-info-meta span {text-transform: uppercase; display: block; font-weight: 700;} 
    .article ul.post-info-meta li {margin-bottom: 1px; padding: 0 0 0px 0px;} 

我不知道,我應該在我的樣式表可以編輯代碼,如果我要製作子主題來做到這一點,或者如果我也有一些額外的HTML或PHP寫的?如果是的話,我應該插入它嗎?

+0

使用div創建圈子! –

+1

我只是輕微地編輯了wordpress模板幾次,但我認爲你是在正確的軌道上。我相信你需要做兩件事。 ** 1。**在創建'post header'div的區域內的php頁面模板中創建一個新的div(用於圓圈)。 ** 2。**爲圈子創建一個新班級。你已經找到了css的正確部分,並且你有上面的必要代碼來創建一個圓形'border-radius'。 – Mal

回答

0

如果你知道一點HTML和CSS,你只需要拿起一些簡單的指南來指導如何編輯Wordpress主題。

聰明的事情就是複製你想改變的樣式並將它下載到本地機器上,這樣你就可以熟悉主題的資源。

添加了一圈,你的情況是很簡單的

.post-date time 
{ 
    -webkit-border-radius: 50%; 
    -moz-border-radius: 50%; 
    border-radius: 50%; 
    color: #fff; 
    background: #000; 
    text-align: center; 
} 

爲了解釋我做了什麼有

  • 你已經有了一個標籤帶班被稱爲「。員額最新
  • 在那li標籤你有兩個子標籤sp一個時間
  • 我們的目標是有一個特定的子類和分配屬性它

在條款最短,如果你想下去又髒。您可以在當前主題中打開style.css,而不需要複製任何內容,只需在文件底部添加上面的代碼即可。