Skip to content

Instantly share code, notes, and snippets.

View tharlab's full-sized avatar
💭
I may be slow to respond.

Hary AK tharlab

💭
I may be slow to respond.
  • TharLab
  • east java
View GitHub Profile
@tharlab
tharlab / rarreg.key
Created February 26, 2025 02:59 — forked from MuhammadSaim/rarreg.key
Step 1: Create a file called rarreg.key Step 2: Paste into the file the raw content of this gist Step 3: Go to Winrar install directory (by default => c:\ProgramFiles\WinRAR\ ) Step 4: Paste the rarreg.key into WinRAR directory Step 5: Enjoy
RAR registration data
WinRAR
Unlimited Company License
UID=4b914fb772c8376bf571
6412212250f5711ad072cf351cfa39e2851192daf8a362681bbb1d
cd48da1d14d995f0bbf960fce6cb5ffde62890079861be57638717
7131ced835ed65cc743d9777f2ea71a8e32c7e593cf66794343565
b41bcf56929486b8bcdac33d50ecf773996052598f1f556defffbd
982fbe71e93df6b6346c37a3890f3c7edc65d7f5455470d13d1190
6e6fb824bcf25f155547b5fc41901ad58c0992f570be1cf5608ba9
@tharlab
tharlab / woo-template-parts-filter.php
Created February 27, 2024 01:31 — forked from Bobz-zg/woo-template-parts-filter.php
Quickly unhook WooCommerce template parts
<?php
/**
* Remove variouse template parts in WooCommerce
*/
add_filter( 'wc_get_template', function( $located, $template_name, $args, $template_path, $default_path ) {
$remove = [
'sale-flash.php',
'meta.php',
@tharlab
tharlab / functions.php
Created February 22, 2024 02:50 — forked from hivepress/functions.php
Add description to the details field in the payout request form #hivepress #marketplace
<?php
add_filter(
'hivepress/v1/forms/payout_request',
function( $form ) {
$form['fields']['details']['description'] = 'custom text here';
return $form;
},
1000
);
@tharlab
tharlab / functions.php
Created February 22, 2024 02:50 — forked from hivepress/functions.php
Add description to the note field in the order delivery form #hivepress #marketplace
<?php
add_filter(
'hivepress/v1/forms/order_deliver',
function( $form ) {
$form['fields']['note']['description'] = 'custom text here';
return $form;
},
1000
);
@tharlab
tharlab / mycred-woo-payout-on-completed
Created February 10, 2024 23:07 — forked from mycred/mycred-woo-payout-on-completed
By default myCRED will payout points for WooCommerce orders when an order has been marked as "paid". This means that no points will be paid out if a users pays using a manual gateway such as Check or Bank Transfers. This code snippet will force myCRED to payout when an order has been marked as "Completed" instead of paid.
/**
* Adjust myCRED Point Rewards
* Will move the points payout from when an order is "paid" to when
* an order is "completed".
* @version 1.0
*/
add_action( 'after_setup_theme', 'mycred_pro_adjust_woo_rewards', 110 );
function mycred_pro_adjust_woo_rewards() {
remove_action( 'woocommerce_payment_complete', 'mycred_woo_payout_rewards' );

STEP 1

Create the folder e.g. "/c/www/tests/php-fast-route/" on your machine.

cd /c/www/tests/php-fast-route/
composer init
composer require nikic/fast-route

@tharlab
tharlab / functions.php
Last active December 21, 2023 10:19 — forked from hivepress/functions.php
Enable rich text (HTML) editor for the listing description #hivepress #listings
<?php
add_filter(
'hivepress/v1/models/listing',
function( $model ) {
$model['fields']['description']['editor'] = array( //'quicktags' => true,
'media_buttons' => false, //if false show image button instead
'toolbar1' => 'styleselect, bold, italic, underline, bullist, numlist, blockquote, link, image, wp_adv, quicklink, fullscreen,',
);
return $model;
@tharlab
tharlab / WFACP_ReCaptcha_For_WC
Created December 21, 2023 06:04 — forked from xlplugins/WFACP_ReCaptcha_For_WC
Funnelkit Checkout comptability added with ReCaptcha For WC by Thirteen Web Solution
class WFACP_ReCaptcha_For_WC {
private $instance = null;
public function __construct() {
add_action( 'wfacp_template_load', [ $this, 'actions' ] );
}
public function is_enable() {
return class_exists( 'I13_Woo_Recpatcha' );
}
@tharlab
tharlab / checkout-functions.php
Created December 21, 2023 05:58 — forked from doubleedesign/checkout-functions.php
Add reCaptcha v2 to WooCommerce Checkout
<?php
/**
* Add reCaptcha to checkout form
* Note: Can't place within the payment part of the form, WooCommerce just won't show it, choose an appropriate action to add it to accordingly
* @param $checkout
*/
function doublee_show_me_the_checkout_captcha($checkout) {
echo '<div class="g-recaptcha" data-sitekey="YOUR_KEY_HERE"></div>';
}
add_action('woocommerce_checkout_order_review', 'doublee_show_me_the_checkout_captcha', 18);