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 | |
/*----------------------------------------------------------- | |
- Name: Options Widget | |
- Description: Test SMK Toolkit | |
- Version: 1.0 | |
-------------------------------------------------------------*/ | |
if( ! class_exists('Options_Widget') && class_exists('SMK_Toolkit_Widget') ) { | |
class Options_Widget extends SMK_Toolkit_Widget { | |
/*----------------------------------------------------------- |
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 | |
return [ | |
'AED' => 'د.إ', | |
'AFN' => '؋', | |
'ALL' => 'L', | |
'AMD' => 'AMD', | |
'ANG' => 'ƒ', | |
'AOA' => 'Kz', | |
'ARS' => '$', |
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 | |
return array( | |
'EUR' => [ 'Euro', '€' ], | |
'USD' => [ 'US dollar', '$' ], | |
'JPY' => [ 'Japanese yen', '¥' ], | |
'BGN' => [ 'Bulgarian lev', 'лв.' ], | |
'CZK' => [ 'Czech koruna', 'Kč' ], | |
'DKK' => [ 'Danish krone', 'DKK' ], | |
'GBP' => [ 'Pound sterling', '£' ], |
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
class Person { | |
constructor($name){ | |
this._name = $name; | |
} | |
getName(){ | |
return `Hello ${this._name}`; | |
} | |
} |
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
import Util from './util' | |
import Swipe from './swipe' | |
class Slider { | |
constructor( slider_el, options = {} ) { | |
// Default options | |
this.opt = { | |
inactiveClass: 'inactive-slide', | |
speed: 5000, | |
startAt: 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 | |
function everyTimeFrame($totalMinutes = 4, $lastSeconds = 16) | |
{ | |
$time = []; | |
for ($i = 0; $i <= 59; $i++) { | |
for ($j = 0; $j <= $totalMinutes; $j++) { | |
$second = strlen($i) > 1 ? $i : "0{$i}"; |
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 ContactFormProcessing | |
{ | |
protected $action = 'example_contact_form'; | |
public function ajaxInit() | |
{ | |
add_action("wp_ajax_{$this->action}", [$this, 'process']); | |
add_action("wp_ajax_nopriv_{$this->action}", [$this, 'process']); | |
} |
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 | |
$flags = \FilesystemIterator::KEY_AS_PATHNAME | \FilesystemIterator::SKIP_DOTS; | |
$iterator = new \FilesystemIterator(__DIR__, $flags); | |
foreach ($iterator as $path => $item) { | |
if ($item->isDir()) { | |
$muPath = trailingslashit($path); | |
$fileName = basename($item->getFileName()); | |
$filePath = "{$muPath}/{$fileName}.php"; |
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 | |
namespace ZeroWP; | |
class PostBlocks | |
{ | |
/** | |
* @param \WP_Post|int $post | |
* @param callable $callback | |
* |
OlderNewer