How can I change the destination of the "Back to Shop" button?

In the following, the button target of the “Back to Shop” button is changed so that this is returned to the last page. For this, the following change must be made in the cart-empty.php.

if ( wc_get_page_id( 'shop' ) > 0 ) : ?>
  <p class="return-to-shop">
    <a href="#" onclick="window.history.go(-1); return false;">
      <?php _e( 'Zurück', 'woocommerce' ) ?>
<?php endif; ?>
Without cookies
This website does not use cookies or tracking. More information can be found in the privacy policy.