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 <stdio.h> | |
#include <string.h> | |
#include <stdlib.h> | |
#include <stdint.h> | |
#include <endian.h> | |
int main(int argc, char** argv) | |
{ | |
if(argc < 2) | |
return 1; |
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
// tohle je uplne ultra hack. Prehrava to obrazky do MIDI. | |
include "midi_selector.pixi" | |
midi_dev = -1 | |
midi_port = 0 | |
mc = midi_open_client( "Pixi MIDI Client" ) | |
midi_selector( mc, MIDI_PORT_READ | MIDI_PORT_WRITE ) |
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 ( | |
"database/sql" | |
"fmt" | |
"flag" | |
"os" | |
"log" | |
"runtime" | |
"html/template" |
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 | |
// params | |
$blog = isset($_GET['blog']) ? $_GET['blog'] : 'admin'; | |
$limit = !empty($_GET['limit']) ? (int) $_GET['limit'] : 5; | |
if ($limit >100) $limit=100; | |
// vars | |
$message = false; | |
$posts = []; | |
$title = 'Kyselo IFRAME'; |
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 ( | |
"database/sql" | |
"fmt" | |
"flag" | |
"os" | |
// "html/template" | |
"strings" | |
"net/url" |
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 | |
// builds playlist page | |
$forUser = null; // or set null to build global playlist | |
// hacked by Severak | |
// source: https://stackoverflow.com/a/17799714 | |
/** | |
* Get Youtube video ID from URL | |
* |
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> | |
<meta http-equiv="content-type" content="text/html; charset=utf-8" /> | |
<title>Slova dne</title> | |
</head> | |
<body> | |
<?php | |
ini_set('display_errors', 1); | |
$db = new PDO('sqlite:'.__DIR__.'/db/kyselo.sqlite'); |
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
CREATE TABLE IF NOT EXISTS "meta" ( | |
"k" text NOT NULL, | |
"v" text NOT NULL, | |
PRIMARY KEY ("k") | |
); | |
CREATE TABLE IF NOT EXISTS "license" ( | |
"id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, | |
"name" text NOT NULL, | |
FOREIGN KEY ("id") REFERENCES "book" ("id") |
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
pi@raspberrypi:~ $ file | |
Usage: file [-bcEhikLlNnprsvzZ0] [--apple] [--extension] [--mime-encoding] [--mime-type] | |
[-e testname] [-F separator] [-f namefile] [-m magicfiles] file ... | |
file -C [-m magicfiles] | |
file [--help] | |
pi@raspberrypi:~ $ cd Downloads/ | |
pi@raspberrypi:~/Downloads $ file _pol_118.zst | |
_pol_118.zst: Zstandard compressed data (v0.8+), Dictionary ID: None | |
pi@raspberrypi:~/Downloads $ apt-cache search zstd | |
libzstd-dev - fast lossless compression algorithm -- development files |
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 | |
// spočítá, kolik Milošovi darovali jeho voliči a kolik trolové | |
// na vstupu je uložené HTML transparentního účtu z | |
// https://www.fio.cz/ib2/transparent?a=2501277007 | |
$html = file_get_contents('milos69.html'); | |
$doc = new DOMDocument(); | |
$doc->loadHTML($html); | |
$sxml = simplexml_import_dom($doc); |