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
/** | |
* Instagram Media Exporter | |
* | |
* @author: Jawdat Sobh | |
*/ | |
(function(){ | |
let _list = {} | |
window.addEventListener('scroll',function(event){ | |
setTimeout(() => { | |
document.querySelectorAll('.FFVAD').forEach((e) => { |
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
// Base | |
let w = width; // shape width | |
let h = height; // shape height | |
let r = row; // grid row start by 0 | |
let c = column; // grid column start by 0 | |
// Square | |
let left = r * w; // transform left position | |
let top = j * h; // transform top position |
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
if( null == username_exists( $email_address ) ) { | |
// Generate the password and create the user | |
$password = wp_generate_password( 12, false ); | |
$user_id = wp_create_user( $email_address, $password, $email_address ); | |
// Set the nickname | |
wp_update_user( | |
array( |
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
/*Filter styles*/ | |
.saturate {-webkit-filter: saturate(3); filter: saturate(3);} | |
.grayscale {-webkit-filter: grayscale(100%); filter: grayscale(100%);} | |
.contrast {-webkit-filter: contrast(160%); filter: contrast(160%);} | |
.brightness {-webkit-filter: brightness(0.25); filter: brightness(0.25);} | |
.blur {-webkit-filter: blur(3px); filter: blur(3px);} | |
.invert {-webkit-filter: invert(100%); filter: invert(100%);} | |
.sepia {-webkit-filter: sepia(100%); filter: sepia(100%);} | |
.huerotate {-webkit-filter: hue-rotate(180deg); filter: hue-rotate(180deg);} | |
.rss.opacity {-webkit-filter: opacity(50%); filter: opacity(50%);} |
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
$('#priceContainer').on('hide',function(){ | |
$('#price').val("0.0"); | |
}); | |
$('#priceContainer').hideWithEvent(); |
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
UPDATE `tbl` | |
SET `date` = DATE_ADD(`date`, INTERVAL -1 MONTH) | |
WHERE MONTH(`date`) = 11 |
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
<script> | |
/* configuration */ | |
var count = <?php echo Yii::app()->session->getTimeout(); ?>; //session | |
var countdown = 60; //warning 60 seconds | |
var idle = 10; //warning when idle 10 seconds | |
var urluser = <?php echo "'".Yii::app()->createUrl('site/lock', array('id'=>Yii::app()->user->id))."'"; ?>; | |
var idlecountdown = countdown; | |
var idletime = idle; | |
var show = true; |
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 nicetime($date){ | |
if(empty($date)) { | |
return "No date provided"; | |
} | |
$periods = array("second", "minute", "hour", "day", "week", "month", "year", "decade"); | |
$lengths = array("60","60","24","7","4.35","12","10"); | |
$now = time(); | |
$unix_date = strtotime($date); |
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 str_pad(input, pad_length, pad_string, pad_type){ | |
var output = input.toString(); | |
if (pad_string === undefined) { pad_string = ' '; } | |
if (pad_type === undefined) { pad_type = 'STR_PAD_RIGHT'; } | |
if (pad_type == 'STR_PAD_RIGHT') { | |
while (output.length < pad_length) { | |
output = output + pad_string; | |
} | |
} else if (pad_type == 'STR_PAD_LEFT') { | |
while (output.length < pad_length) { |
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
.container-flex {-webkit-display: -webkit-box;-webkit-display: -webkit-flex;display: -webkit-box;display: -ms-flexbox;display: flex;-webkit-align-items: stretch;-webkit-box-align: stretch;-ms-flex-align: stretch;align-items: stretch;} |
NewerOlder