Skip to content

Instantly share code, notes, and snippets.

View finleyjchen's full-sized avatar

Finley Chen finleyjchen

View GitHub Profile
# This is a workflow to compile and deploy to WPEngine Production
name: PROD Deploy to WPEngine
# Controls when the workflow will run
on:
# Triggers the workflow on push or pull request events but only for the release-1 branch
push:
branches: [ main ]
@mix5003
mix5003 / convert.php
Created December 6, 2020 09:47
Script for convert images to WebP
<?php
function convertDir($path){
// echo "Search In $path\n";
$items = scandir($path);
foreach($items as $item){
if($item === '.' || $item === '..'){
continue;
}
@ChrisButterworth
ChrisButterworth / converter.php
Created September 5, 2018 12:26
Webp converter for WordPress
<?php
namespace Converter;
use WebPConvert\WebPConvert;
class Converter
{
public $lazy = false;
public function __construct($lazy = false)
@claudiosanches
claudiosanches / functions.php
Last active June 4, 2022 07:52
WooCommerce - Add Order Again button to My Orders actions
<?php
/**
* Add order again button in my orders actions.
*
* @param array $actions
* @param WC_Order $order
* @return array
*/
function cs_add_order_again_to_my_orders_actions( $actions, $order ) {
if ( $order->has_status( 'completed' ) ) {