Skip to content

Instantly share code, notes, and snippets.

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

David Klhufek phirebase

🏠
Working from home
View GitHub Profile
cursor: pointer;
<script type="text/javascript">
jQuery(document).ready(function(){
jQuery(".hyper_this").on('click', function(){
window.location = "https://divinotes.com/free-premium-divi-theme-layouts/";
});
});
</script>
@jamesfosker
jamesfosker / functions.php
Last active November 5, 2021 02:36
Change the slugs of project post, project category and project tags, add this to your child theme functions.php, once you've changed the slug on line 5, 20 & 38, go to your dashboard and go setting/permalinks and just hit the save button to update the slugs
/*Change Project Post Type Slug*/
function ds_divi_modify_project_post_slug() {
return array(
'feeds' => true,
'slug' => 'new-slug', /*Change text between brackets*/
'with_front' => false,
);
}
add_filter( 'et_project_posttype_rewrite_args', 'ds_divi_modify_project_post_slug' );
@indikatordesign
indikatordesign / functions.php
Last active November 5, 2021 01:29
[Combine "Divi - Filterable Blog Module" with the "Events Manager" plugin]
<?php
// Here you can see how to combine "Divi - Filterable Blog Module" with the free plugin "Events Manager": https://wordpress.org/plugins/events-manager/
// Just add these snippets to your themes functions.php and change them according to your needs.
// Combine Event Manager with "Divi – Filterable Blog Module" by changing the $query_args
// If you use it like this, the sorting starts with the current event and past events will be hidden automatically
add_filter( 'dfbm_query_args_output', function( $query_args )
{
@yanknudtskov
yanknudtskov / wordpress-db-get-autoload-size.sql
Created October 18, 2017 12:33
This will show you the autoloaded data size, how many entries are in the table, and the first 10 entries by size. #optimization #database #mysql
SELECT 'autoloaded data in KiB' as name, ROUND(SUM(LENGTH(option_value))/ 1024) as value FROM wp_options WHERE autoload='yes'
UNION
SELECT 'autoloaded data count', count(*) FROM wp_options WHERE autoload='yes'
UNION
(SELECT option_name, length(option_value) FROM wp_options WHERE autoload='yes' ORDER BY length(option_value) DESC LIMIT 10)
@sheerun
sheerun / .bowerrc
Last active March 19, 2023 02:27
Proper .bowerrc file pointing to new Bower registry (if using legacy Bower version)
{
"registry": "https://registry.bower.io"
}
@seoagentur-hamburg
seoagentur-hamburg / .htaccess
Last active September 13, 2024 11:36
UPDATE 2024/03: Perfect .htaccess file for highspeed and security. You can use it for every WordPress-Website without problems. Highspeed and Security - testet on hundreds of Websites. If you are using a WordPress Multisite, change the last part of this file.
########################################################################
# OPTIMAL .htaccess FILE FOR SPEED AND SECURITY @Version 2.0.9 - 03/2024
# ----------------------------------------------------------------------
# @Author: Andreas Hecht
# @Author URI: https://seoagentur-hamburg.com
# License: GNU General Public License v2 or later
# License URI: http://www.gnu.org/licenses/gpl-2.0.html
########################################################################
.slippery:hover {
background-position: bottom center!important;
transition: background-position 5s linear 0s;
}
.slippery:hover {
background-position: bottom center!important;
transition: background-position 5s linear 0s;
}
@phirebase
phirebase / hide_admin_bar.php
Created May 17, 2017 15:15 — forked from franz-josef-kaiser/hide_admin_bar.php
Hide the admin bar with the click of a button in the WP admin UI
<?php
/**
* Plugin Name: "Hide Admin Bar"-Button
* Plugin URI: http://unserkaiser.com
* Description: Easier debugging when the error message is hidden behind the admin bar.
* Version: 0.1
* Author: Franz Josef Kaiser
* Author URI: http://unserkaiser.com
*/
// Prevent loading this file directly - Busted!