Skip to content

Instantly share code, notes, and snippets.

@rugor
rugor / gist:be8e8e0288dad80fbbfd78226059c6d9
Created October 12, 2016 20:41
HTML: Google Map Location Output Format #rugor
<li>
<a data-id="#" data-cat="eating" data-lat="#" data-long="#" data-title="Walnut Grove School of Music + Dance">Walnut Grove School of Music + Dance</a>
</li>
@rugor
rugor / gist:f9b8e86cebd278fc8a8ce6874c35a847
Created October 11, 2016 22:38
SCSS: Familiar mixins #rugor
@mixin below($width) {
@media screen and (max-width: $width - 1) {
@content;
}
}
@mixin above($width) {
@media screen and (min-width: $width + 1) {
@content;
}
@rugor
rugor / gist:492a0c2775e21336504df75ed5329fea
Created October 1, 2016 19:48
.htaccess: WordPress HTTPS w/ Dreamhost example #rugor
AddType image/svg+xml svg
AddType image/svg+xml svgz
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
@rugor
rugor / gist:8c8d5fd669921f4a07f0cacfa9ed0067
Created October 1, 2016 00:20
SCSS: Bootstrap make column fifths
/* bootstrap fifths */
.col-sm-fifth {
@include make-col-ready();
@media (max-width: 34em) {
@include make-col(12);
}
@media (min-width: 34.1em) {
@include make-col(2.4);
@rugor
rugor / gist:f9f2fc47bd914f7238201a5678f44c0a
Created September 28, 2016 17:26
PHP: WordPress wp_nav_menu(); nice and easy w/ span wrapper #rugor
<?php
$defaults = array(
'menu_class' => 'main-menu',
'link_before' => '<span>',
'link_after' => '</span>'
);
wp_nav_menu( $defaults );
?>
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@rugor
rugor / .htaccess
Created July 8, 2016 18:10 — forked from ScottPhillips/.htaccess
Common .htaccess Redirects
#301 Redirects for .htaccess
#Redirect a single page:
Redirect 301 /pagename.php http://www.domain.com/pagename.html
#Redirect an entire site:
Redirect 301 / http://www.domain.com/
#Redirect an entire site to a sub folder
Redirect 301 / http://www.domain.com/subfolder/
@rugor
rugor / .htaccss
Last active September 26, 2016 18:04
Apache SVG MIME Type #rugor htaccess
AddType image/svg+xml svg
AddType image/svg+xml svgz
@rugor
rugor / gist:25f72ef3d1737b5e4dc5df4edc23be8c
Last active June 20, 2016 16:18
HTML: Meta tags Twitter & FB Opengraph
// facebook image minimum resolution 1200x630, twitter < 1mb
<meta property="og:title" content="European Travel Destinations">
<meta property="og:description" content="Offering tour packages for individuals or groups.">
<meta property="og:image" content="http://euro-travel-example.com/thumbnail.jpg">
<meta property="og:url" content="http://euro-travel-example.com/index.htm">
<meta name="twitter:card" content="summary_large_image">
// non-essential, but recommended
<meta name="og:site_name" content="European Travel, Inc.">
<meta name="twitter:image:alt" content="Alt text for image">