Skip to content

Instantly share code, notes, and snippets.

View sherbrow's full-sized avatar

Jonathan Lopes sherbrow

View GitHub Profile
@fat
fat / Tokenahead.less
Created April 18, 2012 04:01
Tokenahead - ghetto typeahead with facebook-like tokens 4 @couch <3
// Tokenahead.less
// ---------------
.tokenahead {
cursor: text;
overflow: hidden;
height: auto;
padding-bottom: 0;
border-color: @inputBorder;
}
@schuhwerk
schuhwerk / setcookie_samesite_polyfill.php
Last active October 15, 2021 15:04 — forked from bohwaz/setcookie_samesite_polyfill.php
PHP setcookie function polyfill with support for SameSite attribute (compatible with PHP 5.0+)
<?php
/**
* Setcookie function with support for SameSite
* @param string|null $samesite 'Lax' or 'Strict'
*/
function setcookie_samesite( $name, $value = '', $expire = 0, $path = null, $domain = null, $secure = false, $httponly = false, $samesite = null)
{
$header = 'Set-Cookie: '.rawurlencode($name) . '=' . rawurlencode($value).';';
$header .= $expire ? sprintf('expires=%s', gmdate('D, d M Y H:i:s \G\M\T', $expire)).'; ' : '';

Phaser 3 Cheatsheet

This is the content from the original Phaser cheatsheet, the site of which went down. I'm editing outdated information as I come across it.

Starting a new game

All config is optional, but width, height and scene is recommended to add.

var config = {