created_date: 02.07.2016
last_update_date: 02.07.2016
author: @yugoslavskiy
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
#Uninstall 3D Builder | |
Get-AppxPackage *3dbuilder* | Remove-AppxPackage | |
#Uninstall Alarms and Clock | |
Get-AppxPackage *windowsalarms* | Remove-AppxPackage | |
#Uninstall Calculator | |
Get-AppxPackage *windowscalculator* | Remove-AppxPackage | |
#Uninstall Calendar and Mail: |
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
/* | |
* Polylang Language API functions tester - WordPress | |
* Github: https://gist.github.com/icetee/fbbfef5534fead58611e | |
* | |
*/ | |
function ex_pll_the_languages($arg = '') { | |
if ( function_exists('pll_the_languages') ) { | |
return pll_the_languages($arg); | |
} |
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 | |
/* | |
* Paginate Advanced Custom Field repeater | |
*/ | |
if( get_query_var('page') ) { | |
$page = get_query_var( 'page' ); | |
} else { | |
$page = 1; | |
} |
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
# macOS | |
find . -maxdepth 5 -iname ".ftpconfig" | zip DEV.zip -@ | |
# Windows 10 | |
Get-ChildItem -Recurse -Depth 5 -Filter ".ftpconfig" -Path . | % { $_.FullName } | zip DEV.zip -@ |
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
alias wanip='dig +short myip.opendns.com @resolver1.opendns.com' |
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
[mysql] | |
user=backups | |
password=secret | |
[mysqldump] | |
user=backups | |
password=secret |
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
let count = 10100; | |
let prefix = "KGY" | |
let keys = []; | |
let getRandomNumber = () => ("0000" + Math.round(Math.random() * 10000)).slice(-4) | |
do { | |
let randomKey = prefix + "-" + getRandomNumber() + "-" + getRandomNumber(); | |
if (keys.indexOf(randomKey) === -1) { |
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
--- web/app/plugins/civicrm/civicrm/CRM/Profile/Selector/Listings.php | |
+++ Listings.php | |
@@ -451,6 +451,8 @@ | |
$additionalWhereClause = 'contact_a.is_deleted = 0'; | |
+ $extraWhereClause = 'contact_a.contact_type = "Organization" AND contact_a.id != 1'; | |
+ | |
if ($extraWhereClause) { | |
$additionalWhereClause .= " AND {$extraWhereClause}"; |
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
var rows = []; | |
$('tbody tr').each((i, elem) => { | |
var $elem = $(elem), | |
$td = $(elem).find('td'); | |
var row = []; | |
row.push($td[0].innerText); | |
row.push($td[1].innerText); | |
row.push($td[2].innerText); |
NewerOlder