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 | |
// Only dependency that's used | |
// TODO: Implement filter for the_content(); | |
use WebPConvert\WebPConvert; | |
add_filter('wp_generate_attachment_metadata', function($meta) { | |
$path = wp_upload_dir(); // get upload directory |
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 | |
namespace Converter; | |
use WebPConvert\WebPConvert; | |
class Converter | |
{ | |
public $lazy = false; | |
public function __construct($lazy = false) |
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
#!/bin/bash | |
RED="\033[0;31m" | |
YELLOW="\033[33m" | |
REDBG="\033[0;41m" | |
WHITE="\033[1;37m" | |
NC="\033[0m" | |
if [ "$1" = "create" ] || [ "$1" = "add" ]; then | |
# Ask for document root |