Skip to content

Instantly share code, notes, and snippets.

View lumenpink's full-sized avatar
🏠
Starting a fresh project

Lumen Lohn lumenpink

🏠
Starting a fresh project
View GitHub Profile

Keybase proof

I hereby claim:

  • I am lumenpink on github.
  • I am lumenpink (https://keybase.io/lumenpink) on keybase.
  • I have a public key ASCFDS3vUOdJepO6n3wa65fjaEqGQdH4s_61hxmTR9APNQo

To claim this, I am signing this object:

@lumenpink
lumenpink / webmention.php
Created February 20, 2023 20:57 — forked from otherjoel/webmention.php
Add simple file logging
<?php
# Licensed under a CC0 1.0 Universal (CC0 1.0) Public Domain Dedication
# http://creativecommons.org/publicdomain/zero/1.0/
#
# Webmention Emailer
# ------------------
#
# An incremental evolution of Jeremy Keith's "minimum viable" webmention,
# I've added some minimal code to have webmentions emailed to an address
@lumenpink
lumenpink / Doctrine-Multi-Tenancy.md
Created July 13, 2021 18:27 — forked from CarlosEduardo/Doctrine-Multi-Tenancy.md
Multi-Tenancy (tenant) Strategy for Doctrine ORM
<?php
header('Access-Control-Allow-Origin: *');
header('Access-Control-Allow-Headers: Authorization');
if(isset($_SERVER['HTTP_ACCEPT']) && strpos($_SERVER['HTTP_ACCEPT'], 'text/plain') !== false) {
$format = 'text';
} else {
header('Content-Type: application/json');
$format = 'json';
}
@lumenpink
lumenpink / upload-a-file.MD
Created July 7, 2020 17:38 — forked from ahmadawais/upload-a-file.MD
Upload a file using the WordPress REST API

Upload files

Using the REST API to upload a file to WordPress is quite simple. All you need is to send the file in a POST-Request to the wp/v2/media route.

There are two ways of sending a file. The first method simply sends the file in the body of the request. The following PHP script shows the basic principle:

@lumenpink
lumenpink / Pizza Recipe.md
Created July 6, 2020 11:11 — forked from syxanash/Pizza Recipe.md
My Pizza Recipe

Pizza Recipe

pizza recipe

Hi I'm Simone! This recipe was developed based on some tips I acquired over time from lots and lots of resources and tutorials like youtube videos, family and friends recipes. I'm just an amateur who likes making pizza :)

If you plan to perfectionate your pizza making skills, I suggest to come up with your own recipe and research online watching lots of tutorials and different techniques. For now the following recipe is the one that works for me!

(I'm not a professional pizzaiolo and I never had any sort of experience in a professional pizzeria restaurant)

Ingredients and quantities

@lumenpink
lumenpink / webmention.php
Created April 19, 2020 13:59 — forked from adactio/webmention.php
Minimum viable webmention in PHP.
<?php
# Licensed under a CC0 1.0 Universal (CC0 1.0) Public Domain Dedication
# http://creativecommons.org/publicdomain/zero/1.0/
if (!isset($_POST['source']) || !isset($_POST['target'])) {
header($_SERVER['SERVER_PROTOCOL'] . ' 400 Bad Request');
exit;
}

Keybase proof

I hereby claim:

  • I am lohn on github.
  • I am lohn (https://keybase.io/lohn) on keybase.
  • I have a public key ASAOKxfo84F9cFUP604WZ-HKcW1UIQqTmxUiIxSYPHOhGgo

To claim this, I am signing this object:

@lumenpink
lumenpink / nginx-rtmp.md
Created June 14, 2019 19:26 — forked from deedos/nginx-rtmp.md
Instalação e configuração de nginx-rtmp module e ffmpeg para transcoding

Instalação e Configuração de nginx-rtmp com live transcoding - S.O : Debian SID stable

  • Instalar ffmpeg da fonte: https://trac.ffmpeg.org/wiki/CompilationGuide/Ubuntu

  • Instalar nginx com módulo rtmp

      wget http://nginx.org/download/nginx-1.9.3.tar.gz
      git clone https://github.com/arut/nginx-rtmp-module
      wget ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/pcre-8.36.tar.bz2
      tar -xvf pcre-8.36.tar.bz2
      tar -xvf nginx-1.9.3.tar.gz
      cd nginx-1.9.3