Skip to content

Instantly share code, notes, and snippets.

View sebdesign's full-sized avatar

Sébastien Nikolaou sebdesign

View GitHub Profile
@Ingramz
Ingramz / app\Http\Kernel.php
Last active November 3, 2020 05:59
Laravel 5 CloudFlare Proxy Middleware Compatibility
<?php
// ...
protected $middleware = [
// ...
'App\Http\Middleware\CloudFlareProxies',
];
// ...
@razwan
razwan / _baseline.scss
Created April 14, 2014 16:20
Aligning type to baseline the right way with SASS
$base-font-size: 16px;
$base-line-height: 1.5;
// this value may vary for each font
// unitless value relative to 1em
$cap-height: 0.68;
@mixin baseline($font-size, $scale: 2) {
@drakakisgeo
drakakisgeo / gist:7200450
Created October 28, 2013 16:52
Money Format (decimal db value to Euro)
function money($amount){
setlocale(LC_MONETARY, 'el_GR.UTF-8');
return money_format("%!n",$amount);
}
@dypsilon
dypsilon / frontendDevlopmentBookmarks.md
Last active March 27, 2024 06:36
A badass list of frontend development resources I collected over time.
@jpatters
jpatters / HeidiDecode.js
Last active March 20, 2024 14:29
Decodes a password from HeidiSQL. HeidiSQL passwords can be found in the registry. Use File -> Export Settings to dump all settings. Great for if you forget a password.
function heidiDecode(hex) {
var str = '';
var shift = parseInt(hex.substr(-1));
hex = hex.substr(0, hex.length - 1);
for (var i = 0; i < hex.length; i += 2)
str += String.fromCharCode(parseInt(hex.substr(i, 2), 16) - shift);
return str;
}
document.write(heidiDecode('755A5A585C3D8141786B3C385E3A393'));
@taylor
taylor / gist:2968566
Created June 21, 2012 21:12
fix ca cert on centos 5

this sucks, but it works. centos should really just build the damn ca-certificates package for centos5 found on centos6

cp /etc/pki/tls/certs/ca-bundle.crt /root/ca-bundle.crt-old
curl http://curl.haxx.se/ca/cacert.pem -o /etc/pki/tls/certs/ca-bundle.crt
@kevinSuttle
kevinSuttle / meta-tags.md
Last active March 31, 2024 14:26 — forked from lancejpollard/meta-tags.md
List of Usable HTML Meta and Link Tags
@CristinaSolana
CristinaSolana / gist:1885435
Created February 22, 2012 14:56
Keeping a fork up to date

1. Clone your fork:

git clone git@github.com:YOUR-USERNAME/YOUR-FORKED-REPO.git

2. Add remote from original repository in your forked repository:

cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream
@matthanger
matthanger / blti-launch.php
Last active October 24, 2022 07:12
Sample code for Basic LTI Consumer in PHP
<?php
# ------------------------------
# START CONFIGURATION SECTION
#
$launch_url = "https://lti.tools/test/tp.php";
$key = "12345";
$secret = "secret";
$launch_data = array(