cara membuat website full background

Membuat Website Dengan Background Full

Posted on Posted in Belajar HTML, Pembuatan website

Saat ini teknik mendesain website sangat beragam, salah satu yang digemari para desainer yaitu membuat sebuah gambar menjadi background yang full satu halaman. Gambar full background akan menciptakan efek elegan pada website, tentunya harus didukung dengan pemilihan gambar yang bagus, jenis dan warna font yang dipakai juga menentukan.

Bagaimana cara membuat halaman website full background tersebut,  tidak terlalu sulit, pada tulisan ini wakaka design akan memberikan potongan kode yang berguna untuk membuat sebuah gambar menjadi full background.

Kita akan memanfaatkan fungsi css bernama Background-size.

Inti dari membuat website full background adalah menggunakan potongan kode seperti ini, bisa diterapkan di tag html, atau body.

html{
	background: url(img/bromo.jpg) no-repeat center center fixed;
	-webkit-background-size: cover;
	-moz-background-size: cover;
	-o-background-size: cover;
	background-size: cover;
}

Mulai dengan memilih gambar

Oke mari kita mulai dengan memilih gambar yang tepat, pada tulisan ini saya menggunakan gambar dari Daniele Parisi

Gunung Bromo

Gunung Bromo

Membuat Struktur HTML

Pada tulisan ini kita akan menggunakan 2 buah Font yang akan kita embed dari Google Web Fonts, yaitu

Oleh Script dan Open Sans

Rancangan struktur yang akan kita buat terdiri dari :

  • header, untuk menempatkan judul website.
  • content, untuk menuliskan isi dari website.
  • footer, untuk menuliskan hak cipta dan sumber.

berikut ini kode selengkapnya :

<div class="container">

	<div class="header">
		<h1 class="brand">Mount Bromo</h1>
		<span class="red">East Java,</span> <span class="white">Indonesia</span>
	</div>

	<div class="content">
		<p>Mount Bromo (Indonesian: Gunung Bromo), is an active volcano and part of the Tengger massif, in East Java, Indonesia. At 2,329 metres (7,641 ft) it is not the highest peak of the massif, but is the most well known. The massif area is one of the most visited tourist attractions in East Java, Indonesia. The volcano belongs to the Bromo Tengger Semeru National Park. The name of Bromo derived from Javanese pronunciation of Brahma, the Hindu creator god.</p>
		<p>Mount Bromo sits in the middle of a vast plain called the "Sea of Sand" (Javanese: Segara Wedi or Indonesian: Lautan Pasir), a protected nature reserve since 1919. The typical way to visit Mount Bromo is from the nearby mountain village of Cemoro Lawang. From there it is possible to walk to the volcano in about 45 minutes, but it is also possible to take an organised jeep tour, which includes a stop at the viewpoint on Mount Penanjakan (2,770 m or 9,088 ft) (Indonesian: Gunung Penanjakan). The best views from Mount Bromo to the Sand Sea below and the surrounding volcanoes are at sunrise. The viewpoint on Mount Penanjakan can also be reached on foot in about two hours. From inside the caldera, sulfur is collected by workers <a href="http://en.wikipedia.org/wiki/Mount_Bromo">Read More</a></p>
	</div>

	<div class="footer">
		<div class="footer-left">Designed by <a href="https://www.makuzaku.com">Makuzaku Indonesia</a> | back to <a href="#">tutorial</a></div>
		<div class="footer-right">Image By <a href="http://www.flickr.com/photos/daniele_parisi/2825831148/sizes/o/in/photostream/">Daniele Parisi</a></div>
	</div>

</div>

Code CSS

*{padding:0;margin:0}
html{
	background: url(img/bromo.jpg) no-repeat center center fixed;
	  -webkit-background-size: cover;
	  -moz-background-size: cover;
	  -o-background-size: cover;
	  background-size: cover;
	font-family: 'Open Sans', sans-serif;
	font-size:13px;
	text-shadow: 0px 1px 2px #000;
}
a{color:#999;text-decoration:none}
a:hover{border-bottom:1px solid #999}
.header{
	padding:8% 2%;
	font-size:24px;
	text-shadow: 0px 1px 0px #333;
}
	h1.brand{
		font-size:50px;
		font-family: 'Oleo Script', cursive;
		text-shadow: 0px 2px 3px #f4f4f4;
	}
	.header span.red{color:#f20000;}
	.header span.white{color:#fff;}

.content{padding:2%;color:#f4f4f4;}
.content p{margin:10px 0}
.footer{
	padding:5% 2%;
	width:95%;
	position:absolute;
	overflow:hidden;
	color:#f4f4f4;
}
	.footer-left{
		position:relative;
		width:45%;
		float:left;
	}
	.footer-right{
		text-align:right;
		position:relative;
		width:45%;
		float:right;
	}

Demo Download

Sekian tutorial kali ini, silahkan tuliskan dikomentar jika ada masukan atau pertanyaan.

Jangan lupa Bagikan pos ini bila bermanfaat, Terima kasih.

Pos Terkait :

Like
Like Love Haha Wow Sad Angry

2 thoughts on “Membuat Website Dengan Background Full

  1. A lot of thanks for all of the efforts on this site. My aunt enjoys managing research and it’s really obvious why. Most people hear all about the lively mode you present functional steps by means of this website and as well foster participation from visitors about this concept while our favorite girl has always been studying a lot. Enjoy the remaining portion of the year. You are always doing a dazzling job.

  2. Thank you so much for giving everyone a very superb opportunity to check tips from this site. It is always very kind and also packed with amusement for me and my office acquaintances to visit your site particularly three times in a week to read the new guides you will have. And indeed, I’m so actually astounded with your striking creative concepts served by you. Selected 2 tips on this page are without a doubt the very best we have ever had.

Tinggalkan Balasan

Alamat email Anda tidak akan dipublikasikan. Ruas yang wajib ditandai *