Skip to content

Instantly share code, notes, and snippets.

define('PHOTOCRATI_ALL_GOOGLE_FONTS', TRUE);
/*-----NAVIGATION-----*/
.menu ul li ul {
border-top: 2px solid #000;
}
/*-----SIDEBAR------*/
.widget-area ul ul li { /*removes bottom-border only*/
border-bottom: 0px;
}
.widget-area ul ul li { /*returns list back to bullet style*/
@scottwyden
scottwyden / gallery-download.php
Created June 7, 2013 18:15
NextGEN Gallery Voting & Download Template
@scottwyden
scottwyden / AddTo-Style.css
Last active December 11, 2015 11:38
Print CSS for Photocrati Dynamic CSS Option
@media only print
{
body:after { content: "Please consider the environment and don't waste paper."; }
#sidebar, #menu_wrapper, #nav-below, #respond {display: none;}
}
@scottwyden
scottwyden / gist:9d0a6b274c71bc65d033
Created December 10, 2015 14:39
Display 1 Random Image With NextGEN Gallery
[ngg_images gallery_ids="1,3" display_type="photocrati-nextgen_basic_singlepic" sort="rand()"]
@scottwyden
scottwyden / gist:73676bb8b07eb2fb7a70
Created October 2, 2015 15:01
Another 5 CSS Snippets to Customize NextGEN Gallery
/** Pro Grid Album Caption */
.nextgen_pro_grid_album > div > a.caption_link {
font-family: courrier;
}
/** Center NextGEN Widget images in Sidebar - the key is to set a specific width */
div.ngg-widget.entry-content {
width: 200px;
margin-left: auto;
margin-right: auto;
@scottwyden
scottwyden / gist:fbc9cfd4e425a5a60f3b
Created October 2, 2015 14:58
5 More CSS Snippets to Customize NextGEN Gallery
/** Increase the default trigger icon sizes */
.fa-shopping-star::before,
.fa-shopping-cart::before,
.fa-share-square::before,
.fa-comment::before {
font-size: 20px;
}
/** Reduce space between Album title and number of photos */
.ngg-album-compact h4 .ngg-album-desc {
@scottwyden
scottwyden / gist:aad7e5f9eed3e3130f3d
Created October 2, 2015 14:46
5 CSS Snippets to Customize NextGEN Gallery
/** Left align and set maximum width for ImageBrowser display */
.ngg-imagebrowser { max-width: 600px; float: left; margin-right: 10px; }
/** Highlight active image (read: stage image) in NextGEN Pro Lightbox carousel */
.galleria-image.active { border: 10px white solid; }
/** Add border and drop-shadow to slideshows */
.slideshow object { border: 10px black solid; box-shadow: 10px 10px 5px red; }
/** Customize the colors of the proofing start icon trigger */
@scottwyden
scottwyden / Clickjacking—The Most Widely Overlooked Web App Vulnerability?
Created August 11, 2015 17:56
Snippet example for an article at Pivot Point Security
<style id="antiClickjack">body{display:none !important;}</style>
<script type="text/javascript">
if (self === top) {
var antiClickjack = document.getElementById("antiClickjack");
antiClickjack.parentNode.removeChild(antiClickjack);
} else {
top.location = self.location;
}
</script>
@scottwyden
scottwyden / gist:9555926ae344d3e8f512
Created March 27, 2015 13:49
Photocrati Theme Attachment Page Mods in Functions.php
// Attachement Page Modifications
add_action('generate_rewrite_rules', 'attachment_rewrite_rule_14924');
function attachment_rewrite_rule_14924($wp_rewrite){
$new_rules = array();
$new_rules['attachment/(\d*)$'] = 'index.php?attachment_id=$matches[1]';
$wp_rewrite->rules = $new_rules + $wp_rewrite->rules;
}