2017-01-16 13 views
0

#sitedescriptionは浮動小数点になりませんので、#title-linkの下にthis siteと表示されます。CSS:divは左に浮動しません(浮動小数点:左)

.header #logo {position: relative; width: 90px; float: left;} 
.header #title-link {position: relative; height: 20px; width: 200px; margin-bottom: 11px; float: left;} 
.header #sitedescription {position: relative; height: 14px; width: 200px; float: left;} 
.header #sitedescription h2 {position: relative; font-size: 11px; color: #622C82;} 

<div class="logo"> 
    <div id="logo"><a href="/"><img id="header-logo" src="/wp-content/themes/madhatmedia/images/header-logo.png" data-pin-nopin="true"></a></div> 
    <div id="title-link"><a href="/"><h1 class="title">Mad Hat Media</h1></a></div> 
    <div id="sitedescription"><h2>Marketing Agency Fremantle</h2></div> 
</div> 

ヘッダーは次のように見ている必要があります enter image description here

ヘルプは感謝しています。

答えて

0

updated screenshot .header #sitedescriptionから浮動小数点数を削除するとタイトルの下に追加されます。

.header #sitedescription {position: relative; height: 14px; width: 300px;} 
+0

ありがとうVNP。その解決策は私には意味がありません。 :-) – Steve

0

こんにちはあなたはそれを明確にすることができます。両方のコード以下のように(そのクラスでは、余分なコードを追加)し、あなたが

.header #sitedescription { 
position: relative; 
height: 14px; 
width: 300px; 
display: block; 
clear: right; 
left: -27px; 
} 

Demo

感謝を望むように、フォントサイズを大きく

関連する問題