<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
		xmlns:xhtml="http://www.w3.org/1999/xhtml"
>

<channel>
	<title>イテルの一日一問 &#187; css＋xhtmlなど</title>
	<atom:link href="http://oneday.ter.jp/category/css-xhtml/feed" rel="self" type="application/rss+xml" />
	<link>http://oneday.ter.jp</link>
	<description>一日にひとつは何かを考える。</description>
	<lastBuildDate>Mon, 31 Jan 2011 09:23:33 +0000</lastBuildDate>
	<language>ja</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1</generator>
<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://oneday.ter.jp/category/css-xhtml/feed" />
		<item>
		<title>CSSで画像の一部だけを表示する</title>
		<link>http://oneday.ter.jp/css-xhtml/760.html</link>
		<comments>http://oneday.ter.jp/css-xhtml/760.html#comments</comments>
		<pubDate>Tue, 25 Aug 2009 23:01:12 +0000</pubDate>
		<dc:creator>イテル</dc:creator>
				<category><![CDATA[css＋xhtmlなど]]></category>

		<guid isPermaLink="false">http://oneday.ter.jp/?p=760</guid>
		<description><![CDATA[サムネイルを表示する際にCSSで画像の一部だけを表示させる方法。 CSSのclipプロパティを使うと。 このclipプロパティは指定した画像の一部を表示することができる。]]></description>
			<content:encoded><![CDATA[<p><img class="alignnone size-thumbnail wp-image-773" title="0908211" src="http://oneday.ter.jp/wp-content/uploads/2009/08/09082112-700x200.jpg" alt="0908211" width="700" height="200" /></p>
<p>サムネイルを表示する際にCSSで画像の一部だけを表示させる方法。</p>
<p>CSSのclipプロパティを使うと。<br />
このclipプロパティは指定した画像の一部を表示することができる。</p>
<pre class="brush: css; title: ; notranslate">
clip : rect(auto 100px 100px auto) ;
</pre>
]]></content:encoded>
			<wfw:commentRss>http://oneday.ter.jp/css-xhtml/760.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://oneday.ter.jp/css-xhtml/760.html" />
	</item>
		<item>
		<title>マウスオーバー時に透明度を変更する（css）</title>
		<link>http://oneday.ter.jp/css-xhtml/747.html</link>
		<comments>http://oneday.ter.jp/css-xhtml/747.html#comments</comments>
		<pubDate>Sat, 22 Aug 2009 11:48:21 +0000</pubDate>
		<dc:creator>イテル</dc:creator>
				<category><![CDATA[css＋xhtmlなど]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[フィルター]]></category>
		<category><![CDATA[透明度]]></category>

		<guid isPermaLink="false">http://oneday.ter.jp/?p=747</guid>
		<description><![CDATA[これまた、時間がないときに覚えておきたい方法。 とIE8対策っぽいのも書きましたが、なぜかうまく認識せず。 もうちょい調査が必要なようです。]]></description>
			<content:encoded><![CDATA[<p><img src="http://oneday.ter.jp/wp-content/uploads/2009/08/0908211-700x200.jpg" alt="090821" title="090821" width="700" height="200" class="alignnone size-thumbnail wp-image-750" /></p>
<p>これまた、時間がないときに覚えておきたい方法。</p>
<pre class="brush: css; title: ; notranslate">
#hoge a:hover{
	border:5px solid #996600;/* border */
	opacity:0.8;
	filter:alpha(opacity=80);/*ie6 7*/
	zoom:1.0;/*ie6 7*/
	-ms-filter:&quot;alpha(opacity=80)&quot;;/*ie8*/
	}
</pre>
<p>とIE8対策っぽいのも書きましたが、なぜかうまく認識せず。<br />
もうちょい調査が必要なようです。</p>
]]></content:encoded>
			<wfw:commentRss>http://oneday.ter.jp/css-xhtml/747.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://oneday.ter.jp/css-xhtml/747.html" />
	</item>
		<item>
		<title>マウスオーバーで画像にラインをつけるcss</title>
		<link>http://oneday.ter.jp/css-xhtml/737.html</link>
		<comments>http://oneday.ter.jp/css-xhtml/737.html#comments</comments>
		<pubDate>Fri, 21 Aug 2009 10:30:47 +0000</pubDate>
		<dc:creator>イテル</dc:creator>
				<category><![CDATA[css＋xhtmlなど]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[ホバー]]></category>
		<category><![CDATA[マウスオーバー]]></category>
		<category><![CDATA[画像にライン]]></category>

		<guid isPermaLink="false">http://oneday.ter.jp/?p=737</guid>
		<description><![CDATA[時間がない、面倒くさい場合に使いたい、CSSで マウスオーバーした時に画像のフチにラインをつける方法。 これだけ。 floatなどを使用するので若干調整が必要な場合もある。]]></description>
			<content:encoded><![CDATA[<p><img class="alignnone size-thumbnail wp-image-739" title="090821" src="http://oneday.ter.jp/wp-content/uploads/2009/08/090821-700x200.jpg" alt="090821" width="700" height="200" /></p>
<p>時間がない、面倒くさい場合に使いたい、CSSで<br />
マウスオーバーした時に画像のフチにラインをつける方法。</p>
<pre class="brush: css; title: ; notranslate">
#fuchi-gazou a img,
#fuchi-gazou a{
    border: none;
    overflow: hidden;
    float: left;
}
#fuchi-gazou  a:hover{
    border: 5px solid #333333;
    }
#fuchi-gazou a:hover img{
    margin: -5px;
}
</pre>
<p>これだけ。<br />
floatなどを使用するので若干調整が必要な場合もある。</p>
]]></content:encoded>
			<wfw:commentRss>http://oneday.ter.jp/css-xhtml/737.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://oneday.ter.jp/css-xhtml/737.html" />
	</item>
		<item>
		<title>フッターをウィンドウの下に設置する（JS）</title>
		<link>http://oneday.ter.jp/css-xhtml/727.html</link>
		<comments>http://oneday.ter.jp/css-xhtml/727.html#comments</comments>
		<pubDate>Thu, 20 Aug 2009 10:11:16 +0000</pubDate>
		<dc:creator>イテル</dc:creator>
				<category><![CDATA[css＋xhtmlなど]]></category>
		<category><![CDATA[js]]></category>
		<category><![CDATA[フッター]]></category>
		<category><![CDATA[下]]></category>

		<guid isPermaLink="false">http://oneday.ter.jp/?p=727</guid>
		<description><![CDATA[JSでフッターを固定する方法。 ぶっちゃけjsを切ってる人って今はいないので、 これの方が簡単じゃないかと思ったりして。 「to-R」さんから「footerFixed.js」をダウンロードする。 head内に下記のjsを [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignnone size-thumbnail wp-image-731" title="090819" src="http://oneday.ter.jp/wp-content/uploads/2009/08/090819-700x200.jpg" alt="090819" width="700" height="200" /></p>
<p>JSでフッターを固定する方法。<br />
ぶっちゃけjsを切ってる人って今はいないので、<br />
これの方が簡単じゃないかと思ったりして。</p>
<p>「<a href="http://blog.webcreativepark.net/2007/11/16-012253.html" target="_blank">to-R</a>」さんから「footerFixed.js」をダウンロードする。</p>
<p>head内に下記のjsを読み込むコードを記述する。</p>
<pre class="brush: xml; title: ; notranslate">
&lt;script type=&quot;text/javascript&quot; src=&quot;./footerFixed.js&quot;&gt;&lt;/script&gt;
</pre>
<p>srcのパスは環境に合わせて書き換える。</p>
<p>あとはフッター要素のidを「footer」にすればok。<br />
やっぱりcssよりこっちの方がスマートだ。</p>
]]></content:encoded>
			<wfw:commentRss>http://oneday.ter.jp/css-xhtml/727.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://oneday.ter.jp/css-xhtml/727.html" />
	</item>
		<item>
		<title>設置したdivの背景をページ下まで伸ばす</title>
		<link>http://oneday.ter.jp/css-xhtml/722.html</link>
		<comments>http://oneday.ter.jp/css-xhtml/722.html#comments</comments>
		<pubDate>Wed, 19 Aug 2009 10:06:27 +0000</pubDate>
		<dc:creator>イテル</dc:creator>
				<category><![CDATA[css＋xhtmlなど]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[div]]></category>
		<category><![CDATA[ブラウザ]]></category>
		<category><![CDATA[下まで]]></category>

		<guid isPermaLink="false">http://oneday.ter.jp/?p=722</guid>
		<description><![CDATA[良く使うのだが、div要素をブラウザの下の方まで伸ばす方法。 毎度、忘れてしまうのでメモっておく。 htmlの例 cssの例 と、これだけ。]]></description>
			<content:encoded><![CDATA[<p><img class="alignnone size-thumbnail wp-image-735" title="090819" src="http://oneday.ter.jp/wp-content/uploads/2009/08/0908191-700x200.jpg" alt="090819" width="700" height="200" /></p>
<p>良く使うのだが、div要素をブラウザの下の方まで伸ばす方法。<br />
毎度、忘れてしまうのでメモっておく。</p>
<h3>htmlの例</h3>
<pre class="brush: xml; title: ; notranslate">
&lt;body&gt;
    &lt;div id=&quot;layout&quot;&gt;ブラウザの下まで伸ばしたいよ&lt;/div&gt;
&lt;/body&gt;
</pre>
<h3>cssの例</h3>
<pre class="brush: css; title: ; notranslate">
html{
    height:100%;
}
body{
    height:100%;
}
#layout{
    height:100%;
    min-height:100%;
    width:80%;
    background:Khaki;
    border-right:1px solid red;
}
body &gt; #layout{
    height:auto;
}
</pre>
<p>と、これだけ。</p>
]]></content:encoded>
			<wfw:commentRss>http://oneday.ter.jp/css-xhtml/722.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://oneday.ter.jp/css-xhtml/722.html" />
	</item>
		<item>
		<title>スクロールしても追従してくるメニュー（jQuery）</title>
		<link>http://oneday.ter.jp/css-xhtml/483.html</link>
		<comments>http://oneday.ter.jp/css-xhtml/483.html#comments</comments>
		<pubDate>Fri, 24 Jul 2009 14:15:06 +0000</pubDate>
		<dc:creator>イテル</dc:creator>
				<category><![CDATA[css＋xhtmlなど]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[webdesigning]]></category>
		<category><![CDATA[スクロール]]></category>
		<category><![CDATA[フローティング]]></category>
		<category><![CDATA[メニュー]]></category>
		<category><![CDATA[追従]]></category>

		<guid isPermaLink="false">http://oneday.ter.jp/?p=483</guid>
		<description><![CDATA[web designing（以降、webdes）の09年8月号より、自分でコピペできるようにメモ。 webdesではjQueryの特集が組んであり、これは私も将来使うのではないかと思う項目がたくさんあった。 ちなみに追従 [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://oneday.ter.jp/wp-content/uploads/2009/07/0907241-700x200.jpg" alt="090724" title="090724" width="700" height="200" class="alignnone size-thumbnail wp-image-508" /></p>
<p>web designing（以降、webdes）の09年8月号より、自分でコピペできるようにメモ。<br />
webdesではjQueryの特集が組んであり、これは私も将来使うのではないかと思う項目がたくさんあった。</p>
<p>ちなみに追従するメニューのことを、プロはフローティングメニューというらしい。<br />
さっそくwebdesのコードをさらしてみる。<br />
別途jQueryはダウンロードする必要があるのであしからず。</p>
<h3>ヘッダーにcssとjQueryを読み込む</h3>
<pre class="brush: xml; title: ; notranslate">
&lt;link rel=&quot;stylesheet&quot; href=&quot;css/main.css&quot; type=&quot;text/css&quot; media=&quot;all&quot;&gt;
&lt;script type=&quot;text/javascript&quot; src=&quot;js/jquery-1.3.2.min.js&quot;&gt;&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot; src=&quot;js/jquery.dimensions.js&quot;&gt;&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot; src=&quot;js/livefloatingmenu.js&quot;&gt;&lt;/script&gt;
</pre>
<h3>コンテンツとメニュー</h3>
<pre class="brush: xml; title: ; notranslate">
&lt;div id=&quot;contents&quot;&gt;
	&lt;h1&gt;フローティングメニュー&lt;/h1&gt;
	&lt;p&gt;ほげコンテンツ&lt;/p&gt;
&lt;/div&gt;
&lt;div id=&quot;menu&quot;&gt;
	&lt;h2&gt;メニュー&lt;/h2&gt;
	&lt;ul&gt;
		&lt;li&gt;&lt;a href=&quot;#&quot;&gt;メニュー1&lt;/a&gt;&lt;/li&gt;
		&lt;li&gt;&lt;a href=&quot;#&quot;&gt;メニュー2&lt;/a&gt;&lt;/li&gt;
		&lt;li&gt;&lt;a href=&quot;#&quot;&gt;メニュー3&lt;/a&gt;&lt;/li&gt;
		&lt;li&gt;&lt;a href=&quot;#&quot;&gt;メニュー4&lt;/a&gt;&lt;/li&gt;
		&lt;li&gt;&lt;a href=&quot;#&quot;&gt;メニュー5&lt;/a&gt;&lt;/li&gt;
	&lt;/ul&gt;
&lt;/div&gt;
</pre>
<h3>JS：livefloatingmenu.js</h3>
<pre class="brush: jscript; title: ; notranslate">
var name = &amp;amp;quot;#menu&amp;amp;quot;;
var menuYloc = null;
$(function(){
	menuYloc = parseInt($(name).css(&amp;amp;quot;top&amp;amp;quot;).substring(0,$(name).css(&amp;amp;quot;top&amp;amp;quot;).indexOf(&amp;amp;quot;px&amp;amp;quot;)));
	$(window).scroll(function () {
		offset = menuYloc+$(document).scrollTop()+&amp;amp;quot;px&amp;amp;quot;;
		$(name).animate({top:offset},{
			duration:350,
			queue: false
		});
	});
});
</pre>
<p>durationの数値を変えることで、追従するタイミングを変更できる。<br />
また、queueをtrueに変更すると良くわからん動きをする。</p>
<p>今回のサンプルは<a href="/html_data/0907/24/" target="_blank">コチラ</a>。</p>
<div class="amazon-item-box" style="display: block; padding: 0; border: 1px solid  #999; margin: 8px;  -moz-border-radius: 10px;">
<div class="amazon-item-image" style="display: block; padding: 10px; float: left;"><a href="http://www.amazon.co.jp/exec/obidos/ASIN/B002GCGJ1O/iterudiary-22/ref=nosim" target="_blank"><img src="http://ecx.images-amazon.com/images/I/512rkaSlQDL._SL160_.jpg" alt="Web Designing (ウェブデザイニング) 2009年 08月号 [雑誌]" title="Web Designing (ウェブデザイニング) 2009年 08月号 [雑誌]" style="border: none; display: inline; vertical-align: bottom;" /></a></div>
<dl class="amazon-item-info" style="display: block; margin-left: 10px; padding: 0 8px 0 10px; font-size: 10pt; line-height: 110%;">
<dt class="amazon-item-name" style="display: block; margin-bottom: 5px; line-height: 120%;"><a href="http://www.amazon.co.jp/exec/obidos/ASIN/B002GCGJ1O/iterudiary-22/ref=nosim" target="_blank" title="Web Designing (ウェブデザイニング) 2009年 08月号 [雑誌]">Web Designing (ウェブデザイニング) 2009年 08月号 [雑誌]</a></dt>
<dd>
<ul class="amazon-item-info-list" style="list-style-type: none; padding-left: 0px; line-height: 120%;">
<li>発売元: 毎日コミュニケーションズ</li>
<li>価格: ￥ 1,280</li>
<li>発売日: 2009/07/18</li>
</ul>
</dd>
</dl>
<p class="amazon-item-footer" style="clear: left; text-align: right; font-size: x-small; padding: 4px 10px 4px 10px; line-height: 100%; background-color: #f0f0f0;">posted with <a href="http://socialtunes.net">Socialtunes</a> at 2009/07/26</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://oneday.ter.jp/css-xhtml/483.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://oneday.ter.jp/css-xhtml/483.html" />
	</item>
		<item>
		<title>背景にFlashを置く</title>
		<link>http://oneday.ter.jp/flash/471.html</link>
		<comments>http://oneday.ter.jp/flash/471.html#comments</comments>
		<pubDate>Thu, 23 Jul 2009 04:36:35 +0000</pubDate>
		<dc:creator>イテル</dc:creator>
				<category><![CDATA[css＋xhtmlなど]]></category>
		<category><![CDATA[Flash]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[背景にFlash設置]]></category>

		<guid isPermaLink="false">http://oneday.ter.jp/?p=471</guid>
		<description><![CDATA[3日目の伊藤商店サイトを作った際のチップス。 FLASHを背景にしきたい場合、次のような感じにするといいみたい。 HTMLソース：Swfobjectを使用して配置 ※swfobjectについては過去の記事を参照してちょ。 [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://oneday.ter.jp/wp-content/uploads/2009/07/090724-700x200.jpg" alt="090724" title="090724" width="700" height="200" class="alignnone size-thumbnail wp-image-496" /></p>
<p>3日目の<a href="http://ito.ter.jp" target="_blank">伊藤商店</a>サイトを作った際のチップス。<br />
FLASHを背景にしきたい場合、次のような感じにするといいみたい。</p>
<h3>HTMLソース：Swfobjectを使用して配置</h3>
<pre class="brush: xml; title: ; notranslate">
&lt;div id=&quot;content&quot;&gt;
&lt;h1&gt;伊藤商店&lt;/h1&gt;
&lt;p&gt;伊藤商店はステキなwebクリエイターです&lt;/p&gt;
&lt;/div&gt;
&lt;div id=&quot;flash&quot;&gt;
&lt;div id=&quot;flashcontent&quot;&gt;
&lt;strong&gt;このサイトでは&lt;a href=&quot;http://www.adobe.com/jp/products/flashplayer/&quot; target=&quot;_blank&quot;&gt;Adobe Flash Player&lt;/a&gt;が必要です。&lt;/strong&gt;&lt;br /&gt;
Adobeのサイトより最新の&lt;a href=&quot;http://www.adobe.com/jp/products/flashplayer/&quot; target=&quot;_blank&quot;&gt;FlashPlayerをダウンロード&lt;/a&gt;してください。
&lt;/div&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
// &lt;![CDATA[
var so = new SWFObject(&quot;itoshoten.swf&quot;, &quot;sotester&quot;, &quot;100%&quot;, &quot;100%&quot;, &quot;10&quot;, &quot;#000000&quot;);
so.addVariable(&quot;flashVarText&quot;, &quot;this is passed in via FlashVars for example only&quot;);
so.addParam(&quot;wmode&quot;, &quot;transparent&quot;);
so.addParam(&quot;scale&quot;, &quot;noscale&quot;);
so.write(&quot;flashcontent&quot;);
// ]]&gt;
&lt;/script&gt;
&lt;/div&gt;
</pre>
<p>※swfobjectについては<a href="http://oneday.ter.jp/css-xhtml/265.html" target="_blank">過去の記事</a>を参照してちょ。</p>
<h3>CSSソース</h3>
<pre class="brush: css; title: ; notranslate">
#content {
	position: relative;
	z-index: 1;
}
#flash {
	position: absolute;
	z-index:0;
	top:0;
	left:0;
	width:100%;
	height:100%;
}
</pre>
<p>z-indexでレイヤーを指定して使う。<br />
古いブラウザによっては正常に見えない可能性もあるが、<br />
IE6より前のブラウザとかは、無視したいところ。。。</p>
]]></content:encoded>
			<wfw:commentRss>http://oneday.ter.jp/flash/471.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://oneday.ter.jp/flash/471.html" />
	</item>
		<item>
		<title>IE6で透過PNG画像を使用する</title>
		<link>http://oneday.ter.jp/css-xhtml/474.html</link>
		<comments>http://oneday.ter.jp/css-xhtml/474.html#comments</comments>
		<pubDate>Wed, 22 Jul 2009 04:37:33 +0000</pubDate>
		<dc:creator>イテル</dc:creator>
				<category><![CDATA[css＋xhtmlなど]]></category>
		<category><![CDATA[ie6]]></category>
		<category><![CDATA[PNG]]></category>
		<category><![CDATA[画像]]></category>
		<category><![CDATA[透過]]></category>

		<guid isPermaLink="false">http://oneday.ter.jp/?p=474</guid>
		<description><![CDATA[またまた伊藤商店で使用したcssのチップス。 今日は透過PNGの処理。 結構面倒だと思っていたため、今まで避けておりましたが ちょっとかっちょいいことしたいと思うと避けて通れないため この機会に学習してみることにした。  [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://oneday.ter.jp/wp-content/uploads/2009/07/0907221-700x200.jpg" alt="090722" title="090722" width="700" height="200" class="alignnone size-thumbnail wp-image-493" /></p>
<p>またまた<a href="http://ito.ter.jp" target="_blank">伊藤商店</a>で使用したcssのチップス。<br />
今日は透過PNGの処理。</p>
<p>結構面倒だと思っていたため、今まで避けておりましたが<br />
ちょっとかっちょいいことしたいと思うと避けて通れないため<br />
この機会に学習してみることにした。</p>
<p>safari、firefox、ie7以上では透過PNGはそのまま<br />
利用できるが、IE6はそのままでは使用できない。</p>
<p>今回は背景にPNGを指定してIE6以外のブラウザはそのまま表示させ、<br />
IE6はフィルターを通して画像を表示させるという技。</p>
<p>説明は、cssのみで。</p>
<h3>IE6以外のブラウザ</h3>
<pre class="brush: css; title: ; notranslate">
	#header h1 a {
	height:30px;
	width:130px;
	background-image:url(images/logo.png);
	background-position:left top;
	background-repeat:no-repeat;
	text-indent:-9999px;
	float:left;
	margin:0 30px 0 0;
	}
</pre>
<h3>IE6のみ読み込み</h3>
<pre class="brush: css; title: ; notranslate">
	/* IE6のみ */
	background:none;
	filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='/path/images/logo.png', sizingMethod=scale);
	/*ファイルはフルパスでした方がいいかも*/
	text-indent:inherit;
	cursor:hand;
</pre>
<p>ついでに、IE6だけ読み込ませる際のHTMLの処理</p>
<h3>HTML内でハックを使わずブラウザの分岐方法</h3>
<pre class="brush: xml; title: ; notranslate">
&lt;!--[if lt IE 7]&gt;
	&lt;link rel=&quot;stylesheet&quot; href=&quot;css/ie6.css&quot; type=&quot;text/css&quot; media=&quot;screen&quot;&gt;
&lt;![endif]--&gt;
</pre>
<p>※IE7未満のブラウザを対象（7含まず）。</p>
<p>ファイルのパスはフルパスで指定しないと表示できなかった。<br />
wordpressのテーマで使用したからかもしれんけど。</p>
<p>また、aタグに書いているのだが、カーソルがそのままだったので、<br />
handを指定した。</p>
<p>具体的に知りたい方は、webdesigningの7月号を参照してちょ。</p>
]]></content:encoded>
			<wfw:commentRss>http://oneday.ter.jp/css-xhtml/474.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://oneday.ter.jp/css-xhtml/474.html" />
	</item>
		<item>
		<title>cssで背景を固定配置にする</title>
		<link>http://oneday.ter.jp/css-xhtml/469.html</link>
		<comments>http://oneday.ter.jp/css-xhtml/469.html#comments</comments>
		<pubDate>Tue, 21 Jul 2009 04:35:55 +0000</pubDate>
		<dc:creator>イテル</dc:creator>
				<category><![CDATA[css＋xhtmlなど]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[fixed]]></category>
		<category><![CDATA[固定配置]]></category>

		<guid isPermaLink="false">http://oneday.ter.jp/?p=469</guid>
		<description><![CDATA[今日は伊藤商店のwebを作って必要だった、 cssでフッターを固定する場合のメモ。 HTMLソース CSSソース コンテンツの内容によっては、IE6などブラウザで、 精度がかなり落ちてしまうので微調整が必要。 他にもJS [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://oneday.ter.jp/wp-content/uploads/2009/07/090722-700x200.jpg" alt="090722" title="090722" width="700" height="200" class="alignnone size-thumbnail wp-image-488" /></p>
<p>今日は<a href="http://ito.ter.jp" target="_blank">伊藤商店</a>のwebを作って必要だった、<br />
cssでフッターを固定する場合のメモ。</p>
<h3>HTMLソース</h3>
<pre class="brush: xml; title: ; notranslate">
&lt;body&gt;
    &lt;div id=&quot;contents&quot;&gt;
        &lt;h1&gt;ほげ&lt;/h1&gt;
        &lt;p&gt;hogeのコンテンツだよ。&lt;/p&gt;
    &lt;/div&gt;

    &lt;div class=&quot;footer&quot;&gt;
        hoge-Footer contents
    &lt;/div&gt;
&lt;/body&gt;
</pre>
<h3>CSSソース</h3>
<pre class="brush: css; title: ; notranslate">
html, body {
    height: 100%;
}
#contents {
    min-height: 100%;
    height: auto !important;
    height: 100%; /* ie用に設定 */
    margin: 0 auto -100px;
    /* class=&amp;quot;footer&amp;quot;と同じ高さ(100px)の負の値を入力 */
}

.footer {
    height: 100px;
    /*適当に色でもつけてみる*/
    background-color:#666666;
}
</pre>
<p>コンテンツの内容によっては、IE6などブラウザで、<br />
精度がかなり落ちてしまうので微調整が必要。<br />
他にもJSなどでできるようなので、後で試してみようと思う。</p>
]]></content:encoded>
			<wfw:commentRss>http://oneday.ter.jp/css-xhtml/469.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://oneday.ter.jp/css-xhtml/469.html" />
	</item>
		<item>
		<title>プルダウンメニューがFlashに隠れるのを回避（wmode ＆ swfobject.jp）</title>
		<link>http://oneday.ter.jp/css-xhtml/265.html</link>
		<comments>http://oneday.ter.jp/css-xhtml/265.html#comments</comments>
		<pubDate>Wed, 01 Jul 2009 08:48:37 +0000</pubDate>
		<dc:creator>イテル</dc:creator>
				<category><![CDATA[css＋xhtmlなど]]></category>
		<category><![CDATA[Flash]]></category>
		<category><![CDATA[swfobject]]></category>
		<category><![CDATA[wmode]]></category>
		<category><![CDATA[隠れる]]></category>

		<guid isPermaLink="false">http://oneday.ter.jp/?p=265</guid>
		<description><![CDATA[初歩的なことを忘れていたのでメモ。 jsのプルダウンメニューがflashにかかってしまう場合、objectタグで何も指定しないとflashの後ろにプルダウンメニューが入り込んでしまう。 また、ドリ標準のflash埋め込み [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignnone size-thumbnail wp-image-271" title="0906701-w3c" src="http://oneday.ter.jp/wp-content/uploads/2009/07/0906701-w3c-700x200.jpg" alt="0906701-w3c" width="700" height="200" /></p>
<p>初歩的なことを忘れていたのでメモ。</p>
<p>jsのプルダウンメニューがflashにかかってしまう場合、objectタグで何も指定しないとflashの後ろにプルダウンメニューが入り込んでしまう。</p>
<p>また、ドリ標準のflash埋め込みは分かりにくいのでswfobjectを使用してみる。</p>
<pre class="brush: xml; title: ; notranslate">
&lt;script src=&quot;js/swfobject.js&quot; type=&quot;text/javascript&quot;&gt;&lt;/script&gt;
</pre>
<p>ヘッダー内に上記記述を入れる。</p>
<pre class="brush: xml; title: ; notranslate">
&lt;div id=&quot;flashcontent&quot;&gt;
	ここはswfobjectでは読み込まないっす。
	flash playerがないとき表示されます。
&lt;/div&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
	var so = new SWFObject(&quot;flashdata.swf&quot;, &quot;flas data&quot;, &quot;500&quot;, &quot;300&quot;, &quot;9&quot;, &quot;#ffffff&quot;);
	so.addParam(&quot;wmode&quot;, &quot;transparent&quot;);
	so.write(&quot;flashcontent&quot;);
&lt;/script&gt;
</pre>
<p><em>※tenteruさんのご指摘により「so.addParam」と「so.write」が逆になっておりましたので修正しました［2009/12/18］</em></p>
<p><cite></cite></p>
<p>と書けばok</p>
<pre class="brush: xml; title: ; notranslate">
so.addParam(&quot;wmode&quot;, &quot;transparent&quot;);
</pre>
<p>これが肝。<br />
プルダウンが上に表示される。</p>
<p>ちなみにswfobjectのパラメータは次の通り。</p>
<p>SWFObject(&#8220;flashdata.swf&#8221;, &#8220;flash movie&#8221;, &#8220;500&#8243;, &#8220;300&#8243;, &#8220;9&#8243;, &#8220;#ffffff&#8221;)</p>
<ul>
<li>flashdata.swf＝swfファイルのソース。</li>
<li>flash movie＝このムービーの名称。特に気にする必要はない。</li>
<li>500＝swfの幅。</li>
<li>300＝swfの高さ。</li>
<li>9＝flash playerの対応バージョン。</li>
<li>#ffffff＝背景色。</li>
</ul>
<p>とのこと。</p>
]]></content:encoded>
			<wfw:commentRss>http://oneday.ter.jp/css-xhtml/265.html/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://oneday.ter.jp/css-xhtml/265.html" />
	</item>
	</channel>
</rss>

<!-- Dynamic page generated in 0.369 seconds. -->
<!-- Cached page generated by WP-Super-Cache on 2012-02-09 14:32:01 -->

