Skip to content

Instantly share code, notes, and snippets.

View larbous's full-sized avatar

Luiz Sobral larbous

View GitHub Profile
@frontend-coder
frontend-coder / Simple Jquery Accordion
Created August 12, 2019 06:11
Simple Jquery Accordion #accordion
<div>
<div class="acc-btn">Button 1</div>
<div class="acc-content">
Content 1
</div>
</div>
<div>
<div class="acc-btn">Button 2</div>
<div class="acc-content show">
Content 2
@mehrshaddarzi
mehrshaddarzi / metabox_order.php
Last active July 18, 2024 02:42
wordpress meta box order
<?php
// meta-box-order_toplevel_page_wps_overview_page
// metaboxhidden_toplevel_page_wps_overview_page
// closedpostboxes_toplevel_page_wps_overview_page
// meta-box-order_toplevel_page_wps_overview_page
// a:2:{s:4:"side";s:127:"wps_summary_postbox,wps_browsers_postbox,wps_referring_postbox,wps_users_online_postbox,wps_countries_postbox,wps_about_postbox";s:6:"normal";s:160:"wps_hits_postbox,wps_top_visitors_postbox,wps_search_postbox,wps_searched_phrases_postbox,wps_words_postbox,wps_recent_postbox,wps_map_postbox,wps_pages_postbox";}
#==========================================
# Exemplo de crontab para listas grandes com mais de 5 mil leads
#
# Neste exemplo damos um tempo para que
# cada tarefa tenha tempo de ser executada
# antes da próxima tarefa entrar em execução
#===========================================
# atualiza as listas nos minutos 1 e 30
@kierzniak
kierzniak / functions.php
Last active March 8, 2024 15:19
Remove accents from url slug before WordPress search for a post
<?php
/**
* Remove accents from url slug before WordPress search for a post
*
* When you access page with accents you will not find any posts because
* WordPress is removing accents from url before saving it to database.
* This function will remove accents from url before WordPress start looking
* for post.
*
@strangerstudios
strangerstudios / pmpro-customizations.php
Last active December 5, 2023 12:19
A blank plugin file for customizations to your Paid Memberships Pro setup.
<?php
/*
Plugin Name: PMPro Customizations
Plugin URI: https://www.paidmembershipspro.com/wp/pmpro-customizations/
Description: Customizations for my Paid Memberships Pro Setup
Version: .1
Author: Paid Memberships Pro
Author URI: https://www.paidmembershipspro.com
*/
@lukecav
lukecav / functions.php
Last active March 13, 2025 12:48 — forked from eteubert/wordpress-passwort-reset-unmultisite.php
WordPress Multisite: Password Reset on a Subsite.
/**
* Password reset on sub site (1 of 4)
* Replace login page "Lost Password?" urls.
*
* @param string $lostpassword_url The URL for retrieving a lost password.
* @param string $redirect The path to redirect to.
*
* @return string
*
* @since 1.0.0
@ChgoChad
ChgoChad / commands.php
Last active January 5, 2024 22:18 — forked from escopecz/commands.php
Script to run Mautic (https://mautic.org) commands from a URL.
<?php
if (!isset($_GET['ILoveMautic'])) {
echo 'The secret phrase is wrong.';
die;
}
$link = "https://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]";
$allowedTasks = array(
'cache:clear',
@ivanvermeyen
ivanvermeyen / !NOTE.md
Last active March 15, 2023 05:25
Setup a Laravel Storage driver with Google Drive API
@gstricklind
gstricklind / styles.css
Created December 10, 2016 18:39
Tabbed WooCommerce My Account
body.woocommerce-account .woocommerce-MyAccount-navigation ul {
margin: 0;
}
body.woocommerce-account .woocommerce-MyAccount-navigation ul li {
list-style: none;
}
body.woocommerce-account .woocommerce-MyAccount-navigation ul li a {
text-decoration: none;
}
/**
* @Title: WooCommerce Display Price and Add to Cart button for specific user role only from Shop and Single Product pages
* @Author: Mina Pansuriya
* @Website: http://minapansuriya.com
*/
if(is_user_logged_in() )
{
$current_user = wp_get_current_user();
foreach ( $current_user->roles as $role )
{