Created
March 12, 2015 07:13
-
-
Save faoud/3e7ca85be14130343463 to your computer and use it in GitHub Desktop.
// source http://jsbin.com/jalago
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<title>JS Bin</title> | |
<style id="jsbin-css"> | |
p{color:maroon;} | |
</style> | |
</head> | |
<body> | |
<input type = "text" id="changes"> | |
<p id="paragraphT">change the user text</p> | |
<button onclick ="changeFunction()">Changes Test Text From Input Box</button> | |
<p>This is another paragraph</p> | |
<a href="javascript:void(0);"> | |
Click here to do nothing | |
</a> | |
<a href="javascript:void(document.body.style.backgroundColor='green');"> | |
Click here for green background | |
</a> | |
<script id="jsbin-javascript"> | |
var coolNumber = 2; | |
var variableNumber = 2; | |
var variableName = "John"; | |
function changeFunction() | |
{ | |
document.getElementById("paragraphT").style.color = "orange"; | |
var variableChangeText = document.getElementById("changes").value;document.getElementById("paragraphT").innerHTML = variableChangeText; | |
} | |
</script> | |
<script id="jsbin-source-css" type="text/css">p{color:maroon;} | |
</script> | |
<script id="jsbin-source-javascript" type="text/javascript">var coolNumber = 2; | |
var variableNumber = 2; | |
var variableName = "John"; | |
function changeFunction() | |
{ | |
document.getElementById("paragraphT").style.color = "orange"; | |
var variableChangeText = document.getElementById("changes").value;document.getElementById("paragraphT").innerHTML = variableChangeText; | |
} | |
</script></body> | |
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
p{color:maroon;} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var coolNumber = 2; | |
var variableNumber = 2; | |
var variableName = "John"; | |
function changeFunction() | |
{ | |
document.getElementById("paragraphT").style.color = "orange"; | |
var variableChangeText = document.getElementById("changes").value;document.getElementById("paragraphT").innerHTML = variableChangeText; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment