This file contains hidden or 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 | |
/** | |
* Implemets hook_preprocess_node(). | |
* | |
* Create variable from translated taxonomy term name. | |
* Code by @tikaszvince. | |
*/ | |
function THEMENAME_preprocess_node(&$variables) { | |
/** @var Drupal\node\Entity\Node $node */ |
This file contains hidden or 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"; | |
// Load plugins | |
const autoprefixer = require("autoprefixer"); | |
const browsersync = require("browser-sync").create(); | |
const cp = require("child_process"); | |
const cssnano = require("cssnano"); | |
const del = require("del"); | |
const eslint = require("gulp-eslint"); | |
const gulp = require("gulp"); |
This file contains hidden or 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
------------------------------------------------- | |
-- DUMP CATEGORIES | |
-- Fields to be imported: 'ID', 'Active (0/1)', 'Name *', 'Parent category', 'Root category (0/1)', 'Description', 'Meta title', 'Meta keywords', 'Meta description', 'URL rewritten', 'Image URL', | |
------------------------------------------------- | |
SELECT a.id_category, a.active, b.name, c.name as parent_name, 0 as is_root, | |
b.description, b.meta_title, b.meta_keywords, b.meta_description, b.link_rewrite, "" as image_url | |
FROM ps_category AS a | |
JOIN ps_category_lang AS b ON a.id_category = b.id_category | |
LEFT JOIN ps_category_lang AS c ON a.id_parent = c.id_category |
This file contains hidden or 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
ffmpeg -i "https://content.jwplatform.com/manifests/Wqyolfwt.m3u8" -c copy -bsf:a aac_adtstoasc video.mp4 |
This file contains hidden or 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
(function() { | |
var CSSCriticalPath = function(w, d, opts) { | |
var opt = opts || {}; | |
var css = {}; | |
var pushCSS = function(r) { | |
if(!!css[r.selectorText] === false) css[r.selectorText] = {}; | |
var styles = r.style.cssText.split(/;(?![A-Za-z0-9])/); | |
for(var i = 0; i < styles.length; i++) { | |
if(!!styles[i] === false) continue; | |
var pair = styles[i].split(": "); |