HTML'li çerçeve - nasıl çalışır
Web sitenizdeki medyayı daha çekici hale getirmek için, çevresine bir çerçeve çizmek için HTML kodunu kullanabilirsiniz. Bu pratik ipucunda, bunun nasıl çalıştığını ve bir çerçeve tanımlarken basamaklı stil sayfalarının (CSS) sunduğu avantajları göstereceğiz.
HTML kodlaması - resimlerin ve diğer ortamların çevresine çerçeveler çizme
Varsayılan olarak, her görüntünün bir piksel genişliğinde bir çerçevesi vardır. Ancak, bu yalnızca görüntü köprü olarak kullanılıyorsa görülebilir. "Border" özelliği ile çerçevenin kalınlığını ayrı ayrı tanımlayabilirsiniz.
- HTML'de, on piksellik siyah bir çerçevenin kodu şuna benzer:
- Bu çerçeve, nesnenin dört tarafına da uygulanır.
- Alternatif olarak, çerçeveyi görüntünüzün çevresine çizmek için Gimp gibi bir görüntü düzenleme programı kullanabilirsiniz.
- Ancak, bunun görüntüyü büyüteceğini ve web sitenize gelen ziyaretçinin görüntüyü indirmesinin daha uzun süreceğini lütfen unutmayın.
HTML belgesindeki çerçeveyi CSS ile tanımlayın
Çerçeveyi - örneğin bir metnin etrafındaki kutuyu - basamaklı stil sayfaları ile daha da net bir şekilde tanımlayabilirsiniz.
- Başka bir pratik ipucu, bir CSS dosyasını web sitenize nasıl entegre edeceğinizi anlatır.
- Bu CSS belgesinde, çerçevenin rengini ve kalınlığını dört sayfanın tümü için farklı şekilde ayarlayabilirsiniz:
- border-bottom: # 999 - Alt çerçevenin rengini ayarlar. Burada ayrıca "border-top", "border-right" veya "border-left" kullanabilirsiniz.
- kenarlık genişliği: 0 0 ince ince - Çizgi kalınlığını belirtir. Bu saat yönünde yapılır. Burada, üstte ve sağda hiçbir çizgi görülmezken, altta ve solda ince bir çizgi tanımlanmış demektir.
- kenarlık stili: yok hiçbiri oluk oluğu - Resminiz veya kutunuz için dekoratif çerçeveyi tanımlar. "Oluk" tarzı bir 3D efekti yaratır.
Ana sayfanız doğal olarak ağdaki varlığından yaşıyor. Bir sonraki makalede, Google sıralamanızı yükseltmek için en iyi ipuçlarını okuyacaksınız.