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
<? | |
error_reporting(E_ALL); | |
/* | |
@ PHP5 Mysql-klasse | |
@ Copyright by Web Communication World (www.wccw.in) | |
@ Diese Klasse darf frei unter diesem Vermerk eingesetzt, verändert und weitergegeben werden | |
@ Weitere Klassen, sind auf www.wccw.in Kostenlos erhältlich | |
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> | |
<title>Game Programming with JavaScript, HTML and CSS: Introduction</title> | |
<style type='text/css'> | |
#game_region { | |
width: 600px; | |
height: 400px; | |
background-color: black; | |
position:relative; |
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> | |
<title>moving box - stops/starts on left click</title> | |
<style type='text/css'> | |
#game_region { | |
width: 600px; | |
height: 400px; | |
background-color: black; | |
position:relative; |
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
$(window).focus(function() { | |
window_focus = true; | |
if(blinkInterval) clearInterval(blinkInterval); | |
blinkInterval = false; | |
document.title = 'Smack Holes'; | |
}) | |
.blur(function() { | |
window_focus = false; | |
}); |
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
<?php | |
if (!function_exists('imagecreatefrombmp')) { function imagecreatefrombmp($filename) { | |
// version 1.00 | |
if (!($fh = fopen($filename, 'rb'))) { | |
trigger_error('imagecreatefrombmp: Can not open ' . $filename, E_USER_WARNING); | |
return false; | |
} | |
// read file header | |
$meta = unpack('vtype/Vfilesize/Vreserved/Voffset', fread($fh, 14)); |
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
<?php | |
class Validate { | |
// validates if folder exists, is writeable and needs to be created | |
// it takes an array with paths as parameter | |
// usage: | |
// $paths = array("url1","url2","url3"); | |
// val = new Validate(); | |
// val->ecw($paths); | |
// | |
function ecw($paths){ |
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
package net.coderockers.gamepanel; | |
import java.awt.Color; | |
import java.awt.Dimension; | |
import java.awt.Graphics; | |
import java.awt.Image; | |
import java.awt.event.KeyAdapter; | |
import java.awt.event.KeyEvent; | |
import java.awt.event.MouseAdapter; | |
import java.awt.event.MouseEvent; |
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
import java.io.*; | |
import java.awt.*; | |
import javax.imageio.ImageIO; | |
import java.awt.image.BufferedImage; | |
public class ComparePixelColor { | |
public static void main(String args[]) throws IOException{ | |
File file= new File("res/redsquare.jpg"); | |
BufferedImage image = ImageIO.read(file); |
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
import java.io.*; | |
import java.awt.*; | |
import javax.imageio.ImageIO; | |
import java.awt.image.BufferedImage; | |
public class CompareAllPixelColor { | |
public static void main(String args[]) throws IOException{ | |
File file= new File("res/rgbsquare.png"); | |
BufferedImage image = ImageIO.read(file); |
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
package main | |
import "fmt" | |
import "net/http" | |
func handler(w http.ResponseWriter, r *http.Request) { | |
fmt.Fprint(w, "Hello, WORLD!") | |
} | |
func main() { |