This gist's comment stream is a collection of webdev apps for OS X. Feel free to add links to apps you like, just make sure you add some context to what it does — either from the creator's website or your own thoughts.
— Erik
// http://wpsnipp.com/index.php/template/create-multiple-search-templates-for-custom-post-types/ | |
/* | |
Create a new file called search.php and add the following search template. | |
Change the $search_refer= CUSTOM_POST_TYPE to the names of your post types. | |
You will also need to change the template path to the corresponding template you wish to display results. | |
*/ | |
<? | |
/* Template Name: Search Results */ |
Attention: the list was moved to
https://github.com/dypsilon/frontend-dev-bookmarks
This page is not maintained anymore, please update your bookmarks.
<?php | |
/* | |
* If you already have something in your functions.php, please remove these first few lines | |
*/ | |
// Usage tribe_is_past_event( $event_id ) | |
function tribe_is_past_event( $event = null ){ | |
if ( ! tribe_is_event( $event ) ){ | |
return false; | |
} | |
$event = tribe_events_get_event( $event ); |
sass/ | |
| | |
|– base/ | |
| |– _reset.scss # Reset/normalize | |
| |– _typography.scss # Typography rules | |
| ... # Etc… | |
| | |
|– components/ | |
| |– _buttons.scss # Buttons | |
| |– _carousel.scss # Carousel |
import React from "react"; | |
import { render } from "react-dom"; | |
const ParentComponent = React.createClass({ | |
getDefaultProps: function() { | |
console.log("ParentComponent - getDefaultProps"); | |
}, | |
getInitialState: function() { | |
console.log("ParentComponent - getInitialState"); | |
return { text: "" }; |
// Register Custom Taxonomy | |
function ess_custom_taxonomy_Item() { | |
$labels = array( | |
'name' => 'Brands', | |
'singular_name' => 'Brand', | |
'menu_name' => 'Brands', | |
'all_items' => 'All Brands', | |
'parent_item' => 'Parent Brand', | |
'parent_item_colon' => 'Parent Brand:', |
<link rel="preload" href="css/global.min.css" as="style" onload="this.rel='stylesheet'"> | |
<noscript><link rel="stylesheet" href="css/global.min.css"></noscript> | |
<script> | |
/*! loadCSS. [c]2017 Filament Group, Inc. MIT License */ | |
!function(a){"use strict";var b=function(b,c,d){function j(a){if(e.body)return a();setTimeout(function(){j(a)})}function l(){f.addEventListener&&f.removeEventListener("load",l),f.media=d||"all"}var g,e=a.document,f=e.createElement("link");if(c)g=c;else{var h=(e.body||e.getElementsByTagName("head")[0]).childNodes;g=h[h.length-1]}var i=e.styleSheets;f.rel="stylesheet",f.href=b,f.media="only x",j(function(){g.parentNode.insertBefore(f,c?g:g.nextSibling)});var k=function(a){for(var b=f.href,c=i.length;c--;)if(i[c].href===b)return a();setTimeout(function(){k(a)})};return f.addEventListener&&f.addEventListener("load",l),f.onloadcssdefined=k,k(l),f};"undefined"!=typeof exports?exports.loadCSS=b:a.loadCSS=b}("undefined"!=typeof global?global:this); | |
/*! loadCSS rel=preload po |
<?php | |
/** | |
* The Events Calendar - Get the next upcoming Featured Event | |
* | |
* Notes: | |
* 1) Ignores all-day events. | |
* 2) For the date comparison, this code assumes each event is in | |
* the same timezone as your WordPress General Settings timezone. | |
* |