Skip to content

Instantly share code, notes, and snippets.

View mahircoding's full-sized avatar
🏠
Working from home

MahirCoding mahircoding

🏠
Working from home
  • surakarta Indonesia
  • 08:14 (UTC +07:00)
View GitHub Profile
<?php
// This overrides woocommerce
if ( ! defined( 'ABSPATH' ) ) {
exit;
}
// add_action( 'after_setup_theme', 'bt_checkout_editor_loaded' );
function bt_checkout_editor_loaded() {
@mahircoding
mahircoding / bp-messages-formatting-toolbar.php
Created June 2, 2025 14:08
Buddyboos - add custom record button
<?php
/**
* BP Nouveau messages editor toolbar
*
* This template can be overridden by copying it to yourtheme/buddypress/messages/parts/bp-messages-formatting-toolbar.php.
*
* @since BuddyBoss 2.1.4
* @version 1.0.0
*/
?>
@mahircoding
mahircoding / send mail with api mailtrap
Last active May 30, 2025 17:19
send mail with api mailtrap
<?php
function kirim($v, $x, $y, $z) {
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://send.api.mailtrap.io/api/send",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
@mahircoding
mahircoding / builder.php
Last active January 28, 2025 16:26
jet engine custom form lokasi file di builder.php & frontend-forms.js
<?php
/**
* Form builder class
*/
// If this file is called directly, abort.
if ( ! defined( 'WPINC' ) ) {
die;
}
function get_kirim_email_list()
{
require '../vendor/autoload.php';
require '../config/database.php';
$user_id = $_SESSION['user_id'];
$user = \SI\Model\User::whereId($user_id)->first();
$api_token = $user->api_kirimemail;
$username = $user->user_kirimemail;
$base_url = 'https://api.kirim.email/v3/list?nolimit=true';
@mahircoding
mahircoding / gist:5087f3013b3ecb3919d2cef20d3094fc
Last active September 25, 2023 03:27
rest api updater salesloo
<?php
function get_latest_update($request) {
$id = 'ID FILE LICENSE';
$purchase_code = sanitize_text_field($request->get_param('purchase_code'));
$host = sanitize_text_field($request->get_param('host'));
$item = get_post(salesloo_get_item_by_license_id($id));
$package = get_post_meta($item->ID, 'package', true);
return new \WP_REST_Response([
'name' => $item->post_title,
@mahircoding
mahircoding / fake-recent-sales-notification-popup.markdown
Created March 27, 2020 19:09
Fake Recent Sales Notification Popup

Fake Recent Sales Notification Popup

Around 85% of visitors leave an online store without buying an item. Among many reasons, lack of trust, engagement, and authenticity prevents new visitors from placing an order. Built from the concept of Social Proof, Sales Pop plugin helps you combat the 85% rate of site abandonment with recent sales notifications.

A Pen by Ahmed El Sheikh on CodePen.

License.