電子書籍の厳選無料作品が豊富!

作成しているサイトでIEでマウスホイールが動かなくて困っています。overflow:auto; とposition:relative;によるIEのバグは調べていてわかったのですが、私の知識では併用しないとサイト上、レイアウトが成り立たないため、方法を探しています。
また、画像やテキストの上でホイールを回転させるとスクロールします。
どなたか良い方法はご存じないでしょうか。
以下がその作成しているページです。
http://i.gmobb.jp/jp-struttin/index/exhibition.htm
よろしくお願い致します。

A 回答 (6件)

 補足ですが、ウィンドウ巾は640pxあたりから上のサイズなら横スクロールなしで問題なく閲覧できるはずです。

スマホや横幅1900pのディスプレイでも使える。横幅が1200を越えると中央に表示される。横に並ぶ数が変わります。

 古いIEはfixedに対応していないため、fixed.jsを拾ってきてください。

 印刷や他の端末を考慮するなら、mediaをscreenに限定してください。fixedでは各ページに印刷されます。

 HTMLには文書構造しか書かれていないので、スタイルシートだけを書き換えることで好きなデザインに変更できます。見出しだけ表示させておいて、マウスオーバーで画像や説明を表示させるとか、スライドショー形式にするとか、何でもできます。代替スタイルシートでユーザーに選択してもらっても良いでしょう。

 まあ、HTMLもスタイルシートも簡単で解りやすいのでここから先はご自身で挑戦してください。
    • good
    • 1
この回答へのお礼

長文どうもありがとうございます。
大変うれしいです。
実際に検証してみましたが、解決に至りませんでした。
ヘッダーごとスクロールするパターンに妥協しました。
ご回答ありがとうございました。

お礼日時:2012/09/27 12:50

スタイルシートのみです。


たったこれだけです。
html,body{margin:0;padding:0;}
body{
_background:url(http://i.gmobb.jp/jp-struttin/img/bg.jpg) no-repeat fixed;
_background-size:cover;
}
div.header{
_position:fixed;top:0;left:0;
_width:100%;
}
div.header div.section{
_width:100%;height:150px;
_max-width:1200px;min-width:640px;margin:0 auto;
_border-bottom:gray 1px solid;
_background:url(http://i.gmobb.jp/jp-struttin/img/bg.jpg) no-repeat fixed;
_background-size:cover;
_z-index:10;
}
div.header div.nav ul{text-align:right;}
div.header h1{position:absolute;left:10px;top:20px;}
div.header div.nav{
_width:100%;position:absolute;
_bottom:0;right:10px;
}
div.header div.nav ul,
div.header div.nav ul li{list-style:none;margin:0;padding:0;}
div.header div.nav ul{display:block;width:100%;}
div.header div.nav ul li{
_display:inline;margin-right:2em;margin-top:20px;
}
div.section,div.footer{
_width:100%;height:150px;
_max-width:1200px;min-width:640px;margin:0 auto;
}
div.section{margin-top:150px;position:relative;}
div.section h2{font-size:0.8em;}
div.section div.section{margin-top:0;}
div.section ol li a{text-decoration:none;color:black;}
div.section ol li a:hover{text-decoration:underline;}
div.section ol li ol{margin:0;}
div.section h2+ol{border-top:1px gray solid;}
div.section ol,div.section ol li{display:block;list-style:none;margin:0;padding:0;}
div.section ol,div.section h2,div.footer{clear:left;}
div.section ol,div.section h2{margin:0 5%;}
div.section ol li ol li h2{margin:0;}
div.section ol li{
_width:200px;height:350px;float:left;
_margin:10px;position:relative;
_font-size:0.7em;font-weight:bold;
}
div.section ol li h3{font-size:100%;margin:0;}
div.section ol li img{
_display:block;width:180px;
_box-shadow:5px 5px 5px rgba(0,0,0,0.4);
}
div.section ol li ol li{
_text-align:center;font-size:1.1em;float:none;
_display:block;height:auto;font-weight:normal;
}
div.section ol li ol li+li{text-align:right;}
div.section ol li.ended:after{
_content:url(http://i.gmobb.jp/jp-struttin/img/exhibition/ex_ …
}
    • good
    • 0

___<li class="ended">2011 12/3 sat-11 sun


____<h3>Birne X'mas market</h3>
____<ol>
_____<li><img src="/jp-struttin/img/exhibition/ex_008.jpg" width="133" height="200" alt="Birne X'mas market"></li>
_____<li><a href="http://birnebirne.com/index.html" title="Birne">Birne</a></li>
____</ol>
___<li class="ended">2011 11/27 sun
____<h3>のふりま3</h3>
____<ol>
_____<li><img src="/jp-struttin/img/exhibition/ex_noimage.jpg" width="200" height="140" alt="のふりま3"></li>
_____<li><a href="http://www.nofu.jp/" title="cafe nofu">cafe nofu</a></li>
____</ol>
___</li>
___<li class="ended">2011 11/5sat 6sun
____<h3><a href="http://minnanoich.exblog.jp/" title="みんなの市">みんなの市</a></h3>
____<ol>
_____<li><a href="http://minnanoich.exblog.jp/" title="みんなの市"><img src="/jp-struttin/img/exhibition/ex_007.jpg" width="209" height="141" alt="みんなの市"></a></li>
_____<li><a href="http://www.cafegalleryconversion.com/" title="cafe gallery CONVERSION">cafe gallery CONVERSION</a></li>
____</ol>
___</li>
__</ol>
__<ol>
___<li class="ended">2011 10/22sat
____<h3><a href="http://k-kurafuto.com/" title="川口暮らふと">川口暮らふと</a></h3>
____<ol>
_____<li><a href="http://k-kurafuto.com/" title="川口暮らふと"><img src="/jp-struttin/img/exhibition/ex_006.jpg" width="209" height="188" alt="川口暮らふと"></a></li>
____</ol>
___</li>
___<li class="ended">2011 10/8 sut - 9 sun
____<h3><a href="http://www.shizuoka-tezukuriichi.com/" title="ART&amp;CRAFT静岡">ART&amp;CRAFT静岡</a></h3>
____<ol>
_____<li><a href="http://www.shizuoka-tezukuriichi.com/" title="ART&amp;CRAFT静岡"><img src="/jp-struttin/img/exhibition/ex_005.jpg" width="209" height="149" alt="ART&amp;CRAFT静岡"></a></li>
_____<li>静岡縣護國神社</li>
____</ol>
___</li>
___<li class="ended">2011 9/24 sat - 25 sun
____<h3><a href="http://creatorsfestival.ikidane.com/" title="クリエイターズフェスタ">クリエイターズフェスタ</a></h3>
____<ol>
_____<li><a href="http://creatorsfestival.ikidane.com/" title="クリエイターズフェスタ"><img src="/jp-struttin/img/exhibition/ex_noimage.jpg" width="200" height="140" alt="クリエイターズフェスタ"></a></li>
____</ol>
___</li>
___<li class="ended">2011 9/19 mon
____<h3>まめなり市</h3>
____<ol>
_____<li><img src="/jp-struttin/img/exhibition/ex_noimage.jpg" width="200" height="140" alt="まめなり市"></li>
_____<li><a href="http://curry-okra.jugem.jp/" title="carry&amp;cafe Okra">carry&amp;cafe Okra</a></li>
____</ol>
___</li>
__</ol>
__<ol>
___<li class="ended">2011 3/9wed-13sun
____<h3>個展 前田美絵 陶展-若草色と夢想-</h3>
____<ol>
_____<li><img src="/jp-struttin/img/exhibition/ex_003.jpg" width="179" height="259" alt="個展 前田美絵 陶展 - 若草色と夢想 -" id="tate"></li>
_____<li><a href="http://fall-gallery.com/" title="FALL shop&amp;gallery">FALL shop&amp;gallery</a><br>東京都杉並区西荻北3-18-10-102</li>
____</ol>
___</li>
__</ol>
_</div>
_<div class="section">
__<h2>2010</h2>
__<ol>
___<li class="ended">2010 7/28wed-8/9mon
____<h3>個展 前田美絵 陶展 -うみをおもふ-</h3>
____<ol>
_____<li><img src="/jp-struttin/img/exhibition/ex_002.jpg" width="269" height="182" alt="個展 前田美絵 陶展 -うみをおもふ-"></li>
_____<li>国立本店 国立市中1-7-62</li>
____</ol>
___</li>
___<li class="ended">2010 4/16fri-20tue
____<h3>個展 前田美絵陶展</h3>
____<ol>
_____<li><img src="/jp-struttin/img/exhibition/ex_001.jpg" width="269" height="181" alt="個展 前田美絵陶展"></li>
_____<li>GALLERY it's<br>東京都渋谷区猿楽町2-7</li>
____</ol>
___</li>
__</ol>
_</div>
_<div class="footer">
__<h2>文書情報</h2>
__<dl class="documentHistry">
___<dt id="FIRST-PUBLISHED">First Published</dt>
___<dd>2012-08-10</dd>
__</dl>
__<address>&copy; 2012 - 2016 All Rights Reserved mailto:*****</address>
_</div>
</body>
</html>
    • good
    • 0

あまりにもなので、HTMLの修正に少しばかり苦労しました。

後半とスタイルシートは次回に回します。
★Another HTML-lint 5 ( http://www.htmllint.net/ )
で検証済みのHTML4.01strictです。(コメント部分は引っかかるけど)
★タブは_に、http:はhttp:に置換してあります。戻すこと

HTMLが簡単なので、簡単に追加できるでしょう。

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html lang="ja">
<head>
_<meta http-equiv="content-type" content="text/html; charset=Shift_JIS">
_<title>タイトル</title>
_<meta name="author" content="ORUKA1951">
_<meta http-equiv="Content-Style-Type" content="text/css">
_<link rev="made" href="mailto:oruka1951@hoge.com" title="send a mail" >
_<link rel="START" href="../index.html">
_<style type="text/css">
<!--
-->
_</style>
</head>
<body>
_<div class="header">
__<div class="section">
___<h1><a href="/"><img src="/jp-struttin/img/logo.png" alt="[タイトル]" width="278" height="40"></a></h1>
___<div class="nav">
____<ul>
_____<li><a href="/profile"><img src="/jp-struttin/img/profile.gif" width="13" height="29" alt="作家"></a></li>
_____<li><a href="/works"><img src="/jp-struttin/img/works.gif" width="12" height="44" alt="器"></a></li>
_____<li><a href="/ex"><img src="/jp-struttin/img/exhibition.gif" width="12" height="28" alt="展示"></a></li>
_____<li><a href="/blog"><img src="/jp-struttin/img/blog.gif" width="9" height="25" alt="日々"></a></li>
_____<li><a href="/contact"><img src="/jp-struttin/img/contact.gif" width="13" height="76" alt="問いあわせ"></a></li>
____</ul>
___</div>
__</div>
_</div>
_<div class="section">
__<h2>2012</h2>
__<ol><!-- olはfloatを解除する -->
<!--
___<li>日時(終了したらclass名をended)
____<h3><a href="[URL]" title="[title]">雑司が谷手創り市</a></h3>
____<ol>
_____<li><a href="[URL]" title="[title]"><img src="/jp-struttin/img/[ファイル名]" width="[size]" height="[size]" alt="[代替テキスト]"></a></li>
____</ol>
___</li>
-->
___<li>2011 12/18 sun
____<h3><a href="http://www.tezukuriichi.com/home.html" title="雑司が谷手創り市">雑司が谷手創り市</a></h3>
____<ol>
_____<li><a href="http://www.tezukuriichi.com/home.html" title="雑司が谷手創り市"><img src="/jp-struttin/img/exhibition/ex_009.jpg" width="149" height="160" alt="雑司が谷手創り市"></a></li>
____</ol>
___</li>
___<li class="ended">2011 12/3sat-11 sun
____<h3>Birne X'mas market</h3>
____<ol>
_____<li><img src="/jp-struttin/img/exhibition/ex_008.jpg" width="133" height="200" alt="Birne X'mas market"></li>
_____<li><a href="http://birnebirne.com/index.html" title="Birne">Birne</a></li>
____</ol>
___</li>
___<li class="ended">2012 10/13sat-14 sun
____<h3><a href="http://www.shizuoka-tezukuriichi.com/" title="ART&amp;CRAFT SHIZUOKA">ART&amp;CRAFT SHIZUOKA</a></h3>
____<ol>
_____<li><a href="http://www.shizuoka-tezukuriichi.com/" title="ART&amp;CRAFT SHIZUOKA"><img src="/jp-struttin/img/exhibition/ex_020.jpg" width="208" height="145" alt="ART&amp;CRAFT SHIZUOKA" ></a></li>
_____<li>静岡縣護國神社</li>
____</ol>
___</li>
___<li class="ended">2012 9/19 wed - 26 wed
____<h3><a href="http://www.padodo.co.jp/" title="pas de deux">そざいで遊ぶブローチ展</a></h3>
____<ol>
_____<li><a href="http://www.padodo.co.jp/" title="pas de deux"><img src="/jp-struttin/img/exhibition/ex_019.jpg" width="209" height="140" alt="そざいで遊ぶブローチ展"></a></li>
_____<li><a href="http://www.padodo.co.jp/" title="pas de deux">pas de deux</a></li>
____</ol>
___</li>
__</ol>
_</div>
_<div class="section">
__<h2>2011</h2>
__<ol>
___<li class="ended">2011 12/18 sun
____<h3><a href="http://www.tezukuriichi.com/home.html" title="雑司が谷手創り市">雑司が谷手創り市</a></h3>
____<ol>
_____<li><a href="http://www.tezukuriichi.com/home.html" title="雑司が谷手創り市"><img src="/jp-struttin/img/exhibition/ex_009.jpg" width="149" height="160" alt="雑司が谷手創り市"></a></li>
_____<li>大鳥神社</li>
____</ol>
___</li>
    • good
    • 0

まず重大なエラーは修正しておきましょう。


★Another HTML-lint 5 ( http://www.htmllint.net/html-lint/htmllint.html )
また、divの使い方が根本的に間違っています。
【引用】____________ここから
注。 CSSではclass属性が非常に大きな力を持っている。 したがって文書作成者は、体裁に殆ど何の関係も無い要素(HTMLだとDIV要素やSPAN要素など)をベースにして、それらにclass属性でスタイル情報を与えれば、独自の構造化言語を設計できると考えられる。 しかし、文書の構造要素は広く受け入れられている一般的意味を持つ場合が多いので、こういった使用法は避けるべきである。 文書作成者が定めたクラス名では、意味を理解してもらえない場合もある。
 ̄ ̄ ̄ ̄ ̄ ̄ ̄ ̄ ̄ ̄ ̄ ̄ ̄ここまで[セレクタ( http://www.swlab.it.okayama-u.ac.jp/man/rec-css2 … )]より

<body>
 <div class="header">
  文書のヘッダー
 </div>
 <div class="section">
  本文
  <div class="section" id="Y2012">
   <h2>2012</h2>
   <ol>
    <li>商品名
     <ol>
      <li>画像</li>
      <li>説明</li>
     </ol>
    </li>
   </ol>
  </section>
  <div class="section" id="Y2011">
   <h2>2012</h2>
   <ol>
    <li>商品名
     <ol>
      <li>画像</li>
      <li>説明</li>
     </ol>
    </li>
   </ol>
のように、既存のHTML要素にその文書構造を示す最適なものがあれば、それを使ってマークアップしましょう。
 Lynxなどのテキストブラウザ、あるいは画像を読み込まずとスタイルシートを解除した状態でページを見ると、なぜダメなのかがすぐわかるでしょう。
『Lynx などのテキスト ブラウザを使用して、サイトを確認します(ほとんどの検索エンジンのスパイダーには Lynx で見えるようにサイトが映ります)。 ( http://support.google.com/webmasters/bin/answer. … )』

 その上で、
div.header,div.section,div,footer{
width:100%;min-width:780px;max-width:1000px;
margin:0 auto;
}
div.section div.section{min-width:0;}
div.header{
position:fixed; height:150px;}
div.section{paddind-top:150px;}
div.section div.section{paddin-top:0;}
div.section div.section ol,
div.section div.section ol li{
display:block;list-style-type:none;
margin:0;padding:0;
}
div.section div.section ol li{
width:200px;height:300px;float:left;
}
div.section div.section ol li{float:none;}
div.section div.section{clear:left;}

だけで希望の動作になるはずです。
HTMLも今の半分、スタイルシートは一桁小さくなり、わかりやすくなるでしょう。
そして、スマートフォンのような小さなディスプレイでも、1900px幅の広いディスプレイでも閲覧できるでしょう。
    • good
    • 0

1.絶対配置したものの上に絶対配置で記事などを載せて


その記事をスクロールさせるようにすれば、IEではスクロールが
リンク部分のカーソルを乗せてスクロールしないと
スクロールできないことが起きます。

2.質問者の方のページはそれとはまったく関係ありません。

3.下記のスクリプト(プラグイン?)にスクリプトエラーがあります。
(IEでスクリプトエラーが発生しています)
下記を外せば、ちゃんとスクロールできると思います(</head>の前の部分)
一時的に外して確認してみてください。

<script src="http://i.gmobb.jp/jp-struttin/js/jquery.shadow.j …
<script type="text/javascript">
$(function(){
jQuery('img.bgmaximage').maxImage({
isBackground: true,
overflow: 'auto'
});
});
</script>
<script type="text/javascript">
$(document).ready(function() {
$('.shadow').shadow('raised');
});
</script>
    • good
    • 0
この回答へのお礼

どうもありがとうございます。
遅くなりました。
いずれも実行してみましたが、うまくいきませんでした。。
ご回答感謝いたします。

お礼日時:2012/09/27 12:48

お探しのQ&Aが見つからない時は、教えて!gooで質問しましょう!