I hereby claim:
- I am daveybrown on github.
- I am davey1211 (https://keybase.io/davey1211) on keybase.
- I have a public key ASCH6FriOi9EflppLOFGqoHIWye1o-Rg_dcydgwSR3rhDAo
To claim this, I am signing this object:
<?php | |
/** | |
* An ACF Relationship field with multisite support. Tested with ACF 6.3.6 | |
* | |
* This aims to be the lightest possible implementation of a multisite compatible relationship field. | |
* For the php class we extend the existing ACF Relationship field and override the necessary methods. | |
* | |
* For the JavaScript, we copy the existing ACF Relationship field and modify only the necessary properties. | |
* |
/** | |
* This class is responsible for rendering HTML from an AJAX template. | |
* | |
* This is an extension of a bare bones templating engine. | |
* @see https://stackoverflow.com/a/39065147/6671505 | |
* | |
* @example | |
* Template: | |
* <script type="text/template" data-template="results-template"> | |
* <div class="result"> |
<?php | |
namespace WPDR_RVY; | |
use WP_Post; | |
if (!defined('ABSPATH')) { | |
exit; | |
} |
Adapted from: https://www.joshcurry.co.uk/posts/ssh-create-a-tunnel-only-user-for-reverse-tunnels | |
sudo useradd -m tun-user | |
sudo nano /etc/ssh/sshd_config | |
Match User tun-user | |
AllowAgentForwarding no | |
PasswordAuthentication no | |
X11Forwarding no |
<?php | |
/** | |
* Class Comments. | |
* Code refactored from: | |
* https://gist.github.com/mattclements/eab5ef656b2f946c4bfb | |
* | |
* @package Foo | |
*/ | |
namespace Boop; |
// This is a function to limit word count on ACF fields | |
// Add cu-helper__max-words-3 to the field class for a limit of 3 words | |
var maxWordHelperClass = 'cu-helper__max-words-'; | |
$('#editor').on('keydown', '.acf-field[class*="' + maxWordHelperClass + '"] input', function (e) { | |
var maxWords = 0; | |
var $input = $(this); | |
if ($input.attr('data-max-words')) { | |
var maxWords = $input.attr('data-max-words'); |
$sliderElement = $('.variation-slider'); | |
var sliderOptions = { | |
cellSelector: '.variation-slide', | |
freeScroll: true, | |
pageDots: false, | |
imagesLoaded: true, | |
percentPosition: false, | |
wrapAround: true | |
}; |
I hereby claim:
To claim this, I am signing this object: