This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if(post_password_required($post)) | |
{ | |
$context['post']->post_content = get_the_content(); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
View = Backbone.View.extend({ | |
initialize: function() { | |
/*! | |
* set the collection | |
*/ | |
this.collection = new dataCollection(); | |
/*! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var ODPHP = {}; | |
ODPHP.common = { | |
init: function() { | |
// common code running on all pages | |
} | |
}; | |
ODPHP.objective_search = { | |
init: function() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
if(class_exists('TimberMenu') && class_exists('TimberMenuItem')) | |
{ | |
class MyMenu extends TimberMenu { | |
var $MenuItemClass = 'MyMenuItem'; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var checkBoxToggle = { | |
init: function() { | |
this.checkBoxes = $('#showUnread, #showArchived'); | |
this.tableBodies = $('div.dashboard-table tbody'); | |
this.bindChange(); | |
}, | |
bindChange: function() { | |
this.checkBoxes.on('change', this.changeEvent.bind(this)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
function LocationCtrl (locations) { | |
this.locations = locations.locations; | |
} | |
LocationCtrl.resolve = { | |
locations: function(Data) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
function LocationCtrl (resolvedLocation) { | |
this.locations = resolvedLocation; | |
} | |
LocationCtrl.resolve = { | |
resolvedLocation: function(Data) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="auto-v-center"> | |
<h2>Vertically Centered Stuff</h2> | |
<p>Indeed</p> | |
</div> | |
// scss | |
.auto-v-center { | |
@include inline-block(middle); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alphabet = function(charStart, charStop) { | |
charStart = charStart || 97; | |
charStop = charStop || 122; | |
var alphabet = []; | |
for(; charStart <= charStop; charStart++) | |
alphabet.push(String.fromCharCode(charStart)) | |
return alphabet; | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Original version by Erik D. Demaine on January 31, 2011, | |
// based on code by Ronald L. Rivest (see docdist[1-7].py). | |
// Usage: | |
// node documentDistance.js file1.txt file2.txt | |
// # This program computes the "distance" between two text files | |
// # as the angle between their word frequency vectors (in radians). | |
// # | |
// # For each input file, a word-frequency vector is computed as follows: |
OlderNewer