$ rails g model User
belongs_to
has_one
apt install php7.2-common php7.2-cli php7.2-zip php7.2-opcache php7.2-mysql php7.2-mcrypt php7.2-mbstring php7.2-json php7.2-intl php7.2-gd php7.2-fpm php7.2-curl php7.2-bz2
Copy the php7.2-fpm pool configuration from php7.0-fpm
cp -f /etc/php/7.0/fpm/pool.d/www.conf /etc/php/7.2/fpm/pool.d/www.conf
<?php | |
// Event taxonomies | |
add_action( 'init', function() { | |
$labels = array( | |
'name' => _x( 'Terms', 'taxonomy general name' ), | |
'singular_name' => _x( 'Term', 'taxonomy singular name' ), | |
); | |
register_taxonomy( 'taxonomy_name', array( 'post' ), array( | |
'hierarchical' => false, |
(function(window) { | |
'use strict'; | |
var toggleEvent = function(el, name, fn, unbind) { | |
var methodName = (unbind ? 'remove' : 'add') + 'EventListener'; | |
el[methodName](name, fn, false); | |
}; | |
<?php | |
/* | |
Plugin Name: Import demo | |
Plugin URI: http://royduineveld.nl | |
Description: A demo import for my blog | |
Version: 1.0 | |
Author: Roy Duineveld | |
Author URI: http://royduineveld.nl | |
*/ |
// License: GPLv2+ | |
var el = wp.element.createElement, | |
registerBlockType = wp.blocks.registerBlockType, | |
ServerSideRender = wp.components.ServerSideRender, | |
TextControl = wp.components.TextControl, | |
InspectorControls = wp.editor.InspectorControls; | |
/* | |
* Here's where we register the block in JavaScript. |
// Generate unique IDs for use as pseudo-private/protected names. | |
// Similar in concept to | |
// <http://wiki.ecmascript.org/doku.php?id=strawman:names>. | |
// | |
// The goals of this function are twofold: | |
// | |
// * Provide a way to generate a string guaranteed to be unique when compared | |
// to other strings generated by this function. | |
// * Make the string complex enough that it is highly unlikely to be | |
// accidentally duplicated by hand (this is key if you're using `ID` |
<?php | |
namespace App\Services; | |
use Ratchet\Http\HttpServer; | |
use Ratchet\MessageComponentInterface; | |
use Ratchet\ConnectionInterface; | |
use Ratchet\Server\IoServer; | |
use Ratchet\WebSocket\WsServer; | |
class RatchetServer implements MessageComponentInterface |
<?php | |
/** | |
* Plugin Name: WordPress Export to JSON | |
* Plugin URI: https://jsnelders.com/ | |
* Description: Export all WordPress posts, pages, comments, tags, commments and users to a JSON file. | |
* Author: Jason Snelders | |
* Author URI: http://jsnelders.com | |
* Version: 2020-01-30.1 | |
**/ |