Skip to content

Instantly share code, notes, and snippets.

View I3rixon's full-sized avatar

Alexander UW5EMC I3rixon

View GitHub Profile
@I3rixon
I3rixon / functions.php
Created January 19, 2024 10:19 — forked from lukecav/functions.php
Enable revisions on products in WooCommerce
add_filter( 'woocommerce_register_post_type_product', 'wc_modify_product_post_type' );
function wc_modify_product_post_type( $args ) {
$args['supports'][] = 'revisions';
return $args;
}
@I3rixon
I3rixon / GooglePageRankCheckSum.php
Created October 2, 2015 00:44 — forked from KartikTalwar/GooglePageRankCheckSum.php
Google PageRank Checksum Algorithm
<?php
function fch($csm)
{
if($csm < 0)
$csm += 4294967296.0;
$a = (int)fmod($csm, 10);
$t = 1;
$b = (int)($csm / 10);