Autor Zpráva
Zeliii
Profil *
Ahoj, chtel bych se zeptat, jestli jde do alertu (takovy ty vyskakovaci blbosti....) nejakym zpusobem nacpat tucny text. Popr. jak?

Díky za odpovědi.
peta
Profil *
bold text alert javascript
http://www.google.com/search?q=bold+text+alert+javascript&start=0&ie=u tf-8&oe=utf-8&client=firefox-a&rls=org.mozilla:cs-CZ:official

Obavam se, ze nic nenajdes a nezbyva nez si napsat vlastni okenko alert, asi pres window.open nebo style.display=block
Pak si tam muzes pridat ruzne ornamenty, vcetne animace, jak se rozbiji pocitac :)
Zeliii
Profil *
Bohuzel to s js moc neumim, nemate uz nekdo hotovej nejakej priklad?
peta
Profil *
<div onclick="objdT('aaa')">aaa-xxx</div>
<div id="aaa" style="border:2px groove #fff;background:#eee;display:none;">
ukaz/Skryj div
</div>

<script>
function objGet(x)
{var d=document;return d.getElementById?d.getElementById(x):d.all?d.all[x]:d.layers?d.layers[ x]:null;}

function objdT(x)
{objGet(x).style.display=(objGet(x).style.display=="none")?"block":"no ne";}

</script>
peta
Profil *
co to je? proc tam dal mezery?


<div onclick="objdT('aaa')">ukaz/Skryj div</div>
<div id="aaa" style="border:2px groove #fff;background:#eee;display:none;">
Skryty
</div>

<script>
function objGet(x)
{var d=document;return d.getElementById?d.getElementById(x):d.all?d.all[x]:d.layers?d.layers[ x]:null;}

function objdT(x)
{objGet(x).style.display=(objGet(x).style.display=="none")?"block":"none";}
</script>
nonick
Profil *
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>untitled</title>
<meta http-equiv="content-type" content="application/xhtml+xml; charset=utf-8" />
<script type="text/javascript">
//<![CDATA[
function doConfirm(v)
{
var b = document.getElementById('btn');
b.value = 'Display dialog [last return value: ' + v + '/' + (v ? 'OK' : 'Cancel') + ']';
}

function setDisp(id, disp)
{
document.getElementById(id).style.display = disp;
}
//]]>
</script>
<style type="text/css">
/*<![CDATA[*/
#confirm {
position: absolute;
top: 40px;
left: 70px;
border: outset #000 10px;
padding: 1em 3em;
display: none;
background: #a5c4cc;
}

#ok {
background: #a5cca8;
}

#cancel {
background: #d6a4a4;
}

#ok, #cancel {
padding: 2px;
margin:2px;
}
/*]]>*/
</style>
</head>
<body>
<div id="confirm">
<div><strong>Are</strong> <em>you</em> <span style="text-decoration: underline;">sure</span>?</div>
<input type="button" id="ok" value="OK" onclick="doConfirm(true);setDisp('confirm', 'none');" />
<input type="button" id="cancel" value="Cancel" onclick="doConfirm(false);setDisp('confirm', 'none');" />
</div>
<div><input type="button" id="btn" value="Display dialog" onclick="setDisp('confirm', 'block');" /></div>
</body>
</html>
Toto téma je uzamčeno. Odpověď nelze zaslat.