padding-bottom: 24px
margin-bottom: 24px
border-bottom: 1px solid #E3E4E7
- &-form .product-thumbnail
- width: 60px
- flex-shrink: 0
- img
- border-radius: 5px
+ &-form
+ .product-thumbnail
+ width: 60px
+ flex-shrink: 0
+ img
+ border-radius: 5px
+ &__cart-item
+ width: 100%
.product-name
line-height: normal
}
return true;
});
+
+add_filter('wc_get_template', function($template, $template_name, $args, $template_path, $default_path) {
+ if ($template_name === 'checkout/payment.php') {
+ $custom_template = get_stylesheet_directory() . '/woocommerce/checkout/payment.blade.php';
+ if (file_exists($custom_template)) {
+ return $custom_template;
+ }
+ }
+ return $template;
+}, 10, 5);
+
+add_action('woocommerce_before_add_to_cart_quantity', function(){
+ echo "<p class='grey-label label-quantity'>Quantité</p>";
+});
+
+add_filter('woocommerce_add_to_cart_redirect', function() {
+ $app = filter_input(INPUT_GET, 'app', FILTER_SANITIZE_STRING);
+ if ($app == "true") {
+ return wc_get_cart_url()."?app=true";
+ }
+ return wc_get_cart_url();
+});
+
+add_filter('woocommerce_get_return_url', function($return_url, $order) {
+ $app = filter_input(INPUT_POST, '_app', FILTER_SANITIZE_STRING);
+ return add_query_arg('app', $app, $return_url);
+}, 10, 2);
<html @php(language_attributes()) class="no-js" data-app="<?php echo $app == 'true' ? esc_attr('on'): '' ?>">
@include('partials.head')
{{-- When not using the hero image header template the compact header is set --}}
- <body @php(body_class( (is_page_template('views/template-transparent-header.blade.php') ? '' : 'header-compact')))>
+ <body @php(body_class((is_page_template('views/template-transparent-header.blade.php') ? '' : 'header-compact')))>
<!-- Google Tag Manager (noscript) -->
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-M3NHJ8X"
@php(do_action('get_header'))
@include('partials.header')
+ @if($app == "true")
+ @include('partials.header-mobileapp')
+ @endif
<div class="wrap container" role="document">
<div class="content">
<main class="main">
<h2 class="woocommerce-cart-summary-card__title"><?php esc_html_e( 'Cart totals', 'woocommerce' ); ?></h2>
@php($app = filter_input(INPUT_GET, 'app', FILTER_SANITIZE_STRING))
<?php if($app == "true") { ?>
-
<div class="woocommerce-cart-summary-card">
<div class="cart-subtotal">
<div class="label"><?php esc_html_e( 'Subtotal', 'woocommerce' ); ?></div>
- <div data-title="<?php esc_attr_e( 'Subtotal', 'woocommerce' ); ?>"><?php wc_cart_totals_subtotal_html(); ?></div>
+ <div data-title="<?php esc_attr_e( 'Subtotal', 'woocommerce' ); ?>">
+ <?php wc_cart_totals_subtotal_html(); ?>
+ </div>
</div>
<?php foreach ( WC()->cart->get_coupons() as $code => $coupon ) : ?>
</div>
<?php }else{ ?>
-
<table cellspacing="0" class="shop_table shop_table_responsive">
<tr class="cart-subtotal">
<div class="product-subtotal" data-title="<?php esc_attr_e( 'Subtotal', 'woocommerce' ); ?>">
<p class="label"><?php esc_attr_e( 'Subtotal', 'woocommerce' ); ?></p>
<?php
- echo apply_filters( 'woocommerce_cart_item_subtotal', WC()->cart->get_product_subtotal( $_product, $cart_item['quantity'] ), $cart_item, $cart_item_key ); // PHPCS: XSS ok.
+ echo str_replace(')','',str_replace('(',' ',apply_filters( 'woocommerce_cart_item_subtotal', WC()->cart->get_product_subtotal( $_product, $cart_item['quantity'] ), $cart_item, $cart_item_key ))); // PHPCS: XSS ok.
?>
</div>
<?php do_action( 'woocommerce_cart_contents' ); ?>
</div>
<?php
if ( ! wp_doing_ajax() ) {
+ $app = filter_input(INPUT_GET, 'app', FILTER_SANITIZE_STRING); ?>
+ <input type="hidden" name="_app" value="<?php echo esc_attr($app) ?>">
+ <?php
do_action( 'woocommerce_review_order_after_payment' );
}
--- /dev/null
+<?php
+/**
+ * Single Product title
+ *
+ * This template can be overridden by copying it to yourtheme/woocommerce/single-product/title.php.
+ *
+ * HOWEVER, on occasion WooCommerce will need to update template files and you
+ * (the theme developer) will need to copy the new files to your theme to
+ * maintain compatibility. We try to do this as little as possible, but it does
+ * happen. When this occurs the version of the template file will be bumped and
+ * the readme will list any important changes.
+ *
+ * @see https://woocommerce.com/document/template-structure/
+ * @package WooCommerce\Templates
+ * @version 1.6.4
+ */
+
+if ( ! defined( 'ABSPATH' ) ) {
+ exit; // Exit if accessed directly.
+}
+
+the_title( '<h1 class="product_title entry-title hide-on-mobileapp">', '</h1>' );