This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_action( 'wp_enqueue_scripts', 'solusipress_jquery_number_wa' ); | |
function solusipress_jquery_number_wa() { | |
if( is_page( 'forminator-test-wa' ) ) { | |
wp_enqueue_script( 'jquery-number', 'https://businessprofile.solusipress.com/wp-content/uploads/custom-css-js/18.js', array('jquery') ); | |
wp_enqueue_script( 'input-spinner', 'https://businessprofile.solusipress.com/wp-content/uploads/custom-css-js/105.js', array('jquery') ); | |
wp_enqueue_script( 'underscore' ); | |
} | |
} | |
add_action( 'wp_footer', 'solusipress_forminator_whatsapp' ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_action( 'wp_enqueue_scripts', 'solusipress_jquery_number' ); | |
function solusipress_jquery_number() { | |
if( is_page( 'forminator-test' ) ) { | |
wp_enqueue_script( 'jquery-number', 'https://businessprofile.solusipress.com/wp-content/uploads/custom-css-js/18.js' ); | |
/* load javascript dari Code JS yang sudah dibuat */ | |
wp_enqueue_script( 'input-spinner', 'https://businessprofile.solusipress.com/wp-content/uploads/custom-css-js/105.js' ); | |
} | |
} | |
add_action( 'wp_footer', 'solusipress_forminator_format_number' ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_action( 'wp_enqueue_scripts', 'solusipress_jquery_number' ); | |
function solusipress_jquery_number() { | |
if( is_page( 'forminator-test' ) ) { | |
wp_enqueue_script( 'jquery-number', 'https://businessprofile.solusipress.com/wp-content/uploads/custom-css-js/18.js' ); | |
} | |
} | |
add_action( 'wp_footer', 'solusipress_forminator_format_number' ); | |
function solusipress_forminator_format_number() { | |
if( is_page( 'forminator-test' ) ) { ?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$remote = wp_remote_get( RAJAONGKIR_BASE_URI . '/province', array( | |
'headers' => array( 'key' => RAJAONGKIR_API_KEY ) | |
) ); | |
$data_province = array(); | |
if( is_array( $remote ) && $remote['response']['code'] == 200 ) { | |
$remote_body = json_decode( $remote['body'] ); | |
$data_province = $remote_body->rajaongkir->results; | |
} | |
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class SP_Ajax_CalculateOngkir_Action extends WP_AJAX { | |
protected $action = 'calculate-ongkir'; | |
protected function run() { | |
if( $this->requestType( 'POST' ) ) { | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class SP_Ajax_Administrative_Action extends WP_AJAX { | |
protected $action = 'administrative-action'; | |
protected function run() { | |
if( isset( $_GET[ 'province' ] ) && $_GET[ 'province' ] != '' ) { | |
$prov = trim( $_GET['province'] ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: My WordPress Custom Form | |
* Plugin URI: https://solusipress.com/ | |
* Description: Form untuk berbagai keperluan di website pribadi | |
* Author: Yerie Piscesa | |
* Author URI: https://solusipress.com/ | |
* Text Domain: sp-custom-form | |
* Domain Path: /languages | |
* Version: 0.9.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_action( 'init', 'sp_woocommerce_contact_form' ); | |
function sp_woocommerce_contact_form() { | |
if( !is_admin() ) { | |
include_once( ABSPATH . 'wp-admin/includes/plugin.php' ); | |
if( is_plugin_active( 'woocommerce/woocommerce.php' ) ) { | |
add_action( 'woocommerce_after_add_to_cart_button', 'sp_woo_add_contact_form_wa' ); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function( $ ) { | |
$( function(){ | |
var $regency, $district, $village; | |
$( '#province_id' ).on( 'change', function() { | |
var data = { | |
"action": "get_administrative", | |
"province": $(this).val(), | |
"security": chainedselect.security |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$page_slug = 'cf7-administrative-data'; | |
function wpcf7_enqueue_script() { | |
if( is_page( $page_slug ) ) { | |
wp_register_script( 'yp-administrative', plugin_dir_url( __FILE__ ) . 'chainedselect.js' ); | |
} | |
} | |
add_action( 'wp_enqueue_scripts', 'wpcf7_enqueue_script' ); |