Skip to content

Instantly share code, notes, and snippets.

View ayoubkhan558's full-sized avatar
🏠
Working from home

Muhammad Ayoub Khan ayoubkhan558

🏠
Working from home
View GitHub Profile
@ayoubkhan558
ayoubkhan558 / gist:4e8370d92db2e2ed970e116525275f7b
Last active May 18, 2025 17:54
Bricks Builder UI/Skin/Editor Tweaks
[data-builder-mode=custom] {
--builder-bg: #1a1a1a;
--builder-bg-2: #222222;
--builder-bg-3: #2c2c2c;
--builder-bg-accent: #33334d;
--builder-color: #f0f0f0;
--builder-color-description: #bbbbbb;
--builder-color-accent: #6c63ff;
--builder-color-accent-inverse: #ffffff;
@ayoubkhan558
ayoubkhan558 / Yup conditional validation
Created April 26, 2024 03:33
How to validate two fields that depend on each other with Yup
# How to validate two fields that depend on each other with Yup
```js
const schema = yup.object().shape({
propCategory: yup.object().shape({
label: yup.string().required(),
value: yup.string().required(),
icon: yup.string().required(),
}),
@ayoubkhan558
ayoubkhan558 / gist:fb05f4ef59f5e747813a616e59af89ca
Created December 12, 2023 06:03
Show ACF repeater fields from Product categories in tag taxonomy archive page
<?php
// Get the current category ID
$category_id = get_queried_object_id();
$term = get_queried_object();
$repeaterField = get_field('category_faq', 'product_cat_' . $category_id);
// Check if repeater field has values
if ($repeaterField) :
echo '<ul class="accordion accordionjs">';
$counter = 1;
@ayoubkhan558
ayoubkhan558 / gist:cec3901541952152aeffd53d4ef042ef
Created December 12, 2023 06:03
Show ACF repeater fields from Product taxonomy in tag taxonomy archive page
<?php
// Get the current tag
$tag = get_queried_object();
// Check if the tag exists
if ($tag) {
// Get ACF repeater field values for the current tag
$repeaterField = get_field('product_tag_faq', 'product_tag_' . $tag->term_id);
{
"basics": {
"name": "John Doe",
"label": "Programmer",
"image": "",
"email": "[email protected]",
"phone": "(912) 555-4321",
"url": "https://johndoe.com",
"summary": "A summary of John Doe…",
"location": {
@ayoubkhan558
ayoubkhan558 / gist:2c9d5d91a582fd37ed2c6a62df9423f3
Last active August 2, 2022 09:05
Pakistan cities for Developers List.html
<select name="city" id="city">
<option value="Abbottabad">Abbottabad</option>
<option value="Adezai">Adezai</option>
<option value="Ahmadpur East">Ahmadpur East</option>
<option value="Ahmed Nager Chatha">Ahmed Nager Chatha</option>
<option value="Akora Khattak">Akora Khattak</option>
<option value="Ali Bandar">Ali Bandar</option>
<option value="Ali Khan Abad">Ali Khan Abad</option>
<option value="Alipur">Alipur</option>
<option value="Alpuri">Alpuri</option>
https://www.simonewebdesign.it/demo/html5editor/
Simone Web Design
Home Blog Projects About
How to make a real-time in-browser editor with the HTML5′s contenteditable attribute
Apr 20th, 2013
Lots of fun here. Some days ago I just read a very cool comment on html5doctor:
1: Install Java JDK 8
2: Install Ionic 4 globaly through NPM
3: Install Gradle
Installing Gradle manually
https://gradle.org/next-steps/?version=5.5&format=bin
Step 1. Download the latest Gradle distribution
Step 2. Unpack the distribution
@ayoubkhan558
ayoubkhan558 / wp-bootstrap-5-comment-walker.php
Created April 22, 2022 14:20 — forked from ayoubkhan558-zz/wp-bootstrap-5-comment-walker.php
A custom WordPress comment walker class to implement the Bootstrap 5 Card in WordPress comment list.
<?php
/**
* A custom WordPress comment walker class to implement the Bootstrap 3 Media object in wordpress comment list.
*
* @package wp-bootstrap-5-comment-walker
* @version 1.0.0
* @author Ayoub Khan <[email protected]>
* @license MIT
Animate.css, wow.js (aoa.js),
-- # Faviorite Fonts
Roboto, Raleway,
"Segoe UI","Helvetica Neue","Helvetica",Arial,sans-serif
-- # Plugins
// Animation Libraries