Skip to content

Instantly share code, notes, and snippets.

View LinuxDoku's full-sized avatar

Martin Lantzsch LinuxDoku

View GitHub Profile
<Lisa> überforder mich net!
<Martin> Konflikte mit C#?
<Lisa> ja
<Lisa> wir haben uns no net so lieb
<Martin> Das wird schon, wenn ihr euch etwas näher kommt, geb der Beziehung zeit
<Martin> C# ist Anfangs etwas schüchern, aber seine Freundin Intelli Sense kann dir Tipps geben xDD
@LinuxDoku
LinuxDoku / gist:1908404
Created February 25, 2012 13:01
Form1.cs
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Threading;
/**
* This will display tplMods please use the smarty function in order to get the best results!
* @param string $position name of the position
* @return bool
*/
public function displayTplModification($position, $surroundDiv) {
$return = true;
if (!isset($this->_tplModificationCache[$position])){
Vorbereiten zum Ersetzen von linux-libc-dev 3.1.6-1 (durch .../linux-libc-dev_3.2.1-1_amd64.deb) ...
Entpacke Ersatz für linux-libc-dev ...
dpkg-deb: Datei »/var/cache/apt/archives/linux-libc-dev_3.2.1-1_amd64.deb« enthält nicht verstandene Datenelemente data.tar.xz , gebe auf
dpkg: Fehler beim Bearbeiten von /var/cache/apt/archives/linux-libc-dev_3.2.1-1_amd64.deb (--unpack):
Unterprozess dpkg-deb --fsys-tarfile gab den Fehlerwert 2 zurück
Fehler traten auf beim Bearbeiten von:
/var/cache/apt/archives/linux-libc-dev_3.2.1-1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
Fehler traten auf beim Bearbeiten von:
/var/cache/apt/archives/linux-libc-dev_3.2.1-1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
private bool check(int player)
{
for (int x = 7; x > 0; x--)
{
for (int y = 6; y > 0; y--)
{
int[] tmp = fields[x, y];
if (tmp[0] == 1 && tmp[1] == player)
{
for (int xCurrent = (x - 1); xCurrent > (x + 1); xCurrent++)
@LinuxDoku
LinuxDoku / gist:1345047
Created November 7, 2011 13:54
Vier Gewinnt, Gewinnprüfung - Brain --> Keyboard --> Fail :D
private bool check(int player)
{
for (int x = 7; x > 0; x--)
{
for (int y = 6; y > 0; y--)
{
int[] tmp = fields[x, y];
if (tmp[0] == 1 && tmp[0] == player)
{
for (int xCurrent = x - 1; xCurrent > x + 1; xCurrent++)
@LinuxDoku
LinuxDoku / gist:1326342
Created October 30, 2011 19:50
Zu verkaufen
Ram
• 512MB 333mhz DDR von Hynx
• 256MB PC133mhz (Low Profile) von Kingston (neu, mit OVP)
• 64MB PC 133mhz FRU: PA2061U von Toshiba
Netzwerk
• Intel PRO/Wireless 2200BG Network Connection Card
• 2x Netgear PCMCIA WLan Karte
Festplatten
• 60GB 2,5” IDE HD von Toshiba
• 10GB 2,5” IDE HD von Fujitsu
<?php
error_reporting(E_ERROR);
set_time_limit(0);
// config
$host = 'localhost';
$port = 1414;
// connect
$socket = socket_create(AF_INET, SOCK_STREAM, SOL_TCP);
<html>
<head>
<title>RG Test</title>
<script type="text/javascript" src="http://code.jquery.com/jquery-1.6.4.min.js"></script>
<script type="text/javascript">
// web socket test
var socket = new WebSocket("ws://localhost:1414/sockettest/server.php");
socket.onopen = function(event) {
$('#response').html($('#response').html()+"\n Connect to server...");
};