Zdravím,
chci ze zeptat jak docílit bublinové nápovědy. Řešim to přez css ale v opeře mi to dělá problémy.
Mám css:
a.tooltip {
position: relative;
}
a.tooltip span {
display: none;
}
a.tooltip:hover {
font-size: 100%; /* Fixes bug in IE5.x/Win */
}
a.tooltip:hover span {
display:block;
position:absolute;
top:1em;
left:2em;
padding: 0.2em 0.6em;
border:1px solid #999999;
background-color:#FFEDC4;
color:#000;
}
<p><a href="nekam.php" class="tooltip">Nekam odkaz<span>uifgudifh iuhsd auisdhfaiusdfh aiudsfha sidufhai sdfhasdif haisdfhafuasd fuiahsdf uihdsfui</span></a></p>
V IE to jede v pohode ale v opere se to spatne pozicuje a kdyz odjedu z objektu tak tom zustavaji casti napovedy. Potrebuji neco jako ma tento vek kdyz se najede na nejakou ikonku diskuze. :smile1:
Fórum › CSS
Bublinová nápověda

Ten předchozí kód selhal v IE >> zobrazoval bublinu průhlednou.
Tak jsem trochu máknul => výsledkem je bublinovka pro řádkové (i blokové) odkazy.
Zobrazuje se bez kazů, a to i na spodním okraji v Opeře (což byl velký problém).
Prověřeno v Opeře,FF,IE6/7.
[jediný FF se nedá přimět, aby zobrazil bublinu zarovnaně pod odkaz, nýbrž vedle odkazu]
Petroff: Díky za ten scipt.. dlouho jsem strávil na jeho testování než jsem to dal na web.. Teď jsem zjistil, že to není validní s IE 6.. :( Jiné prohlížeče kromě Firefoxu jsem nezkoušel.. Použil jsem ten 2. scipt.. Nevíš, co s tim mám prosím tě dělat? :(
Myslíš asi tu skutečnost, že pseudoelement :root je pro IE neznámý <=> neplatný . . .
Právě proto, že ho FF jako jediný interpretuje (jako kořenový prvek), mohu pro FF nastavit odlišné hodnoty aby zobrazoval správně. Vynechat se nedá - ostatním prohlížečům by ty odlišné hodnoty rozbily vzhled.
Ale napadly mě 2 způsoby, jak ho skrýt před IE:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="cs">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>tooltip</title>
<style type="text/css">
. . . . .
</style>
<!--[if !IE]> -->
<style type="text/css">
:root a.tooltip span {
top: auto;
left: 5px;
}
</style>
<!-- <![endif]-->
. . . . .
(tohle mi háže validator v IE bez chyb)

Přidej příspěvek
Ano, opravdu chci reagovat → zobrazí formulář pro přidání příspěvku
×Vložení zdrojáku
×Vložení obrázku
×Vložení videa
































Uživatelé prohlížející si toto vlákno
Podobná vlákna
Bublinova napoveda — založil vyhno
"Skrytá nápověda" — založil Kalgys
Nápověda pro začatečníka (zelenáče) — založil Dobyvatel
Moderátoři diskuze