Add Coupon Code Box to Be visible on Mobile

👍 Gathering votes
Greg Writer

On Mobile, the coupon box is hidden under the order summary and should be visible to the user.

4 months ago

Activity
Abdul Kahar (Kay)

that is a must as for me there are more mobile customers than

0    1 month ago    Reply

Comment must be at least 20 characters.
Cancel

We love to listen to our customers.

Studyofmemesbook

I made a workaround for this by adding some text to the cart page that warns of the need to view the order summary; add this to the cart custom code section:

<script>

document.addEventListener('DOMContentLoaded', function () {
    // Find the element
    var subtotalElement = document.querySelector('h2.h6.mb-3.pb-1');

    // Check if the element exists
    if (subtotalElement) {
        // Create a new element for the additional text
        var newElement = document.createElement('div');
        newElement.innerHTML = '<i>Proceed to checkout and view order summary to apply any coupons</i>';
        newElement.style.fontSize = 'small'; // Set the font size to small
        newElement.style.fontStyle = 'italic'; // Set the style to italic

        // Insert the new element after the subtotal element
        subtotalElement.parentNode.insertBefore(newElement, subtotalElement.nextSibling);
    }
});

</script>

0    3 months ago    Reply

Comment must be at least 20 characters.
Cancel

We love to listen to our customers.

Joshua changed status to 👍 Gathering votes

4 months ago

Categories
Store Appearance