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
0 8 * * * /usr/local/bin/certbot-auto renew >/dev/null 2>&1 && /etc/init.d/apache2 restart && echo "`date`: Let's Encrypt certificate is updated" >> /var/log/openproject/cron-certbot-auto.log |
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 | |
/* | |
* | |
*/ | |
class Custom_Meta_Box | |
{ | |
public static function add() | |
{ | |
// define post types to show |
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 | |
/* | |
* | |
*/ | |
class Custom_Meta_Box | |
{ | |
public static function add() | |
{ | |
// post types |
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 | |
class ShortcodeName extends WPBakeryShortCode { | |
function __construct() { | |
add_action( 'init', [ $this, 'vc_ShortcodeName_mapping' ] ); | |
add_action('wp_enqueue_scripts', [ $this, 'vc_register_ShortcodeName_assets' ] ); | |
add_shortcode( 'vc_ShortcodeName', [ $this, 'vc_ShortcodeName_html' ] ); | |
} | |
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 | |
// Add css classes for standard WordPress menu items (<li>) | |
function menu_items_classes($classes, $item, $args) { | |
// Check is it that menu that we need | |
if($args->theme_location == 'header-menu') { | |
$classes[] = 'nav-item'; | |
} | |
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
/** | |
* Register js | |
*/ | |
function register_scripts() { | |
//Register countdown script | |
wp_register_script( 'simple-countdown', get_stylesheet_directory_uri() . 'simple-countdown.js', '', false, true ); | |
} | |
add_action( 'wp_enqueue_scripts', 'register_scripts' ); |
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 child_theme_enqueue_styles() { | |
$parent_style = 'parent-style'; | |
// parent and child styles load | |
wp_enqueue_style( $parent_style, get_template_directory_uri() . '/style.css' ); | |
wp_enqueue_style( 'child-style', | |
get_stylesheet_directory_uri() . '/style.css', | |
array( $parent_style ), | |
wp_get_theme()->get('Version') | |
); |
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
<script src="https://ajax.googleapis.com/ajax/libs/webfont/1.6.26/webfont.js"></script> | |
<script> | |
WebFont.load({ | |
google: { | |
families: ["Work+Sans:400,700"] | |
} | |
}); | |
</script> |
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
wget --load-cookies /tmp/cookies.txt "https://docs.google.com/uc?export=download&confirm=$(wget --quiet --save-cookies /tmp/cookies.txt --keep-session-cookies --no-check-certificate 'https://docs.google.com/uc?export=download&id=FILEID' -O- | sed -rn 's/.*confirm=([0-9A-Za-z_]+).*/\1\n/p')&id=FILEID" -O FILENAME && rm -rf /tmp/cookies.txt |
NewerOlder