Skip to content

Instantly share code, notes, and snippets.

@amdrew
Last active August 29, 2015 14:18
Show Gist options
  • Save amdrew/af020756a063580341fb to your computer and use it in GitHub Desktop.
Save amdrew/af020756a063580341fb to your computer and use it in GitHub Desktop.
Cleans up the display of cross-sells and up-sells within the Marketify theme
/**
* Fix styling in the Marketify theme
*/
function sumobi_edd_csau_fix_styles() {
if ( ! ( is_singular( 'download' ) || edd_is_checkout() ) ) {
return;
}
?>
<style>
.entry-content .edd-csau-products .edd_download_purchase_form { border: none; padding-bottom: 0; margin-bottom: 0; }
.entry-content .edd-csau-products .edd_download_purchase_form:last-of-type { margin-top: 0; }
.entry-content .edd-csau-products .edd_purchase_submit_wrapper { margin-top: 0; }
</style>
<?php
}
add_action( 'wp_head', 'sumobi_edd_csau_fix_styles' );
// turn add to cart button for cross-sells off, marketify has it's own add to cart buttons in the popup
add_filter( 'edd_csau_upsell_show_button', '__return_false' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment