Skip to content

Instantly share code, notes, and snippets.

View palimadra's full-sized avatar

Pali Madra palimadra

  • Chandigarh, India
View GitHub Profile
@palimadra
palimadra / css3-media-queries-code
Created September 12, 2014 08:02
CSS3 Media Queries template
/* All Smartphones in portrait and landscape ----------- */
@media only screen
and (min-device-width : 320px)
and (max-device-width : 480px) {
/* YOUR STYLE GOES HERE */
}
/* All Smartphones in landscape ----------- */
@media only screen
and (min-width : 321px) {
@palimadra
palimadra / media-query-template
Last active August 29, 2015 14:06
Media query CSS code for a web page
@media only screen
and (max-width : 1024px) { }
@media only screen
and (min-width : 769px)
and (max-width : 1024px) { }
@media only screen
and (max-width : 768px) { }
@palimadra
palimadra / cheatsheet-md-template
Last active August 29, 2015 14:06
Markdown template for cheatsheets
# Typography
## Headings
Headings from `h1` through `h6` are constructed with a `#` for each level:
``` markdown
# h1 Heading
## h2 Heading
### h3 Heading
@palimadra
palimadra / gist:f4ae3b5a8ccf965b3b07
Last active August 29, 2015 14:03 — forked from CristinaSolana/gist:1885435
How to ensure that forks are updated whenever the master is updated.

1. Clone your fork:

git clone [email protected]: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

A Starting Point for CSS Styleguides

This is a CSS styleguide that you could fork to use for your project. Some of the rules give you multiple acceptable options. If you want to adopt this styleguide for your project, you should modify it for your project.

Here is an example styleguide made from this starting point

This styleguide follows my styleguide for styleguides. That means it follows the following rules:

  • Focus on readability.
  • Focus on consistency.
@palimadra
palimadra / alternate.html
Last active August 29, 2015 13:57
Tumblr starter theme.
<!DOCTYPE html>
<!--[if IE 8]> <html class="no-js lt-ie9"> <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js"> <!--<![endif]-->
<html lang="{block:English}en{/block:English}{block:French}fr{/block:French}{block:German}de{/block:German}{block:Japanese}ja{/block:Japanese}{block:Italian}it{/block:Italian}{block:Spanish}es{/block:Spanish}{block:Polish}pl{/block:Polish}">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>
{Title}
@palimadra
palimadra / dabblet.css
Created February 24, 2014 16:53
CSS3 Image Gallery
/**
* CSS3 Image Gallery
*/
body {
background: black url(http://subtlepatterns.com/patterns/dark_wood.png);
font: 14px "Helvetica Neue", Helvetica, sans-serif;
}
h2 {
color: white;
@palimadra
palimadra / dabblet.css
Created February 24, 2014 16:53 — forked from maxhoffmann/dabblet.css
CSS3 Image Gallery
/**
* CSS3 Image Gallery
*/
body {
background: black url(http://subtlepatterns.com/patterns/dark_wood.png);
font: 14px "Helvetica Neue", Helvetica, sans-serif;
}
h2 {
color: white;
@palimadra
palimadra / fb-gallery-embed.html
Created January 31, 2014 07:09 — forked from alexdunae/fb-gallery-embed.html
Embed a Facebook gallery into your website
<?php
/* Merge multiple RSS feeds with SimplePie
*
* Just modify the path to SimplePie and
* modify the $feeds array with the feeds you want
*
* You should probably also change the channel title, link and description,
* plus I added a CC license you may not want
*
* Help from: http://www.webmaster-source.com/2007/08/06/merging-rss-feeds-with-simplepie/