Taken from StackExchange
Thanks to LangLangC
For temperature and other improvements see https://gist.github.com/cdleon/d16e7743e6f056fedbebc329333d79df
<?php | |
/** | |
* | |
* Calculate reading time on page save. | |
* Add this to your ready.php file. | |
* Uses a field called 'article_read_time' to store the value | |
* and the field 'page_content' as the readable content. | |
* You'll need to update those field names if yours are different. | |
* |
Taken from StackExchange
Thanks to LangLangC
For temperature and other improvements see https://gist.github.com/cdleon/d16e7743e6f056fedbebc329333d79df
<?php | |
if( !class_exists('acf') ) | |
{ | |
$tp_acf_notice_msg = __( 'This website needs "Advanced Custom Fields Pro" to run. Please download and activate it', 'tp-notice-acf' ); | |
/* | |
* Admin notice | |
*/ | |
add_action( 'admin_notices', 'tp_notice_missing_acf' ); | |
function tp_notice_missing_acf() |
<? | |
///////////////////// | |
// slack2html | |
// by @levelsio | |
///////////////////// | |
// | |
///////////////////// | |
// WHAT DOES THIS DO? | |
///////////////////// | |
// |
ProductID Database | |
106 GeoIP.dat | |
111 GeoIPOrg.dat | |
112/115 GeoIPRegion.dat | |
117 GeoIPASNum.dat | |
119 GeoIPUserType.dat | |
121/122 GeoIPISP.dat | |
132/133 GeoIPCity.dat | |
135 GeoIPAreaCode.dat | |
137 GeoIPDMACode.dat |
IMPORTANT | |
Please duplicate this radar for a Safari fix! | |
This will clean up a 50-line workaround. | |
rdar://22376037 (https://openradar.appspot.com/radar?id=4965070979203072) | |
////////////////////////////////////////////////////////////////////////////// | |
(Now available as a standalone repo.) |
git diff -p \ | |
| grep -E '^(diff|old mode|new mode)' \ | |
| sed -e 's/^old/NEW/;s/^new/old/;s/^NEW/new/' \ | |
| git apply |
-- This script automatically `cd`s to the directory of the current document. | |
-- You can use $f to represent the file for the current document. | |
-- This is nowhere near perfect, just a quick and dirty script. | |
-- NOTE: you need to have "Enable access for assistive devices" checked... | |
-- in the Accessibility preference pane. | |
-- Example: select a file in Finder, and type: echo The filename is $f | |
on getCurrentDocument() |
brew update | |
brew versions FORMULA | |
cd `brew --prefix` | |
git checkout HASH Library/Formula/FORMULA.rb # use output of "brew versions" | |
brew install FORMULA | |
brew switch FORMULA VERSION | |
git checkout -- Library/Formula/FORMULA.rb # reset formula | |
## Example: Using Subversion 1.6.17 | |
# |
dev: | |
mailer: | |
class: sfMailer | |
param: | |
logging: %SF_LOGGING_ENABLED% | |
charset: %SF_CHARSET% | |
delivery_strategy: realtime | |
transport: | |
class: Swift_SmtpTransport | |
param: |