是否有任何技術術語的全圖像爲中心的技術?
例如:topgear.com,http://safe.tumblr.com/theme/preview/979,以及其他許多我不記得的東西。背景圖像技術
背景圖像技術
回答
您可以創建一個大尺寸的圖像(例如2000px
寬度/高度)並將其設置爲背景background-position: 50% 50%
。或者,您可以在body
標記上添加一個<img src="background.jpg" width="100%" height="100%" />
,並確定它將根據頁面大小進行拉伸。
背景位置:50%50%不會垂直和水平居中。它將bg的起點設置到屏幕的中心。 – 2010-08-03 09:19:49
我不認爲它有一個特定的名稱。下面是與國家的最先進的一些技巧的文章:
http://www.alistapart.com/articles/supersize-that-background-please/
謝謝,這就是我正在談論的 – 2010-08-03 09:17:56
我不這麼認爲,沒有。圖像只放在主div內(在這種情況下#wrap)。它有一些左右填充,所以它會被設置在正確的中間。但是,您可以使用與主div相同大小的圖像。
下面是該網站使用的代碼:
#wrap {
background: url("http://static.tumblr.com/xsp9wak/xAOkloi15/background-top.jpg") no-repeat scroll center top transparent;
margin: 0 auto;
overflow: hidden;
padding-left: 28px;
padding-right: 28px;
position: relative;
width: 905px;
PS:有很多方法可以做到這一點。
- 1. 「單精靈背景圖像」的背景定位技術
- 2. css技巧爲背景圖像模糊
- 3. 在背景圖像背景圖像
- 4. 圖像分割技術
- 5. 圖像壓縮技術
- 6. 圖像存儲技術
- 7. 使用圖像技術
- 8. 可變高度與自定義背景圖像 - 什麼是最好的技術?
- 9. 圖像背景
- 10. 背景圖像
- 11. 背景圖像
- 12. 背景圖片上的背景圖像
- 13. cinemagraph背後的技術
- 14. Google Instant背後的技術?
- 15. 背景圖像css
- 16. SVG背景圖像
- 17. 背景圖像tamplete
- 18. 背景圖像URL
- 19. 背景html圖像
- 20. UITableViewController - 圖像背景
- 21. CSS背景圖像
- 22. 背景圖像GUI
- 23. 與背景圖像
- 24. 背景圖像AndroidStudio
- 25. Div背景圖像
- 26. 背景圖像CSS
- 27. TabWidget背景圖像
- 28. 背景圖像EVAL
- 29. Android背景圖像
- 30. VML背景圖像
我不知道你在說什麼。 – 2010-08-01 18:27:37
我也不知道。 – zneak 2010-08-01 18:28:25
你的意思是應用於'id =「wrap」'元素的背景嗎?這只是'背景:url(「http://static.tumblr.com/xsp9wak/xAOkloi15/background-top.jpg」)無重複滾動中心頂部透明;' – 2010-08-01 18:32:04