Skip to content

Instantly share code, notes, and snippets.

@bluedognz
bluedognz / simple-user-listing.php
Created December 22, 2017 05:01
Simple User Listing (with search)
<?php
/*
Plugin Name: Simple User Listing
Plugin URI: http://cozmoslabs.com
description: >-
Create a simple shortcode to list our WordPress users.
Author: Cristian Antohe
Version: 0.1
Author URI: http://cozmoslabs.com
*/
@bluedognz
bluedognz / style.css
Created December 20, 2017 02:11
H1,2,3 responsive CSS snippet
/** GLOBAL SMALL DEVICE H1,2,3 FONT SIZES **/
@media (max-width: 768px) {
h1 {
font-size: 32px;
}}
@media (max-width: 768px) {
h2 {
font-size: 28px;
}}
@media (max-width: 768px) {
@bluedognz
bluedognz / 127.0.0.1 lockout fix
Last active January 31, 2018 20:44
All Logins come from the IP 127.0.0.1, so if a user locks the IP out, all users get locked out, as they all have the same IP address.Add this to wp-config.php file, just ABOVE the line:/* That’s all, stop editing! Happy blogging. */
/** Required Code for showing correct IP address */
if(isset($_SERVER['HTTP_X_FORWARDED_FOR'])) {
$xffaddrs = explode(',',$_SERVER['HTTP_X_FORWARDED_FOR']);
$_SERVER['REMOTE_ADDR'] = $xffaddrs[0];
}
@bluedognz
bluedognz / microthemer
Last active July 27, 2018 10:40
Microthemer remove snippet
/* Begin Microthemer Code */
if (!defined('MT_IS_ACTIVE')) {
function add_microthemer_css() {
$p = get_option('preferences_themer_loader');
$mtv = '?mtv=' . (!empty($p['version']) ? $p['version'] : 1);
$mts = '?mts=' . (!empty($p['num_saves']) ? $p['num_saves'] : 0);
if (!empty($p['g_fonts_used'])){
$google_url = !empty($p['g_url_with_subsets']) ? $p['g_url_with_subsets']
: !empty($p['gfont_subset']) ? $p['g_url'].$p['gfont_subset'] : $p['g_url'];
$h = 'microthemer_g_font'; wp_register_style($h, $google_url, false); wp_enqueue_style($h);
@bluedognz
bluedognz / shrink-row hide.css
Last active July 14, 2017 15:43
Use this code to hide rows on scrolled state with the Beaver Themer. Assign bdw-hide-scrolled class name to the row or module you want hidden.
/** HIDE HEADER ROWS OR MODULES ON SCROLLED STATE **/
.fl-theme-builder-header-shrink .bdw-hide-scrolled {
display: none;
}
@bluedognz
bluedognz / shrink-row shadow.css
Last active July 14, 2017 14:30
CSS to apply a subtle drop shadow to the Beaver Themer fixed header
/** ADD A DROP SHADOW TO BEAVER THEMER HEADER SHRINK ROW **/
.fl-theme-builder-header-scrolled {
-webkit-box-shadow: 0 3px 3px 0 rgba(0, 0, 0, 0.2);
-moz-box-shadow: 0 3px 3px 0 rgba(0, 0, 0, 0.2);
box-shadow: 0 3px 3px 0 rgba(0, 0, 0, 0.2);
}
<?php get_header(); ?>
<div class="fl-content-full container">
<div class="row">
<div class="fl-content col-md-12">
<?php if(have_posts()) : while(have_posts()) : the_post(); ?>
<?php get_template_part('content', 'page'); ?>
<?php endwhile; endif; ?>
</div>
</div>