Skip to content

Instantly share code, notes, and snippets.

View orangerdev's full-sized avatar
🏠
busy mending broken

Ridwan Arifandi orangerdev

🏠
busy mending broken
View GitHub Profile
@orangerdev
orangerdev / request.php
Last active January 29, 2019 08:09
Class to create basic controller on request
<?php
namespace YOUR_PLUGIN;
class Request
{
private $url;
/**
* private variable
* make sure that the value of the properity is unique, lowercase, non whitespace and
@orangerdev
orangerdev / rest.php
Last active February 13, 2019 10:31
REST MVC for WordPress
<?php
namespace QMQUOTE\Admin;
class Rest
{
private $key = 'quoteme'; // change this prefix
private $script = 'quoteme-action'; // change this script action
/**
* Construction
@orangerdev
orangerdev / 99.co.json
Created July 30, 2021 12:21
99.co lighthouse
This file has been truncated, but you can view the full file.
{
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/92.0.4515.107 Safari/537.36",
"environment": {
"networkUserAgent": "Mozilla/5.0 (Linux; Android 7.0; Moto G (4)) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4420.0 Mobile Safari/537.36 Chrome-Lighthouse",
"hostUserAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/92.0.4515.107 Safari/537.36",
"benchmarkIndex": 1390,
"credits": {
"axe-core": "4.1.3"
}
},
@orangerdev
orangerdev / caldera-form-data-entry.php
Created August 5, 2021 04:08
Save caldera form entry programmatically
$form_id = 'CF610b605dd7710';
$form = Caldera_Forms_Forms::get_form($form_id);
//Basic entry information
$entry_detail = new Caldera_Forms_Entry_Entry();
$entry_detail->form_id = $form['ID'];
$entry_detail->datestamp = current_time('mysql');
$entry_detail->status = 'pending';
$entry_detail->user_id = get_current_user_id();
@orangerdev
orangerdev / hubspot-custom.js
Created April 3, 2025 17:02
Hubspot modification for Wix to receive any URL params then parse them to the fields
!(function () {
("use strict");
const e = {
RECEIVED_ANALYTICS: "HS_CTA_PARENT_RECEIVED_ANALYTICS",
DEVICE_TYPE: "HS_CTA_PARENT_DEVICE_TYPE",
PROXY_ANALYTICS_FN_CALLBACK: "HS_CTA_PARENT_PROXY_ANALYTICS_FN",
INIT: "HS_CTA_PARENT_INIT",
SHOWING_CTA: "HS_CTA_SHOWING_CTA",
SEND_EXTRACTED_STYLES: "HS_SEND_EXTRACTED_STYLES",
STARTED: "HS_CTA_STARTED",