Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
<html>
<head>
<script language=JavaScript>
function showColors(obj) {
blahForm.fgclr.value = obj.currentStyle["color"];
blahForm.bgclr.value = obj.currentStyle["backgroundColor"];
}
</script>
</head>
<body>
<form name=blahForm>
<input type=button value='Click Me' onclick='showColors(this)'><br>
<input type=text name=fgclr>Foreground Color<br>
<input type=text name=bgclr>Background Color
</form>
</body>
</html>
<html>
<head>
<script language=JavaScript>
function showColors(obj) {
blahForm.blahTextArea.value += "Foreground Color: " + obj.currentStyle["color"] + "\n";
blahForm.blahTextArea.value += "Background Color: " + obj.currentStyle["backgroundColor"] + "\n";
}
</script>
</head>
<body>
<form name=blahForm>
<input type=button value='Click Me' onclick='showColors(this)'><br>
<textarea name=blahTextArea rows=10 cols=50></textarea>
</form>
</body>
</html>
function radioselect()
{
if (document.frm_name.radiobutton[0].checked)
{
document.frm_name.buttonselect.value="One!";
alert('Correct')
return true;
}
}
function radioselect()
{
{
document.frm_name.buttonselect.value="One!";
alert('Correct')
return true;
}
}
<script language="javascript">
function addTextToFoo(text){
document.FooForm.Foo.focus();
document.selection.createRange().text = text;
}
</script>
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script language="JavaScript">
<!--
function AddText(tag) {
var ta = document.forms[0].ta;
// NS + FF
if (window.getSelection) {
start = ta.selectionStart;
end = ta.selectionEnd;
// Split before, sel, after and insert tags in between
before = (ta.value).substring(0, start);
sel = (ta.value).substring(start, end);
after = (ta.value).substring(end, ta.textLength);
ta.value = before + tag + after;
// focus
ta.focus();
ta.selectionStart = end + 5 + (tag.length * 2);
ta.selectionEnd = ta.selectionStart;
}
// IE
else if (document.selection && document.selection.createRange) {
ta.focus();
document.selection.createRange().text = tag;
}
// Not supported
else {
alert ("your browser does not support these functions");
}
}
// -->
</script>
</head>
<body>
<script language="JavaScript" type="text/javascript">
<!--
//-->
</script>
<form name="test" action="" method="">
<input type="button" onClick="AddText('hello')" value="button1" />
<input type="button" onClick="AddText('munchie')" value="button2" />
<br />
<textarea name="ta" rows="10" cols="50"></textarea>
</form>
</body>
</html>