Created
May 28, 2011 16:45
-
-
Save jakswa/997020 to your computer and use it in GitHub Desktop.
CLOUD9IDE WOOO
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
<html> | |
<head> | |
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js" | |
type="text/javascript"></script> | |
<script type="text/javascript"> | |
$().ready(function() { $("#btnn").click(function() { | |
$.get("http://hellonode.jakswa.cloud9ide.com", | |
function(data) { | |
$("body").html(data); | |
} | |
); | |
});}); | |
</script> | |
</head> | |
<body> | |
Gonna put stuff here dynamically from<br /> | |
a server running with the source in<br /> | |
server.js! EXCITED?<br /> | |
<div id="holder"></div> | |
<button id="btnn" type="button">Click?</button> | |
</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
//runs on Cloud9's Node.js service | |
//this is pretty much the 'hello world' from http://nodejs.org/ | |
var http = require('http'); | |
http.createServer(function (req, res) { | |
res.writeHead(200, {'Content-Type': 'text/plain', 'Access-Control-Allow-Origin': '*'}); | |
res.end('Hello World\n'); | |
}).listen(process.env.C9_PORT, "0.0.0.0"); | |
console.log('Server running on port' + process.env.C9_PORT); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment