For my japanes learning site i am building a kana-helper: Every time when the cursor hovers over a kana (basic japanese characters) in the text, the belonging romaji should be shown in a fixed div.
I am a very beginner in css and html etc. and with the help of this community a was able to get the job half done.
Here is my code so far (reduced to the absolutely necessary):
span.ko:hover + #kanahelfer-ko {display: block;}
#kanahelfer-ko {
position: fixed;
display: none;
top: 100px;
left: 100px;
}
<span class="ko">こ</span>
<div id="kanahelfer-ko">ko</div>
So far it does what it is supposed to do. The problem is, that i need many of these divs (a little more than 200, one for each kana). But ist does not even work with two:
span.ko:hover + #kanahelfer-ko {display: block;}
span.re:hover + #kanahelfer-re {display: block;}
#kanahelfer-ko {
position: fixed;
display: none;
top: 100px;
left: 100px;
}
#kanahelfer-re {
position: fixed;
display: none;
top: 100px;
left: 100px;
}
<span class="ko">こ</span><span class="re">れ</span>
<div id="kanahelfer-ko">ko</div>
<div id="kanahelfer-re">re</div>
I hope anybody can help me.
P.S.: Sorry for my poor english.