Skip to content

Instantly share code, notes, and snippets.

@conorbuck
conorbuck / angle-between-points.js
Created May 5, 2012 22:51
JavaScript: Find the angle between two points
var p1 = {
x: 20,
y: 20
};
var p2 = {
x: 40,
y: 40
};
@jimmygle
jimmygle / PHP-Recursive-Implosion.php
Last active March 29, 2024 21:47
PHP function to recursively implode multi-dimensional arrays.
<?php
/**
* Recursively implodes an array with optional key inclusion
*
* Example of $include_keys output: key, value, key, value, key, value
*
* @access public
* @param array $array multi-dimensional array to recursively implode
* @param string $glue value that glues elements together