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
System: Host: batputer Kernel: 4.10.0-38-generic x86_64 (64 bit gcc: 5.4.0) | |
Desktop: Cinnamon 3.6.6 (Gtk 3.18.9-1ubuntu3.3) dm: lightdm Distro: Linux Mint 18.3 Sylvia | |
Machine: System: LENOVO (portable) product: 80XL v: Lenovo ideapad 320-15IKB | |
Mobo: LENOVO model: LNVNB161216 v: NO DPK Bios: LENOVO v: 4WCN37WW date: 12/04/2017 | |
Chassis: type: 10 v: Lenovo ideapad 320-15IKB | |
CPU: Dual core Intel Core i3-7100U (-HT-MCP-) cache: 3072 KB | |
flags: (lm nx sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx) bmips: 9600 | |
clock speeds: min/max: 400/2400 MHz 1: 699 MHz 2: 699 MHz 3: 699 MHz 4: 699 MHz | |
Graphics: Card: Intel Device 5916 bus-ID: 00:02.0 chip-ID: 8086:5916 | |
Display Server: X.Org 1.18.4 drivers: intel (unloaded: fbdev,vesa) |
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
//Product Sales Shortcode | |
function ticket_count_shortcode( $atts ) { | |
$atts = shortcode_atts( array( 'id' => null, 'count' => 0), $atts, 'bartag' ); | |
if( intval( $atts['id'] ) > 0 && function_exists( 'wc_get_product' ) ){ | |
$_product = wc_get_product( $atts['id'] ); | |
$tickets_left = $atts['count']-($_product->get_total_sales()); | |
} | |
return $tickets_left; | |
} |
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 fizzBuzz() { | |
var number = 1; | |
for (var i = 0; i < 100; i++) { | |
var bool = true; | |
if (number%3 ===0 && number%5 !==0){ | |
console.log('fizz'); | |
bool = false; | |
} |
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
add_filter('woocommerce_package_rates', 'hide_shipping_method', 100, 2); | |
function hide_shipping_method($rates, $package){ | |
// Additional conditions can be set | |
unset( $rates['local_pickup:12']); // This can be any shipping method, you'll have to use browser tools to see the name | |
return $rates; | |
} |
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
#!/bin/bash | |
dt=`date +"%Y-%m-%d %T"` | |
bCap=`cat /sys/class/power_supply/battery/capacity` | |
bTemp=`cat /sys/class/power_supply/battery/temp` | |
bStatus=`cat /sys/class/power_supply/battery/status` | |
bHealth=`cat /sys/class/power_supply/battery/health` | |
cTemp=`cat /sys/class/thermal/thermal_zone10/temp` | |
echo $cap |
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
git commit --fixup=HASH | |
git rebase -i --autosquash HASH^ | |
git push -f origin BRANCH |
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 {ConcreteComponent, CSSProperties} from 'vue'; | |
export const TYPE_BUTTON = 'button'; | |
export const TYPE_INPUT = 'input'; | |
export const TYPE_FILE_INPUT = 'file'; | |
export const TYPE_TEXTAREA = 'textarea'; | |
export const TYPE_DROPDOWN = 'dropdown'; | |
export const TYPE_PASSWORD = 'password'; | |
export const TYPE_CHECKBOX = 'checkbox'; | |
export const TYPE_SWITCH = 'switch'; |
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 {ConcreteComponent, CSSProperties} from 'vue'; | |
export const TYPE_BUTTON = 'button'; | |
export const TYPE_INPUT = 'input'; | |
export const TYPE_FILE_INPUT = 'file'; | |
export const TYPE_TEXTAREA = 'textarea'; | |
export const TYPE_DROPDOWN = 'dropdown'; | |
export const TYPE_PASSWORD = 'password'; | |
export const TYPE_CHECKBOX = 'checkbox'; | |
export const TYPE_SWITCH = 'switch'; |
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
// Based on a field value, show some extra input fields | |
const schemaOne = { | |
layout: [ | |
{ | |
type: 'grid', | |
props: { | |
cols: 2, | |
}, | |
children: { |
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 | |
/** | |
* OrangeHRM is a comprehensive Human Resource Management (HRM) System that captures | |
* all the essential functionalities required for any enterprise. | |
* Copyright (C) 2006 OrangeHRM Inc., http://www.orangehrm.com | |
* | |
* OrangeHRM is free software; you can redistribute it and/or modify it under the terms of | |
* the GNU General Public License as published by the Free Software Foundation; either | |
* version 2 of the License, or (at your option) any later version. |
OlderNewer