2016-10-05 64 views
-1

我必須從頭開始爲一個項目做一個網頁,而且我對HTML一無所知。我剛開始創建我的導航欄。如何將字體更改爲centhury哥特式?以及如何爲背景添加透明度。如果您可以告訴我如何將「主頁」頁面更改爲將您鏈接到主頁的徽標,這也會非常有幫助。提前非常感謝任何人的幫助!到目前爲止,我有這樣的:如何在導航欄中添加字體和透明度?

<!DOCTYPE html> 
<html> 
    <head> 
    <style> 
     ul { 
      list-style-type: none; 
      margin: 0; 
      padding: 0; 
      overflow: hidden; 
      border: 1px solid #e7e7e7; 
      background-color: grey; 
     } 
     li { 
      float: left; 
     } 
     li a { 
      display: block; 
      color: white; 
      text-align: center; 
      padding: 34px 85px; 
      text-decoration: none; 
     } 
     li a:hover:not(.active) { 
      background-color: #grey; 
     } 
     li a.active { 
      color: white; 
      background-color: #4CAF50; 
     } 
    </style> 
    </head> 
    <body> 
    <ul> 
     <li><a class="active" href="#home">Home</a></li> 
     <li><a href="#Social">Social</a></li> 
     <li><a href="#Comercial">Comercial</a></li> 
     <li><a href="#Sobre el fotógrafo">Sobre el fotógrafo</a></li> 
     <li><a href="#Contacto">Contacto</a></li> 
    </ul> 
    </body> 
</html> 
+0

font-family,用於字體。透明的顏色使用rgba。 rgba(255,255,255,0.5)白色50%可見。 – pol

回答

0

要更改字體世紀的哥特式使用:

font-family: "Century Gothic", CenturyGothic, AppleGothic, sans-serif; 

使home鍵,你可以使用圖像:

<img src="Image.png" height="" width=""> 

最後使背景透明使用rgba(它支持alpha):

background-color: rgba(119, 119, 119, 0.5); 

Here is an example,我還沒有整理你的代碼,但這可能會給你一個良好的開端。