Skip to content

Instantly share code, notes, and snippets.

View miznokruge's full-sized avatar

Mizno Kruge miznokruge

View GitHub Profile
@miznokruge
miznokruge / BCA_API.php
Created January 4, 2024 04:00 — forked from dertajora/BCA_API.php
This is my code when learn to use BCA API for my office. This code only works on Sandbox environment and there is no confidential information here. FYI, based on my experience if you want to implement this code using real environment of BCA API, you need to do some UAT with BCA side.
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
class BCAAPI extends MY_Controller {
function __construct(){
$this->api_key = "YOUR API KEY";
$this->api_secret = "YOUR API SECRET";
$this->client_id = "YOUR CLIENT ID";
<?php
require_once(dirname(__FILE__) . '/wp-config.php');
$wp->init();
$wp->parse_request();
$wp->query_posts();
$wp->register_globals();
$wp->send_headers();
// Your WordPress functions here...
@miznokruge
miznokruge / infectedFiles.md
Created March 10, 2021 03:02 — forked from frosit/infectedFiles.md
Some commands for finding and clearing infected PHP files

Finding infected files with following bash commands

** Command to list all infected files:

  • grep -lr --include=*.php "eval(base64_decode" /path/to/webroot
  • grep -lr --include=*.php "eval" .
  • grep -lr --include=*.php "base64" .

Command to remove malicious code:

  • grep -lr --include=*.php "eval(base64_decode" /path/to/webroot | xargs sed -i.bak 's/<?php eval(base64_decode[^;]*;/<?php\n/g'
@miznokruge
miznokruge / gist:3b4c1839108db439a3c18699d934e492
Created January 14, 2021 17:55 — forked from matoakley/gist:1092571
MySQL to convert a string into a slug
LOWER(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(TRIM('My String'), ':', ''), ')', ''), '(', ''), ',', ''), '\\', ''), '\/', ''), '\"', ''), '?', ''), '\'', ''), '&', ''), '!', ''), '.', ''), ' ', '-'), '--', '-'), '--', '-')) AS `post_name`
@miznokruge
miznokruge / list.md
Created January 14, 2021 03:09 — forked from ih2502mk/list.md
Quantopian Lectures Saved
@miznokruge
miznokruge / gist:f820325dd147083ce6df5c0e811ba59a
Last active November 13, 2020 04:35
Mengerjakan soal matematika anak kelas 4
<?php
if (isset($_GET['iterasi']) && $_GET['iterasi'] != '') {
$iterasi = (int) $_GET['iterasi'];
$tgl_ketemu = $_GET['tgl_ketemu'];
$penjual_telur = [];
$penjual_sabun = [];
$penjual_mie = [];
for ($i = 1; $i <= $iterasi; $i++) {
$penjual_telur[] = $i * 8;
@miznokruge
miznokruge / AndroidManifest.xml
Created June 1, 2020 08:23 — forked from Venryx/AndroidManifest.xml
Record audio on Android in the background (even when screen is off)
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.myapp">
<application android:allowBackup="true" android:icon="@mipmap/ic_launcher android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round" android:supportsRtl="true" android:theme="@style/AppTheme">
<service android:name=".ForegroundService" android:enabled="true" android:exported="true"></service>
<activity
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale"
@miznokruge
miznokruge / sms.php
Created August 17, 2018 10:47 — forked from ankitsam/sms.php
Send SMS using AWS SNS via AWS PHP SDK
use Aws\Sns\SnsClient;
$sns = \Aws\Sns\SnsClient::factory(array(
'credentials' => [
'key' => '<access_key>',
'secret' => '<access_secret>',
],
'region' => '<region>',
'version' => 'latest',
));
@miznokruge
miznokruge / backlink-checker.php
Created April 27, 2018 01:35 — forked from tuckbloor/backlink-checker.php
check if a website is linking back to you
@miznokruge
miznokruge / 1100 List Website Iklan Gratis Indonesia Sebagai Backlink
Created April 27, 2018 01:30
1100 List Website Iklan Gratis Indonesia Sebagai Backlink