Skip to content

Instantly share code, notes, and snippets.

View jdelia's full-sized avatar

Jackie D'Elia jdelia

View GitHub Profile
@jdelia
jdelia / searchbar-snippet
Last active August 29, 2015 14:08
Winning Agent Search Bar Widget on Homepage only
// Add search widget below header.
add_action( 'genesis_after_header', 'wap_search_bar' );
function wap_search_bar() {
// only run if we are on the home page
if ( is_front_page() ) {
genesis_widget_area( 'search-bar', array(
'before'=> '<div class="search-bar"><div class="wrap">',
'after' => '</div></div>',
) );
}
// Add search widget below header.
add_action( 'genesis_after_header', 'wap_search_bar' );
function wap_search_bar() {
genesis_widget_area( 'search-bar', array(
'before'=> '<div class="search-bar"><div class="wrap">',
'after' => '</div></div>',
) );
}
@jdelia
jdelia / winning-agent-pro-home-welcome-shading
Last active August 29, 2015 14:14
Winning Agent Theme - Shading the home-welcome message
.home-welcome .widget-wrap {
background-color: rgb(0, 0, 0);
background-color: rgba(0, 0, 0, .4);
padding: 30px;
}
/* AgentPress Listings
--------------------------------------------- */
.home .listing-wrap:hover .listing-text,
.home .listing-wrap:hover .listing-price,
.home .listing-wrap:hover .listing-address,
.home .listing-wrap:hover .listing-city-state-zip,
.home .listing-wrap:hover .listing-wrap .more-link {
display: none;
}
@jdelia
jdelia / 0_reuse_code.js
Last active August 29, 2015 14:18
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@jdelia
jdelia / genesis-site-title-styles.css
Last active August 29, 2015 14:19
genesis-site-title-styles.css
/* An example of how you can style each word */
/* Uncomment this if you want to remove the space between words
*
.site-title {
font-size: 0;
}
*/
/* Font size for all the span tags */
@jdelia
jdelia / style-after.css
Last active August 29, 2015 14:19
Fix for AgentPress Featured Listings on Winning Agent Pro
.home-featured-1,
.home-featured-2,
.home-featured-3,
.home-listings .featured-listings .entry {
float: left;
margin-bottom: 0;
margin-right: 60px;
min-height: 140px;
text-align: center;
width: 340px;
@jdelia
jdelia / functions.php
Last active August 29, 2015 14:20
Add Link to Widget Area in Toolbar
<?php
//* Do NOT include the opening php tag
// Adds a Widget link to the Toolbar
add_action( 'admin_bar_menu', 'toolbar_link_to_widget_page', 999 );
function toolbar_link_to_widget_page( $wp_admin_bar ) {
$args = array(
'id' => 'my_widget_page',
'title' => 'My Widgets',
'href' => '/wp-admin/widgets.php',
.home .search-bar {
padding-top: 350px;
}
@media only screen and (max-width: 1023px) {
.home .search-bar {
padding-top: 250px;
}
}
@jdelia
jdelia / genesis-agent-profiles-extended-custom.php
Last active August 29, 2015 14:22
Genesis Agent Profiles Archive Page - Sort Randomly and Show Up to 999 agents per page
<?php
//* Do NOT include the opening php tag
// Force Sorting on the archive profiles page defaults to random up to 999 per page.
add_action( 'pre_get_posts', 'aeprofiles_change_sort_order_extended_custom', 20 );
function aeprofiles_change_sort_order_extended_custom( $query ) {