Editing the woocommerce cart page - wordpress

I am using woocommerce and would like to add a custom text to the cart page.
So I add a product to cart, go to the cart and in there I see that the cart uses the page.php template.
My theme folder is called woocommerce, then inside my theme folder I created a folder called woocommerce/templates/cart/cart.php
I added text to the new cart.php but it does not work.
How can I override the woocommerce cart page?
It is my first time using woocommerce so I really hope you can help
Thanks in advance

Create woocommerce/woocommerce/cart/cart.php , folder templates should not be there if you are using theme to override default woocommerce php's
See the article
Template structure & Overriding templates via a theme
https://docs.woocommerce.com/document/template-structure/

Related

Why wordpress don't see the archive-product page?

I installed my theme with just html, and woocommerce plugin.
I created in my theme directory woocommerce and inside a file archive-products.
In admin, in settings -> reading i choose as a static page the Shop.
But i saw just the page, not the archive-product page.
Where i done a mistake?
When i create a theme with underscores.me, i forgot to check a checkbox for woocommerce.
Now i create another theme with checked checkbox, and the theme work.

Woocommerce - different/individual page.php

i want to use a different navigation and some other individual codes for all WooCommerce pages.
For archive-product.php or content-single-product.php this is no problem. I used them in my themechild (theme-chiild/woocommerce). But for pages like cart or checkout its not working.
Is it possible to use a different page.php for all WooCommerce pages?
Cart and Checkout by default use your default page.php and just use a shortcode to generate the page content.
So you have a few options.
Modify page.php to check if it is cart/checkout
Create a custom page template for both that modifies what you need
Create a custom page template for each if you need different options on each
In Woocommerce > templates you do have cart/checkout templates as well
Depending on the level of customization. You may need to hook into those pages to add/remove what you need. https://docs.woocommerce.com/wc-apidocs/hook-docs.html

Editing WooCommerce coupon message

How do I correct/edit the alignment/contents of the coupon message (refer to the screenshot) that pops up when a user enters the coupon code at the cart checkout page in WordPress?
You need to find the template inside the woocommerce plugin's template folder.
Then create a woocommerce folder in your child theme, and copy the template there (same folder strucure).
Finally you make changes to your child theme's coupon template.
Read the comments for this file

Simple woocommerce checkout page

I want to make the woocommerce checkout page as simple as like attached image.
Payment method and cart section only, no customer details section.
How can customize the checkout page like this?
Modify the WooCommerce templates by copying them over to your child theme directory under the path child-theme/woocommerce/checkout. The main file is called form-checkout.php

WooCommerce custom checkout page in theme

Is it possible to create custom checkout page in my theme? I mean to create custom checkout.php document I do not want to edit WooCommerce default theme.
Yes, this is achieved by overriding the WooCommerce checkout.php file in the plugin itself by placing it in your theme's WooCommerce directory. You are right not to want to edit the plugin because any updates will render such changes obsolete. You can see the following files you would want to override here: https://github.com/woothemes/woocommerce/tree/master/templates/checkout
Your directory should look something as follows:
themeroot/
single.php
page.php
etc..
woocommerce/
templates/
checkout/
form-checkout.php
form-billing.php
etc
You can learn more about creating Custom WordPress themes by viewing the document. You will want to duplicate and work of these files to create your custom checkout page.

Resources