How to create a mini shopping car: 3 methods

Are you looking for a simple way

to set up a WoOOCOMMERCE mini shopping cart [123 123 ]? If your checkout experience is slow and repeated, it may affect the customer’s shopping experience. The process of improving the checkout process is an indispensable part of improving the conversion rate of potential customers, and mini shopping carts may be a good solution. Therefore, in order to help you add a website to your website, there is a guide to how

how to create a WoOOCOMMERCE mini shopping cart.

But first of all, let’s see what is a mini -handed cart, and why you may need to use a mini -handed cart. What is Woocommerce mini shopping cart?

Your WoOOCOMMERCE mini shopping cart is just a small form of your actual WordPress shopping cart page. It contains products added to the shopping cart and more details.迷你购物车的内容取决于您的活动WordPress 主题,但它们通常包括:

[123 ] Your product list

    Tip

  • Product shrinkage map

  • Product number

  • Detailed information displayed by your woocommerce mini shopping cart How, it is an important part of your customer user experience when you browse the Woocommerce store. This is an easy -to -access tool. Your customers can use it to move directly from any part of your website to the checkout page, and help track the shopping cart project.

Even we also use mini carts in Quadlayers. If you add the product to the shopping cart, you can check the mini shopping cart by hovering in the shopping cart icon in the title menu.

If you look at the screenshot below, we have added the product Woocommerce Checkout Manager to the shopping cart. This is also displayed in the mini shopping cart with the quantity and trick.

Why create a mini shopping cart for your WOOCOMMERCE website? 创建 woocommerce 迷你购物车四层

By default, your WoOOCOMMERCE theme may have your own Woocommerce mini shopping cart.Even so, its position and style itself may not be completely customized from your theme settings. In addition, it may not be suitable for your mini cart.

Our readers may consider adding a floating mini shopping cart, and others may take them Add to the sidebar or footbar. You may consider using various possible mini shopping carts. In addition, you may also need to add more content to your mini shopping cart, such as freight, other shopping carts, custom messages, etc. The comfort when using the shopping cart is also important to increase the actual sales of you and your customers

. Fully conforms to the customization of your website aesthetics and sellable checkout can change your game rules of your Woocommerce website. Therefore, if you want to create a custom mini -shopping car and add it to different pages of the website, then there is nothing!

How to create a Woocommerce mini shopping cart in WordPress To create and add your Woocommerce mini shopping cart

,

You can use

3 different methods

123]:

Add a small part of the shopping cart Use the WordPress plug -in

Programming

  1. Let’s take a look at each method and the steps involved in all these methods, starting with the default method of using WordPress Widgets.

  2. 1. Use WordPress small components to create a Woocommerce mini shopping cart

  3. By default, you can use

WooCommerce shopping cart parts to create a WooCommerce mini shopping cart.

Since we use small components, it can only be positioned in the available small component area of \u200b\u200bthe theme. The most common areas include:

Small component sidebar

below

Pack

  • According to your theme, according to your theme, There are more small parts. But make sure you also use one of the topics compatible with Woocommerce.

  • 1.1. Select a small part area

  • To add a small part of the shopping cart, you need to choose a small part area first. therefore,Open your WP Admin Dashboard and turn to

Appearance \u0026 GT; widgets

. Then, you choose a small part area for your mini shopping cart.

For our demonstration, we will use Sidebar . But you can use the most convenient small component area.

1.2. Add the small parts of the shopping cart to the small component area After selecting a small part area for your mini shopping cart, click

+ Button

Add a small part. Search for a search bar for 创建 woocommerce 迷你购物车 - 小部件页面 shopping cart

and click it to add a small component with

.

If you can’t see a small part, make sure you have set woocommerce correctly on your website. Here, you can also enable or disable If the shopping cart is empty, it hides the option . We recommend that you use it because if your customer’s shopping cart is empty, your side bar shopping cart will be hidden. This will also make your website look more practical.

After completing the addition of a shopping cart component,

Update Small components to save changes. Now, your side bar mini shopping cart should appear at your front end.

创建 woocommerce 迷你购物车 - 添加购物车截图

Of course, you can also add your mini shopping cart to different small component areas. Just choose the position under the small component page, you can easily add the small parts to the header or footer.

Although this is the creation of a woocommerce mini shopping cart [123 ] The easiest way , but it has a lot of restrictions . On the one hand, your mini shopping cart is not customized . You are very limited to the appearance of the mini shopping cart and how customers access it.

The location of the mini shopping vehicle is limited to the small component area provided by your theme. In addition, customers or website owners cannot use the custom fields such as pop -up mini shopping carts or shopping carts. Therefore, if you want a more customized mini shopping cart, we recommend that you continue to read and consider the following methods. 创建 woocommerce 迷你购物车 - 标题购物车

2. Use WORDPRESS plug -in to create woocomMerce mini shopping cart

using WordPress plug -in is one of the easiest ways to manage your shopping cart experience. You can make sure your customers can easily check out at any time with the help of the plug -in. They also allow you to simplify the checkout experience of the website.

Mini shopping cart plug -in provides beautiful features to promote your product sales and improve your potential customers Essence For example:

You can use the hovering car icon and pop -up window for the mini shopping cart. Therefore, your customers can access them at any time while keeping the cleaning and non -interference of other contents of the store. Many shopping carts and product elements can be added to the mini shopping car itself. For example, additional product information, changes, edit shopping carts and total display, etc. You can add some intelligent features through the plug -in, such as adding coupons, special specialty products and recommendation product suggestions directly from the mini shopping car.

Therefore, we strongly recommend using WordPress plug -ins, which is specially used to add and customize the Woocommerce mini shopping cart.

For our demonstration, we will use

    Woocommerce Cart All in One plug -in

  • . It is one of the best plugins for creating a mini shopping cart on your website. The plug -in is also very easy to use and has all the functions you need, such as a mini shopping cart pop -up window, a side bar shopping cart or a menu shopping cart custom option.

We also listed the best Woocommerce mini shopping Car plug -in. If you want to use any other plug -in, you can also look at it.

2.1. Install and activate the plug -in Let us start with the installation and activation plug -in. Open your WP management instrument panel , and then turn to the

plug -in \u0026 gt on the sidebar; add a new

.

Then, use the search bar in the upper right corner to search for

Cart all in one for woocommerce

.

After finding the plug -in, click to install it immediately to install the plug -in. Finally, after installation activation plug -in.

创建 woocommerce 迷你购物车 - 安装插件页面

If you want to use advanced plug -ins, you must upload and install manually. Check out the detailed guidelines for our manual installation of the WordPress plug -in to get more information.

Now, we need to configure the plug -in to enable your Wooocommerce mini shopping cart.

2.2. Configure the shopping cart in the WooCommerce plug -in

To configure the plug -in woocommerce mini shopping cart, please click WP Admin dashboard Cart All in one tab . This will open the dashboard page of the plug -in.

创建 woocommerce 迷你购物车 - 安装和激活插件

In the free version of the plugin, you can enable [ 123] Sidebar Mini Cart or Menu mini cart

. You can also add and configure AJAX to add to the shopping cart, but we only pay attention to the mini shopping cart option now.

To activate the mini shopping car pop -up window on your website, please open the side bar shopping car and click to enable . You can also use to enable the

option to enable/disable the mini shopping cart on the mobile device to pop up the window. Finally,

Save 创建 woocommerce 迷你购物车 - 购物车多合一 Your change.

Now, go back to the front end of your website. You should see a new mini shopping car icon on the webpage. You only need to click it to turn on your mini shopping cart.

In addition, you can also add menu to any menu. Just open the menu shopping cart tab like the previous steps and enable it. If necessary, you can also use it on the mobile menu. Next, you need to add the WordPress menu to display the menu shopping cart on your website. Just select the menu for the \”menu\” field to be added to the Woocommerce mini shopping cart . Then click

Save

.

You should now see your menu mini shopping cart on your website. It will be added to the menu you choose for a mini shopping cart.

2.3. Use the plug -in to customize your Woocommerce mini shopping cart Customization is CART ALL in ONE plugin

Features. You can freely customize the sidebar shopping cart and menu shopping cart. This includes color, mini shopping cart style, location, custom animation, mini shopping car icon, side -bar dish style style, and so on.

To access the custom option, transfer to the appearance \u0026 gt; custom on the WP management dashboard. You will be redirected to your theme customizer. Here, click Shopping car all in one for woocommerce , you should see all mini shopping cart custom options.

For this demonstration, we will customize the side barons shopping vehicle. So, click

Sidecart Cart

, you should see all its options. Now, we will use to display the sidebar

content options to enable a smaller mini shopping cart and change the location of the shopping cart in the sidebar of

.

But you can use these options to further customize your mini shopping cart. How it is suitable for your website. There are also many places that need to be edited, such as interaction with the shopping car icon itself, so when you hang the icon, a mini shopping cart will appear, custom loading icons, and so on.

创建 woocommerce 迷你购物车 - 购物车定制

After completing the change, click

Publish Save them. You will be able to see all these custom settings of your mini shopping cart on your website. This is the basic point of using a plug -in to customize the mini shopping cart. If you want to know more information about all customized options provided by the plug -in, we strongly recommend that you read their documents .

3) Create a woocommerce mini shopping cart by programming

Assuming you don’t want to use a plug -in to add your WooComerce Mini shopping cart to maintain the lightweight framework of your website. Then you can also choose to create one by programming. This will require you to use a custom function to create custom short generationCode and paste it to the theme Functions.php

file. You can then use a short code on any part of the website, and you can even add it to any WordPress or Woocommerce template file to directly add a Woocommerce mini shopping cart.

Since we will change some core files, it is best to back up your website and create a sub -theme by programming or using one of the sub -theme plugins. This ensures that you will not lose the custom code when updating the WordPress theme.

创建 woocommerce 迷你购物车 - 购物车定制风格 3.1. Add custom simplified code to your theme function

We will add custom code to the theme files of your website through the theme file editor. If you are not satisfied with adding code to Woocommmerce, we recommend that you read this article first. After preparing, on

wp admin Use the sidebar of the theme file on the right, and then click

Functions.php . This will open the Functions.php file on your theme editor.

Now, paste the following code into your theme editor:

Function Custom_mini_cart () {echo \u0026#39; \u0026 lt; a href \u003d \u0026quot;#\u0026quot; class\u003d\u0026quot;dropdown-back\u0026quot; data-toggle\u003d\u0026quot;dropdown\u0026quot;\u0026gt; \u0026#39;;echo \u0026#39;\u0026lt;i class\u003d\u0026quot;fa fa-shopping-cart\u0026quot; aria-hidden \u003d \u0026 quot; true \u0026 quot; \u0026 gt; \u0026 lt;/i \u0026 gt; \u0026#39;; Class \u003d \u0026 Quot; CART-ITEMS-COUNT Count \u0026 Quot; \u0026 GT; \u0026#39; Echo WC ()-\u0026 GT; CART- \u0026 GT_CONTENTS_COUNT (); #39; \u0026 lt/;/;/div \u0026 gt; \u0026#39;; echo \u0026#39; \u0026 lt;/a \u0026 gt; \u0026#39; echo \u0026#39; \u0026 lt; ul class \u003d \u0026 quot; dropdown-menu dropdown-mini-cart \u0026 quot; #39;;echo \u0026#39;\u0026lt;li\u0026gt; \u0026lt;div class\u003d\u0026quot;widget_shopping_cart_content\u0026quot;\u0026gt;\u0026#39;;woocommerce_mini_cart();回声\u0026#39;\u0026lt;/div\u0026gt;\u0026lt;/li\u0026gt;\u0026lt; /ul \u0026 gt; \u0026#39;} Add_shortcode (\u0026#39; Quadlayers-mini-cart \u0026#39;, custom_mini_cart \u0026#39;); Add add After the code, click

to update

file

. This will create a custom short code called

\”[Quadlayers-mini-cart]\”

. Now, you can use this short code on any post, page, or small component to add your custom woocommerce mini shopping cart.

3.2. Use a short code in the Woocommerce template You can also use the following code fragment to add your custom mini shopping cart to any theme template file or the Woocommerce template. \u0026 lt; php echo do_shortcode (\u0026#39; [quadlayers-mini-cart] \u0026#39;); \u0026 gt; For example, let us add this code to your WooCommerce product In the archive template file. To open your WOOCOMMERCE template file, transfer from your WordPress dashboard to

plug -in \u0026 gt; plug -in file editor

. 创建 woocommerce 迷你购物车 - 功能 php

 Then, use 

Select plugin to edit

in the upper right corner and select woocommerce

and click

Select. Use the plug-in file menu, click template \u0026 gt; Archive-PRODUCT.PHP.

Next, add the following code to any appropriate part of the template.

 Echo Do_shortcode (\u0026#39; [Quadlayers-mini-cart] \u0026#39;) 

For our demonstration, we will be do_action (\u0026# 39; woocommerce_before_main_content \u0026#39;)

;

. But you can add code fragments on any template file and where you need.

Finally, add code to the plug -in editor Update file . The mini shopping cart will be displayed on the WoOOCOMMERCE page you specified. In our example, it is the “SHOP/Product Archive page. This method will add your mini shopping cart to the template. However, the appearance of a mini shopping cart may not fully meet your requirements

, and you may need to use the theme file style table for additional style settings. Therefore, it is recommended to use this method when you are accustomed to coding and have the knowledge of adding PHP and CSS to WordPress.

Reward: How to skip the shopping cart page in WooCommerce

If you want your customers to have a faster checkout process, you can also choose to completely

skip the shopping cart Page

. Since the mini shopping cart has been provided to your customers, the demand for the shopping cart page is not great. Therefore, you can redirect it directly to the checkout page when the customer wants to buy. 

You can do this by using a special plug -in or using a custom function. Now, we will introduce how to skip the shopping cart page by programming. But before continuing, you need to transfer from the WP instrument board to WooCommerce \u0026 GT; Set and open the

product

tab. Under the conventional

option, two

are disabled to add to the shopping car behavior option . This ensures that our custom functions will not be disturbed.

Now, use the same steps as the above steps again to open your sub -theme Functions.php file. Just turn from

appearance \u0026 gt; theme file editor to the theme editor, then click fuNCTIONS.PHP

file.

Then, paste the following code fragments here.

add_filter(\u0026#39;add_to_cart_redirect\u0026#39;, \u0026#39;ql_skip_cart_page\u0026#39;);功能ql_skip_cart_page () {全球$woocommerce;$redirect_checkout \u003d $woocommerce-\u0026gt;cart-\u0026gt;get_checkout_url( );返回$redirect_checkout;}

现在,每次您的客户将产品添加到您的购物车时,他们都会被直接带到结帐页面,而Not their shopping cart page. In order to simplify this process, you can also use plugins such as Direct Checkout for Woocommerce. If you want to know it and why you consider using it, you can view our dedicated guide here. Conclusion

This is our guide for how

Create a mini shopping cart in Woocommerce. Setting and custom WOOCOMMERCE Mini Shopping Cars is not a tedious process. You can choose to use different methods to do this. Let us summarize the method we use in today’s guide to add and customize our Woocommerce mini shopping cart:

Use shopping cart parts Use a dedicated WordPress plug -in Use a brief code and template file with a programming method

If you are not sure which process you want Woocommerce mini shopping cart. This method is not only safer and easier, but you can also obtain a large number of special customization and personalized options for your mini. If you are a primary scholar of WordPress and want to add a mini shopping cart with the least restrictions, we strongly recommend that you use a special plug -in.

 

In addition, if you are looking for other methods to shorten the checkout process and increase sales, why not read other articles:

Jia Plug -in

How to create WOOCommerce one page to checkout

How to create a direct check -in link to create a woocommerce

So can you now add a mini shopping cart on your website?Or have you added it?We are glad to understand it in the comments.

Author:

Leave a Reply

Your email address will not be published. Required fields are marked *