Skip to content

Instantly share code, notes, and snippets.

View tamaspap's full-sized avatar

Tamás Pap tamaspap

  • Cluj-Napoca, Romania
View GitHub Profile
array (
'(GMT-11:00) Midway Island' => 'Pacific/Midway',
'(GMT-11:00) Samoa' => 'Pacific/Samoa',
'(GMT-10:00) Hawaii' => 'Pacific/Honolulu',
'(GMT-09:00) Alaska' => 'US/Alaska',
'(GMT-08:00) Pacific Time (US & Canada)' => 'America/Los_Angeles',
'(GMT-08:00) Tijuana' => 'America/Tijuana',
'(GMT-07:00) Arizona' => 'US/Arizona',
'(GMT-07:00) Chihuahua' => 'America/Chihuahua',
'(GMT-07:00) La Paz' => 'America/Chihuahua',
@tamaspap
tamaspap / gist:6281449
Created August 20, 2013 13:31
PHP Timezones - OLD
array (
'(GMT-12:00) International Date Line West' => 'Pacific/Wake',
'(GMT-11:00) Midway Island' => 'Pacific/Apia',
'(GMT-11:00) Samoa' => 'Pacific/Apia',
'(GMT-10:00) Hawaii' => 'Pacific/Honolulu',
'(GMT-09:00) Alaska' => 'America/Anchorage',
'(GMT-08:00) Pacific Time (US & Canada); Tijuana' => 'America/Los_Angeles',
'(GMT-07:00) Arizona' => 'America/Phoenix',
'(GMT-07:00) Chihuahua' => 'America/Chihuahua',
'(GMT-07:00) La Paz' => 'America/Chihuahua',
@tamaspap
tamaspap / javascript-inheritance-with-object-create.js
Created June 5, 2014 14:30
JS inheritance with Object.create
// Shape - superclass
function Shape() {
this.x = 0;
this.y = 0;
}
// superclass method
Shape.prototype.move = function(x, y) {
this.x += x;
this.y += y;
@tamaspap
tamaspap / gist:3accf35a2b057d050846
Created June 17, 2014 18:25
Setup LAMPP on Ubuntu
// LAMP
sudo apt-get install tasksel
sudo tasksel install lamp-server
//CURL + Composer + mcrypt
sudo apt-get install curl php5-curl php5-mcrypt
curl -sS https://getcomposer.org/installer | php
sudo mv composer.phar /usr/local/bin/composer
//activate mod_rewrite + mcrypt
@tamaspap
tamaspap / uploaderjs-basic-demo.html
Created June 25, 2014 11:01
UploaderJS - Basic demo
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Uploader Demo</title>
<link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css"/>
<style>
.uploader-button {
position: relative;
overflow: hidden;
.nav {}
.nav__list {}
.nav__list__item {}
.nav__list__item--featured {}
.block {} /* represents a higher level of abstraction or component */
.block__element {} /* represents a descendent of .block */
.block--modifier {} /* represents a different state or version of .block. */
.nav {
@at-root #{&}__list {
@at-root #{&}__item {
@at-root #{&}--featured {}
}
}
}
.nav {
&__list {
&__item {
&--featured {
}
}
}
}
.nav {
height: 30px;
&__list {
list-style: none;
&__item {
float: left;
&--featured {
color: #e86ea4;
}
}