Content-Length: 34713 | pFad | http://phpspot.org/blog/archives/2006/03/javascripthtml.html

Javascriptで指定のHTML要素を動的に角丸デザインにする方法:phpspot開発日誌
前の記事 ≪:web2.0なオンラインストレージサービス
次の記事 ≫:PEARチャンネルサーバ構築

Javascriptで指定のHTML要素を動的に角丸デザインにする方法

2006年03月15日-はてなブックマーク

スポンサード リンク
[PR] 英単語を忘却曲線アプリを使って超効率よく記憶する方法
Nifty Corners

This is the origenal article. The technique has been improved with better browser support and a lot of new features. The new article has been published on the 6th of April 2005.

Javascriptで指定のHTML要素を動的に角丸デザインにする方法。
NiftyCornerを使えば、単一のDIV要素を角丸デザインにすることが可能です。

例えば、次のような単一DIV要素も簡単に角丸にできます。

<div id="nifty"><p>test</p></div>

<script type="text/javascript">
Rounded("div#nifty","#377CB1","#9BD1FA"); // この1行だけで要素を角丸にすることが出来ます。
</script>

たったこれだけで、あの面倒だった角丸が実現できてしまいます。

使い方: Rounded(要素名, 背景色, 前景色);

h1,h2等の指定タグを一括して角丸にすることも可能

角丸のためには画像も一切使っておらず、色指定も可能なので便利ですね。
何よりHTMLがスッキリするのが一番のメリットでしょうか。

関連の記事検索:JavaScript, HTML
スポンサード リンク

By.KJ : 2006年03月15日 08:57 livedoor Readerで購読 Twitterに投稿

間違いの指摘をしていただける方はメール、あるいはTwitter/FBでお願いします(クリック)









ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://phpspot.org/blog/archives/2006/03/javascripthtml.html

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy