Skip to content

Instantly share code, notes, and snippets.

View fencermonir's full-sized avatar

Md. Monir Hossain fencermonir

View GitHub Profile
@fencermonir
fencermonir / js.md
Created August 25, 2017 09:35 — forked from nuhil/js.md
Javascript Handbook

Javascript Handbook

A hand crafted markdown document contains all major Javascript topics covered, taken from different sources. Brush Up your JS memory.

Comments


Single line comments start with //. For multi-line commands, you use /* ... */

// This is a single line comment
@fencermonir
fencermonir / wp-query-ref.php
Created October 13, 2017 09:36 — forked from luetkemj/wp-query-ref.php
WP: Query $args
<?php
/**
* WordPress Query Comprehensive Reference
* Compiled by luetkemj - luetkemj.com
*
* CODEX: http://codex.wordpress.org/Class_Reference/WP_Query#Parameters
* Source: https://core.trac.wordpress.org/browser/tags/3.9/src/wp-includes/query.php
*/
$args = array(
/*
Copyright 2011 Martin Hawksey
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
@fencermonir
fencermonir / a)understandNode.md
Created November 16, 2017 01:23
Notes of learn_and_understand _node _js

LEARN AND UNDERSTAND NODEJS

@fencermonir
fencermonir / a) understandJS.md
Created November 16, 2017 01:24 — forked from LearningMaterial/a) understandJS.md
Notes of Javascript_The_Weird_Parts

Javascript Understanding The Weird Parts

<?php
/**
* Show posts which are only under uncategorized term
* 1 is the id of Uncategorized term
*/
function op_show_only_uncategorized( $query ) {
if ( is_admin() || ! $query->is_main_query() || ! $query->is_category( 1 ) ) {
return;
}
<?php
$caseNo = 0;
foreach (range(1, 9) as $numberOne) {
$makeNumberOne = ($numberOne * 100) + 62;
foreach (range(1, 9) as $numberTwo) {
@fencermonir
fencermonir / bootstrapCDN.html
Created February 21, 2018 03:56 — forked from planetoftheweb/bootstrapCDN.html
Bootstrap 3 CDN Page Code
<!-- HEAD SECTION -->
<!-- IE Edge Meta Tag -->
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<!-- Viewport -->
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- Minified CSS -->
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css">
@fencermonir
fencermonir / disable_wp_plugin_update.txt
Last active August 15, 2018 10:55
Disable Wordpress Plugin Update Notification
// disable update notice for plugins
function disable_plugin_updates( $value ) {
$pluginsToDisable = [
'plugin-folder-name-1/main-file-name-1.php',
'plugin-folder-name-2/main-file-name-2.php',
];
if ( isset($value) && is_object($value) ) {
foreach ($pluginsToDisable as $plugin) {
if ( isset( $value->response[$plugin] ) ) {
unset( $value->response[$plugin] );
@fencermonir
fencermonir / retina_display.js
Created August 16, 2018 08:51
Find Retina Display
function isRetinaDisplay() {
if (window.matchMedia) {
var mq = window.matchMedia("only screen and (min--moz-device-pixel-ratio: 1.3), only screen and (-o-min-device-pixel-ratio: 2.6/2), only screen and (-webkit-min-device-pixel-ratio: 1.3), only screen and (min-device-pixel-ratio: 1.3), only screen and (min-resolution: 1.3dppx)");
return (mq && mq.matches || (window.devicePixelRatio > 1));
}
}