Skip to content

Instantly share code, notes, and snippets.

@SeanChDavis
Last active January 21, 2016 19:29
Show Gist options
  • Save SeanChDavis/abdde2b52effd121dc4a to your computer and use it in GitHub Desktop.
Save SeanChDavis/abdde2b52effd121dc4a to your computer and use it in GitHub Desktop.
EDD Add Checkout Cart Item Permalinks
<?php // DO NOT COPY THIS LINE
/**
* The goal is to link the line items back to their original products from the checkout cart
*
* To override the checkout_cart.php file, see here: https://easydigitaldownloads.com/videos/template-files/
*/
// FIND:
echo '<span class="edd_checkout_cart_item_title">' . esc_html( $item_title ) . '</span>';
// REPLACE WITH:
echo '<a href="' . get_permalink( $item['id'] ) . '"><span class="edd_checkout_cart_item_title">' . esc_html( $item_title ) . '</span></a>';
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment