Skip to content

Instantly share code, notes, and snippets.

Avatar
🤡
code fool

Humayun Ahmed humayunahmed8

🤡
code fool
View GitHub Profile
@humayunahmed8
humayunahmed8 / bootstrap-grid.css
Created May 14, 2022
Bootstrap 5 Grid System
View bootstrap-grid.css
/*!
* Bootstrap Grid v5.0.2 (https://getbootstrap.com/)
* Copyright 2011-2021 The Bootstrap Authors
* Copyright 2011-2021 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/
.container,
.container-fluid,
.container-lg,
.container-md,
View live-sass-compiler.json
"liveSassCompile.settings.formats": [
{
"format": "expanded",
"extensionName": ".css",
"savePath": null,
"savePathSegmentKeys": null,
"savePathReplaceSegmentsWith": null
}
],
View class-kirki-installer-section.php
<?php
/**
* This file adds a custom section in the customizer that recommends the installation of the Kirki plugin.
* It can be used as-is in themes (drop-in).
*
* @package kirki-helpers
*/
if ( ! function_exists( 'kirki_installer_register' ) ) {
/**
@humayunahmed8
humayunahmed8 / remove-and-redeclare-function.php
Created Feb 28, 2022
Remove existing function from main theme and redeclare function in child theme
View remove-and-redeclare-function.php
<?php
// Remove tgmpa function from main theme and redeclare the function in child theme
function remove_content_filter() {
remove_filter( 'tgmpa_register', 'themeplace_register_required_plugins' );
}
add_action( 'after_setup_theme', 'remove_content_filter' );
@humayunahmed8
humayunahmed8 / wp-cli-configure.txt
Last active Feb 17, 2022
How to configure wp-cli
View wp-cli-configure.txt
# Prerequisite
================
1. Download **xampp or wamp**
2. Download Powershell (https://github.com/PowerShell/PowerShell/releases/download/v7.2.1/PowerShell-7.2.1-win-x64.msi)
3. Create "wp.bat" file
4. Download "wp-cli.phar" (https://raw.github.com/wp-cli/builds/gh-pages/phar/wp-cli.phar)
# Official Doc:
================
1. WP CLI phar - https://raw.github.com/wp-cli/builds/gh-pages/phar/wp-cli.phar
@humayunahmed8
humayunahmed8 / codestar-options.php
Created Feb 14, 2022
Custom widget for popular posts/latest posts/posts from custom post type
View codestar-options.php
<?php if ( ! defined( 'ABSPATH' ) ) { die; }
function mydeals_theme_shortcode_options($options){
$options = array();
}
add_filter('cs_shortcode_options', 'mydeals_theme_shortcode_options');
function mydeals_theme_customizer($options){
$options = array();
}
@humayunahmed8
humayunahmed8 / vs-code-essentials-extensions.txt
Created Feb 13, 2022
VS Code Essential Extensions and Theme List
View vs-code-essentials-extensions.txt
Extenstions Name and Authors:
=============================
# Themes
1. Andromeda - Eliver Lara
2. Dracula Official - Dracula Theme
3. Learn with Sumit Theme - Sumit Saha
# Extensions
1. Auto Rename Tag => Jun Han
2. Autoprefixer => mrmlnc
@humayunahmed8
humayunahmed8 / settings.json
Last active Feb 13, 2022
VS Code Settings
View settings.json
{
"workbench.colorTheme": "Dracula Soft",
"workbench.productIconTheme": "fluent-icons",
"workbench.iconTheme": "vscode-icons",
"workbench.editor.enablePreview": false,
"powermode.enabled": true,
"liveServer.settings.donotShowInfoMsg": true,
"explorer.compactFolders": false,
"bracketPairColorizer.excludedLanguages": [""],
"php.validate.executablePath": "F:\\xampp\\php\\php.exe",
@humayunahmed8
humayunahmed8 / cf7-template.html
Last active Feb 5, 2022
Subscription Form Contact Form 7
View cf7-template.html
<div class="row justify-content-center align-items-center">
<div class="col-xl-7 col-md-7">
<div class="newsletter-content">
<h5>Get notified of exclusive deals</h5>
[acceptance acceptance-566 default:on] I agree to subscribe to the Mydeals newsletter. See our <a href="https://example.com/privacy-policy">Privacy Policy</a> [/acceptance]
</div>
</div>
<div class="col-xl-5 col-md-5">
<div class="subscription-form">
[email* email placeholder "Enter email address"]
@humayunahmed8
humayunahmed8 / metabox-and-options.php
Created Feb 3, 2022
Social Media Links Shortcode using Codestar Repeater Field.
View metabox-and-options.php
<?php if ( ! defined( 'ABSPATH' ) ) { die; }
function mydeals_theme_shortcode_options($options){
$options = array();
}
add_filter('cs_shortcode_options', 'mydeals_theme_shortcode_options');
function mydeals_theme_customizer($options){
$options = array();
}