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 http-equiv="Content-Type" content="text/html; charset=utf-8" /> | |
<title>dogs slideshow</title> | |
<link href="style.css" rel="stylesheet" type="text/css"> | |
<script src="slide.js" type="text/javascript"></script> | |
</head> | |
<body> |
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 PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" | |
"http://www.w3.org/TR/html4/loose.dtd"> | |
<html> | |
<head> | |
<title></title> | |
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> | |
<meta name="description" content=""> | |
<meta name="keywords" content=""> | |
<script src="entity utils.js"></script> |
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 PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" | |
"http://www.w3.org/TR/html4/loose.dtd"> | |
<html> | |
<head> | |
<title></title> | |
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> | |
<meta name="description" content=""> | |
<meta name="keywords" content=""> | |
</head> |
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 PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> | |
<html> | |
<head> | |
<title>using ajax</title> | |
<script language="javascript" src="jax.js"></script> | |
<style language="css"> | |
input, textarea { | |
font: 10pt courier | |
} | |
</style> |
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
require_relative 'webc'; | |
require 'uri'; | |
ws = Webclient.new 'codepad.org'; | |
begin | |
ws.start "/", | |
URI.encode_www_form( | |
'code' => IO.read(ARGV[0]), | |
'lang' => ARGV[1] == "/p" ? "Plain Text" : 'Ruby', |
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 projector = new Object(); | |
var Slide = function(path, caption){this.path = path; this.caption = caption;} | |
// events hook | |
onload = initialize; | |
// relative path or absolute - doesn't matter, caption | |
var slides = [ | |
new Slide('neko/red_scarf.jpg', 'I am very smart'), | |
new Slide('neko/awakening.jpg', 'Wahhh! I just woke up'), |
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> | |
<body> | |
<h2>Upload a picture</h2> | |
<form enctype="multipart/form-data" | |
action="http://puush.me/api/up" method="post"> | |
Key: <input type="text" name="k"> | |
<input type="file" name="f" accept="image/jpeg,image/png"> | |
<input name="z" value="poop" style="display:none"> <br><br> | |
<input type="submit"> | |
</form> |
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
static void uploadPic(HttpURLConnection connection, File name) { | |
String BOUNDARY = "--$hocuspocus"; | |
DataOutputStream output = null; | |
connection.setRequestProperty( | |
"Content-Type", | |
"multipart/form-data; boundary=$hocuspocus" | |
); | |
try { | |
output = new DataOutputStream(connection.getOutputStream()); | |
output.writeBytes(BOUNDARY + "\r\n"); |
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 nil = 1; | |
function getFirst(elm) { | |
var firstElm = document.getElementsByTagName(elm)[0]; | |
if (firstElm == undefined) | |
return nil; | |
return firstElm; | |
} |
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
#include <iostream> | |
#include <algorithm> | |
#include <array> | |
int main() | |
{ | |
std::array<float, 5> numbers = {1.2, 3.4, 3.7, 2.8, 6.9}; | |
std::cout << std::boolalpha; | |
std::cout << "ascending short: " |
OlderNewer