Thursday, 29 September 2016

Fix API Issues on Opencart

For this tutorial, I will be showing you how to fix the problem 'Warning: Your IP is not allowed to access this API!' To fix this problem I will be using my opencart dashboard.

API Issue.

First, you will need to add you IP to your API, to do this you need to go on to your opencart dashboard. Click on settings on the left-hand panel, in the drop down menu click users and then API.

Dashboard - Settings [1] - Users [2] - API [3].

You need to add a new API (blue button with plus sign), there are three tabs but we will only be focusing on two:
General
  • API Name - Create a name to call your API (i have used my own name)
  • API Key - Under the large blank box is a blue button with the word generate, click this and the blank box will fill with the API Key.
  • Status - This needs to be enabled.
IP Addresses
  • IP - In this table you will need to add your IP address, click the add button and put your IP in the field provided. If you do not know your IP it will be showing in the box above the IP table.

If you refresh your dashboard the problem will still be showing, now you will need to access your settings (Dashboard - System - Settings).

Dashboard - System [1] - Settings [2].

Your store settings need editing, when you enter the settings there will be several tabs across the top of the page, you will need to click on the option tab. Scrolling through the options section you need to find checkout. Go to the bottom of the checkout section and find API User, in the box next to this option should be --- None --- , click on this and will show a drop down menu. In the drop down menu will be the API name that you created previously, select this. Save this change and you will not have the API issue again. 

Sam    



Wednesday, 28 September 2016

Change Homepage SEO URL Opencart

This tutorial will be showing you how to change your opencart store homepage SEO URL. For this, I will be using my open cart dashboard and my cPanel file manager.

Homepage URL.

Go on your opencart dashboard, on the left-hand panel find system, once you have clicked on system you will see a menu underneath and you will need to click on settings
Dashboard - System [1] - Setting [2].

Once in the settings you will see several tabs at the top of the screen, you will need to click on server. Under the section general, you will see an option called 'use SEO URL's' this will be set to no, it needs  to be changed to yes. Click save and that's all for the dashboard.


Now to access your cPanel File Manager, you need to find seo_url.php (public_html/catalog/controller/common/seo_url.php). This file needs editing, once open find the line return $link; (line 128), Above this line add $link = str_replace('index.php?route=common/home', '', $link);. Your file will now look like this:

return $url_info['scheme'] . '://' . $url_info['host'] . (isset($url_info['port']) ? ':' . $url_info['port'] : '') . str_replace('/index.php', '', $url_info['path']) . $url . $query;
} else {
$link = str_replace('index.php?route=common/home', '', $link);
return $link;

Save this, refresh your store page and the URL will have changed.

With the change
Sam.


Add Featured Products Opencart

This tutorial will show you how to add featured products to the home page on your opencart store. For this I will be using my opencart dashboard, you will need to access your modules this is found in the left-hand panel on your dashboard under extensions. 


Dashboard - Extensions [1] - Modules [2].

This will show you a module list, scroll down the list until you find the module name Featured > Home Page, click on edit (blue button with a pencil icon). To edit the featured module you will ned to change and add a few things:

  • Module Name: I changed this to featured products, you can change this to what you would like to change the name too. 
  • Products: Add the products that you would like to feature, to do this just type the name of the product into the product box, this will add it to the box below.
  • Limit: I left this at the default 5.
  • Width: I also left this as the default recommended, 200.
  • Height: I kept the default, 200. 
  • Status: Set this to enabled. 
Save this module. 

Featured Module.
Now the module is created you will need to add it to your homepage, to do this you need to go back to your opencart dashboard. On the left-hand panel click on design then on the drop down menu click layout.

Dashboard - Design [1] - Layout [2].
This will bring you to the layout list, scroll through the list until you find the layout name home, click on edit. There will be a few options:
  • Layout Name: Leave this as Home.
  • Store & Route: Leave this to what it is set at.
  • Module: This is what you will need to edit. Click on the add module (blue button with a plus sign). In the module section, click on the drop down box and find the module you have just made (featured > featured product). In the section position, you need to set the position you want it to be on your homepage (I have selected top). In the sort order column, I have set this to 1.  
Save the changes.

Layout.
Once you have done this check your store to make sure it has worked. Remember to back up your store.


Final Look.



Sam




Thursday, 22 September 2016

Remove Ex Tax from Products in Opencart.

For this tutorial I will be showing you how to remove the ex-tax from products, for this, I will be using my opencart dashboard. 

What I want to remove.

You will need to access your opencart dashboard, on the left-hand panel click on system, this will show you a drop-down menu and you will need to click on settings. 

Dashboard - Systems [1] - Settings [2].

You will need to edit your store's settings when in the settings click on the option tab. Then scroll down to taxes, underneath will be an option for display prices with tax. Set this to no and save the changes. Refresh your store and the ex-tax will be removed from product pages. 

Sam.


Create a Product in Opencart.

For this tutorial, I will be showing you how to add products to your opencart store. I will be using my opencart dashboard. On the dashboard select catalog on the left-hand panel, this will show a drop-down menu, then click on products.

Dashboard - Catalog [1] - Products [2].

This will bring you to the product list, to add a new product click on add new (blue button with plus sign). There will be 11 tabs for the add new product, the main ones to fill in are:


General
  • Product Name - What the name of the product will be.
  • Description -  Describe the product.
  • Meta Tag Title - What will appear in the web pages header.
  • Product Tags - Keywords to group and categorise products together.
Data
  • Image - Image of the product.
  • Model - Model/Make information.
  • Price - How much you're selling the item for.
  • Quantity - How many items you have in stock.
  • Minimum Quantity - Lowest amount a customer has to buy.
  • Requires Shipping - Does the item need to be shipped.
  • Status - This need to be enabled. 
Links
  • Categories - Which category the item will be placed under.
  • Downloads - Add the item if it is a downloadable product. 

These fields need to be filled in before you can save the product. Once saved refresh your store and check the product is displayed correctly.
Sam

Tuesday, 20 September 2016

Add a Category and Sub-Category in Opencart

For this tutorial I will be showing you how to add categories to your opencart store, for this, I will be using my opencart dashboard. You will need to click on catalog in the left-hand panel, this will show you a drop-down menu and you will then need to click on categories. 

Dashboard - Catalog [1] - Catergories [2].

The page will show a category list, I have deleted all previous categories that were there for demo purposes. You will need to add a new category (blue plus icon).  What to add to a new category:

General
  • Category Name - This is the name you want to show on your nav bar.
  • Meta Tag Title - This is the name that will show in the header.
Data
  • Top - Ensure this is ticked to display this category in the nav bar.
  • Status - Make sure this is enabled.
Category


Create a Sub-Category.

To create a sub-category you need to stay on the category list, create a new category like before (blue plus sign).  For this, you will need to fill the category name and meta tag title as you did when creating the category for the nav bar. However, the data tab will be filled in differently you do not need to tick the top box for a sub-category. There will be a field at the top of the page called parent, this is where you will choose which category the sub-category will be in, also ensure that the status is set to enable.

Sub-Category
Sam.






Sunday, 18 September 2016

Remove Slideshow from Opencart.

For this tutorial, I will be removing the slideshow from you opencart store. For this, I will be using my opencart dashboard.

Slideshow.

To remove the slideshow you need to access your opencart dashboard and click on extensions, this will show you a drop-down menu, then click modules.

Dashboard - Extensions [1] - Modules [2].

Scroll down the modules list until you find Slideshow>Homepage, uninstall this (red bin). 

Uninstall Slideshow>Homepage.
Now the slideshow on your opencart will be gone, obviously, the homepage will look bare. I have installed the modules featured product, best seller and latest product (all can be found in the module list). To use these on your home page install them (green plus) and edit (blue pencil) them and make sure the status is set to enable otherwise they will not show.

Sam



Wednesday, 14 September 2016

Edit Stores Information on Opencart.

This tutorial will be showing you how to edit your opencart's information section, this includes about us, delivery information, privacy policy, terms and conditions. To do this you will be using your opencart dashboard. To find the information section you will need to click on catalog on the left-hand side panel on your dashboard, this will show you a drop down menu and you need to click on information.

Dashboard - Catalog [1] - Information [2]
Once you are on your Information page you will see a list of pages that you will need to edit (blue pencil).

About Us Page - This needs to be filled in with information about your business and give a little bit of information about yourself, make it interesting, tell a story and personalise your writing.


Delivery Information - Tell customers how long it will be before the items are shipped from your location, cover prices, which company will be posting the items, how long it will take for the posting company to deliver and what happens if a customer orders on a Sunday or a bank holiday weekend.


Privacy Policy - A statement or a legal document that discloses some or all of the ways a party gathers, uses, discloses, and manages a customer or client's data. It fulfils a legal requirement to protect a customer or client's privacy. Shopify offer a privacy policy template at https://www.shopify.co.uk/tools/policy-generator.


Terms and Conditions - Terms of service are rules, that one must agree to abide by in order to use a service. Terms of service can also be merely a disclaimer. Shopify also offer a free template at https://www.shopify.co.uk/tools/policy-generator/terms-and-conditions.



Sam

Tuesday, 13 September 2016

Disable Countries in Opencart

In this tutorial I will be showing you how to disable countries in your opencart store in bulk, for this I will be using my opencart dashboard and cPanel phpmyadmin. The countries that you will be disabling will not show in the customer registration form or on the guest checkout of your shopping cart. 

When you go on your opencart dashboard click on system in your left hand panel, this will show a dropdown menu. You will then need to click on localisation, this will show you another drop down menu, then click on countries.


Dashboard - System [1] - Localisation [2] - Countries [3].


When you go on to countries on your opencart dashboard there are 13 pages, you can delete 20 at a time or go through each country on your dashboard and disable them one by one. I prefer to disable them rather than deleting them, just in case i need to use them at a later date. Rather than going through each country on the list to disable it, I am going to use my phpmyadmin to disable them all. Go on your cPanel and search for phpmyadmin. 
phpmyadmin.

Once you are in your phpmyadmin, you will need to choose your database, once you have done this you will need to scroll down your structure list and find oc_country and click on it to open. Once you have opened it along the top of the page you will see several options, you need to click on SQL. Type the SQL statement UPDATE country SET status=0 and click go. This will disable all the countries, click on browse (next to SQL and structure) you will see all the county status have changed to 0 (meaning disabled). 


SQL.

Now go back to your dashboard and on the country list, find which country you want to show on your opencart. Once you have found it click edit, scroll down to status and enable and save. Make sure you test your opencart registration and guest checkout to ensure that the country you have enabled is the only one showing.


Enable Status.
Sam






Friday, 9 September 2016

Setting Up Your Google Analytics On Opencart.

For this tutorial, I will be showing you how to set up your Google Analytics on your opencart store. I will be using my opencart dashboard and my Google Analytics account. First, you need to access your opencart dashboard and click on extensions, this will show a drop down menu and you need to click on analytics. 


Dashboard - Extensions [1] - Analytics [2].

This will bring you to the analytics list, in the list you will see Google Analytics. You need to install this (green box with a + symbol), once installed click on edit (blue pencil icon).

 
When in edit you will see two boxes Google Analytics code and status. You need to fill the Google Analytics box with your code and make sure the status box is enabled.
I have seen a few people adding their Tracking ID to the Google Analytics code, like so:


Tracking ID
However, when you do this, this will happen:

Tracking ID
Your Tracking ID appears in the top left side of your store, this is because the code that you need to enter into the google analytics box is not the Tracking ID. To get the correct code you need to access you google analytics account, got to Admin - Property - Tracking Info - Tracking Code. Underneath the Tracking ID is a section called website tracking, this is the code you need to copy into your dashboard.

Google Analytics.
Once you have entered the website tracking code your analytics extension will look like this:

Analytic Extension.

Now your Google Analytics will work with your store and the Tracking ID will not be showing in the top left-hand corner of your store.


Tracking ID is now gone.

Sam.






  

Thursday, 8 September 2016

Setting Up Shipping On Opencart.

For this tutorial, I will be showing you how to set up shipping on your opencart store. I will have priced shipping on orders below £20 and free shipping on orders above £20. To do this I will be using my opencart dashboard and my cPanel file manager.

First, you will need to go to your opencart dashboard, on the left-hand panel you need to click on extensions, this will show a drop down menu, you will need to click on shipping.

Click extensions [1], then click shipping [2].
Once on the shipping page, you will see a shipping list, the only two shipping methods I will be installing are flat rate and free shipping.

Install flat rate and free shipping.

When you have installed both click on edit (pencil icon) on the flat rate shipping. Here you will change some of the settings.

Flat Rate Shipping.
Cost - How much do you want to charge for shipping.
Tax Class - I have this set to none, when I was setting a tax class it would automatically alter my postage cost.
Geo-Zones - What zones does this shipping apply too.
Status - This needs to be set to enabled.
Sort Order - What place this method should be.

Flat Rate Shipping Settings.

Once you have saved this go back to your shipping list and click edit (pencil icon) on free shipping. Now to edit the settings.

Free Shipping
Total - This is how much the cart must add up to before free shipping is available.
Geo-Zones - What zones is the shipping option available too.
Status - Make sure this is enabled. 
Sort Order - What place this shipping method should be.

Free shipping settings.


Click Save.  If an order is over £20.00 both the free shipping and flat rate shipping is showing, to change this you need to access your cPanel file manager. 

Both flat rate shipping and free shipping are showing.

Once in your cPanel you will need to find flat.php (public_html/catalog/model/shipping/flat.php), find the line $method_data = array(); (line 16). Underneath this line add
if ($this->cart->getSubTotal() > $this->config->get('free_total')) {
         $status = FALSE;
      }   

Once you have add this line, the section will look like this:

$method_data = array();
if ($this->cart->getSubTotal() > $this->config->get('free_total')) {
         $status = FALSE;
      }   

if ($status) {


Click save and check your store to see if it has worked.

Orders under £20.

Orders over £20.
Sam.








Set Up Paypal For Your Opencart Store.

For this tutorial I will be showing you how to set up paypal for your opencart store. For this I will be using my opencart dashboard and my cPanel file manager. First you need to access your opencart dashboard, on the left hand side panel you will need to click on extensions, this will show a drop down menu and you will need to click on payments.


Click on extensions [1] then on payments [2].
Once you are on the payments extensions you will need to scroll down the payments list until you find paypal payments standard. You will need to install this then click on edit (pencil icon).

Paypal Payments Standard.

Once you are in edit you can change the settings according to what you need.


General.
Email - This is your paypal email address.
Sandbox - Use live or testing (sandbox) gateway.
Debug Mode - Logs additional information. 
Transaction Method - Change this to sale.
Total - the minimum amount before the store accepts payment.
Geo-Zone - What zones you will accept orders from.
Status - Ensure this is enabled.

General Settings.

For the order status settings I matched the drop down box to the order status name.

Order Status.

Once you have done this go to your stores cart and there will be a payment option available.


Payment available.
However, I wanted the payment option to say 'Pay by Debit/Credit Card or Paypal'. To change this you need to access your cPanel file manager and find the file pp_standard.php (public_html/catalog/language/english/payment/pp_standard.php, one in this file change $_['text_title']    = 'Paypal'; (line 3) to Pay by Debit/Credit Card or Paypal. The file should now look like this: 

<?php
// Text
$_['text_title'] = 'Pay by Debit/Credit Card or Paypal';
$_['text_testmode'] = 'Warning: The payment gateway is in \'Sandbox Mode\'. Your account will not be charged.';
$_['text_total'] = 'Shipping, Handling, Discounts & Taxes';

Now your payment method will be set up, make sure you test your store.

Final Result.


Sam.




Change the Colour of the Hover Button on Opencart

Hovering over the search button.
For this tutorial, I will be showing you how to change the colour of a button when you hover over it on opencart. The reason I am changing the colour is because when I hover over the button the colour flickers between grey and blue. I will be using my cPanel file manager to change this.


Hovering over the add to cart button. 














To change this or fix the issue you need to access your stylesheet.css (public_html/catalog/view/theme/default/stylesheet/stylesheet.css). Once in this file you need to find .btn-primary:hover (on line 427), i changed the background-color to grey (you can change this to any colour). Then add border-color: #d9d9d9 #d9d9d9 #d9d9d9; (change this to the colour you want), add this underneath background colour. This part of your stylesheet should look like this:

}
.btn-primary:hover, .btn-primary:active, .btn-primary.active, .btn-primary.disabled, .btn-primary[disabled] {
background-color: #F2F2F2;
border-color: #d9d9d9 #d9d9d9 #d9d9d9;
background-position: 0 -15px;

Save your changes and refresh your store's website. 

Add to cart.

Search bar.













Sam. 










EDIT: When I was testing my store I noticed on the checkout page that the continue buttons flickered blue on click (these were the only ones that hadn't changed). If you come into this problem don't worry. To fix this you need to access your cPanel file manager and find buttons.tlp (public_html/catalog/view/theme/default/template/common/buttons.tlp). Once in this file find <a href="<?php echo $button['link']; ?>" class="btn btn-primary"><?php echo $button['text']; ?></a> (line 4), underneath add <a href="#" onclick="this.style.background='#f2f2f2';">Watch me change!</a>. Now the file should look like this:

<?php foreach ($buttons as $button) { ?>
      <a href="<?php echo $button['link']; ?>" class="btn btn-primary"><?php echo $button['text']; ?></a>
      <a href="#" onclick="this.style.background='#f2f2f2';">Watch me change!</a>

    <?php } ?>

Sorry for not noticing this sooner!