One Paragraph of project description goes here
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.
<?php | |
/* | |
This function saved my life. | |
found on: http://www.sitepoint.com/forums//showthread.php?t=438748 | |
by: crvandyke | |
It takes an object, and when all else if/else/recursive functions fail to convert the object into an associative array, this one goes for the kill. Who would'a thunk it?! | |
*/ | |
$array = json_decode(json_encode($object), true); |
/*! | |
* jQuery simpleWidget - v0.1pre - 10/28/2010 | |
* http://benalman.com/ | |
* | |
* Copyright (c) 2010 "Cowboy" Ben Alman | |
* Dual licensed under the MIT and GPL licenses. | |
* http://benalman.com/about/license/ | |
*/ | |
(function($,undefined){ |
<template> | |
<textarea | |
:id="id" | |
:name="name" | |
:value="value" | |
:placeholder="placeholder" | |
:rows="rows" | |
:cols="cols" | |
class="form-control" | |
@dragover.prevent |
This is a solution to run the original enc2ly
CLI program within a Docker container.
There are two CLI programs that convert Encore musical files to LilyPond.
Unfortunately I wasn't able to run these programs on my MacOS.
So, here are the instructions for using the original enc2ly
CLI programm within a Docker container.
<?php
declare(strict_types=1);
require dirname(__DIR__) . '/../vendor/autoload.php';
class Entity
{
public function __construct(array $data)
{
<?php | |
// Examples for different uses of PHP callbacks | |
output(callback(function() { return 'anonymous function'; })); | |
output(callback('func')); | |
output(callback(new InvokableClass())); | |
output(callback([new NormalClass(), 'test'])); | |
output(callback('StaticClass::staticMethod')); | |
output(callback([StaticClass::class, 'staticMethod'])); |
<?php | |
/** | |
* Get class name from file | |
* | |
* This is a working example, that works for PHP 7.4 and 8.x. | |
* | |
* @see https://stackoverflow.com/questions/7153000/get-class-name-from-file | |
*/ | |
function get_class_name(string $file): string |
<?php | |
/** | |
* A low-level function for retrieving data. Throws an exception in case of an error. | |
* | |
* @return array | |
*/ | |
function retrieve_data(): array | |
{ | |
// throw an exception in case of an error |
<?php | |
$types = []; | |
$fp = @fopen("/downloads/db1-duplicate-keys.txt", "r"); | |
if ($fp) { | |
$i = 0; | |
$status = 0; | |
while (($buffer = fgets($fp, 4096)) !== false) { |