opencart使⽤教程_您的第⼀个使⽤OpenCart的电⼦商务商
店,第1部分
opencart使⽤教程
Creating an online shop is as easy as A, B, C with the availability of so many open-source e-commerce platforms. In less than five minutes, you can create your very own online storefront like Amazon and offer physical and digital products for sale.
拥有众多开放源代码电⼦商务平台,创建在线商店就像A,B,C⼀样容易。 在不到五分钟的时间内,您可以创建⾃⼰的在线店⾯(如亚马逊),并提供实体和数字产品进⾏销售。
OpenCart is a robust e-commerce solution for Internet merchants giving them the ability to create their own online presence and participate in e-commerce at a minimal cost.
OpenCart是⾯向互联⽹商⼈的强⼤的电⼦商务解决⽅案,使他们能够以最低的成本创建⾃⼰的在线业务并参与电⼦商务。
In this two-part series I’ll explain all of the necessary steps to create your own e-commerce site with OpenCart. In this article I’ll start with its installation.
在这个由两部分组成的系列⽂章中,我将解释使⽤OpenCart创建⾃⼰的电⼦商务⽹站的所有必要步骤。 在本⽂中,我将从其安装开始。OpenCart功能 (OpenCart Features)
OpenCart is a powerful, open source shopping cart system that is designed to be feature rich and user friendly. Some of its features worth checking out include:
OpenCart是⼀个功能强⼤的开源购物车系统,旨在具有丰富的功能和⽤户友好性。 它值得⼀试的⼀些功能包括:
Open Source The best thing about OpenCart is that it is free to download and use. There is no need for you to worry about licensing cost for using it. And if you ever make modifications to the OpenCart source code, you can share them back with the OpenCart developers so the community at large can benefit from them too.
开源关于OpenCart的最好的事情是可以免费下载和使⽤。 您⽆需担⼼使⽤它的许可成本。 ⽽且,如果您曾经修改过OpenCart源代码,则可以与OpenCart开发⼈员共享这些代码,以便整个社区也可以从中受益。
Unlimited Categories/Products/Manufacturers In an online store one would need to have unlimited Categories, products
and manufacturers. In OpenCart you can create unlimited number of Categories for your products, add unlimited number of products to your store and add unlimited number of manufacturers.
⽆限的类别/产品/制造商在⼀家在线商店中,需要具有⽆限的类别,产品和制造商。 在OpenCart中,您可以为您的产品创建⽆限数量的类别,为您的商店添加⽆限数量的产品,并添加⽆限数量的制造商。
Guest Shopping/Checkout There are times you want to order a product online on an online store and don’t want to
register before you can buy any goods. OpenCart allows guest shopping and checkout which enables a customer to add goods to their shopping cart, pay for the goods and checkout without them registering.
访客购物/结帐有时候,您想在⽹上商店在线订购产品,⼜不想注册,然后再购买任何商品。 OpenCart允许客⼈购物和结帐,这使客户可以将商品添加到他们的购物车中,为商品付款和结帐,⽽⽆需注册。
To learn more about OpenCart, be sure to visit their website at .
要了解有关OpenCart的更多信息,请确保访问其⽹站 。
安装OpenCart (Installing OpenCart)
To install OpenCart, you first need to and download the latest version of the software. OpenCart comes as a ZIP archive, so afterwards you have to extract the archive’s contents into a folder of your choosing.
要安装OpenCart,您⾸先需要并下载该软件的最新版本。 OpenCart是ZIP归档⽂件,因此之后,您必须将归档⽂件的内容提取到您选择的⽂件夹中。
After extracting it, you’ll see a folder called upload and three text files , ,
解压缩后,您将看到⼀个名为upload的⽂件夹和三个名为 , 和⽂本⽂件。
mysql下载之后是个文件夹 file contains installation notes, contains the GNU General Public License under which OpenCart is released, contains instructions for upgrading an earlier version of OpenCart to the latest version if you’re already using it. The upload directory contains the f
iles you need to upload to your web host.
<⽂件包含安装说明, ⽂件包含发布OpenCart的GNU通⽤公共许可证, 包含有关将OpenCart的较早版本升级到最新版本的说明(如果已在使⽤)。 upload⽬录包含您需要上载到Web主机的⽂件。
Copy all the files and folders found in the upload folder to the public directory of your web host. The name of the public directory may vary depending on your host and configuration, but usually it’s named something like public_html.
将在上upload⽂件夹中到的所有⽂件和⽂件夹复制到Web主机的公共⽬录中。 公共⽬录的名称可能会因您的主机和配置⽽异,但通常使⽤诸如public_html之类的名称。
After copying the files, you need to make sure the following files and directories are writable:
复制⽂件后,需要确保以下⽂件和⽬录可写:
image/ image/cache/ image/data/ system/cache/ system/logs/ download/ config.php admin/config.php
image/ image/cache/ image/data/ system/cache/ system/logs/ download/ config.php admin/config.php
To make them writable, make sure the file’s permissions are 666 (rw-rw-rw) and directory permissions are 777 (rwxrwxrwx). You can do this with the chmod command if you have shell access, or easily through your host’s cPanel install.
要使其可写,请确保⽂件的权限为666(rw-rw-rw),⽬录权限为777(rwxrwxrwx)。 如果您具有外壳程序访问权限,则可以使⽤chmod命令执⾏此操作,也可以轻松地通过主机的cPanel安装来执⾏此操作。
To do this in cPanel, all you need to do is go the directory that you uploaded your OpenCart files to, right click on each of the file and folder choose “Change Permissions” for the pop up box.
要在cPanel中执⾏此操作,您所需要做的就是转到将OpenCart⽂件上传到的⽬录,右键单击每个⽂件和⽂件夹,然后在弹出框中选择“更改权限”。
Now create a MySQL database with a new user created and attached to it.
现在,创建⼀个MySQL数据库,并创建并附加⼀个新⽤户。
To create a MySQL database, you’ll need to login to your database backend. If it’s a shell, you can then use the CREATE DATABASE command and create a user with appropriate access privileges with GRANT.
要创建MySQL数据库,您需要登录到数据库后端。 如果是外壳,则可以使⽤CREATE DATABASE命令并使⽤GRANT创建具有适当访问权限的⽤户。
If you’re using phpMyAdmin, under Create New Database enter the name of the database you want to create and click on the Create Button. Then to attach a new user to the newly created database, click on the Privileges tab at the top and then click on the the Add New User button. Enter the username, host (most likely “local”), and your chosen password twice. Under the Database then for the user select the None option. Under Global privileges click on the check all link.
如果您使⽤的是phpMyAdmin,请在“创建新数据库”下输⼊要创建的数据库的名称,然后单击“创建”按钮。 然后要将新⽤户附加到新创建的数据库,请单击顶部的“权限”选项卡,然后单击“添加新⽤户”按钮。 输⼊⽤户名,主机(很可能是“本地”)和您选择的密码两次。 在数据库下,然后为⽤户选择⽆选项。 在“全局特权”下,单击“检查所有”链接。
After you have done all this, you should open the storefront in a browser to begin the installation wiza
rd. The exact URL will depend on where you’ve uploaded the files; for example, if you’ve uploaded the files to public_html then you would open your domain, ample. If you’ve created public_files/store and uploaded the files there, then you would ample/store.
完成所有这些操作后,应在浏览器中打开店⾯以开始安装向导。 确切的URL将取决于您将⽂件上传到何处。 例如,如果您已将⽂件上传到public_html,则可以打开域,如ample 。 如果您已创建public_files/store并将⽂件上传到那⾥,则可以打
开ample/store 。
After you have visited the URL of where you uploaded your OpenCart files, you will be shown the first step which is “Step 1 – License”. All you need to do here is accept the GNU General Public License by ticking “I agree to the License” after which you click on the continue button.
访问了您上传OpenCart⽂件的URL后,将显⽰第⼀步,即“步骤1 –许可”。 您需要做的就是通过勾选“我同意许可证”来接受GNU通⽤公共许可证,然后单击继续按钮。
The next step is “Step 2 – Pre-Installation”. The pre-installation screen displays all the installation requirements, and PHP settings and extensions. It would also check whether the correct permissions are set for the files and directories. If there are no errors, you can click on the continue button.
下⼀步是“步骤2 –预安装”。 预安装屏幕显⽰所有安装要求以及PHP设置和扩展名。 它还将检查是否为⽂件和⽬录设置了正确的权限。如果没有错误,您可以单击继续按钮。
The next step is “Step 3 – Configuration”. This is where you enter the database host, the username and password of the MySQL user you created earlier, and the database name.
下⼀步是“步骤3 –配置”。 在这⾥,您可以输⼊数据库主机,之前创建MySQL⽤户的⽤户名和密码以及数据库名称。
The next three options, Username, Password, and Email, are for the admin account. This is where you enter the username, password, and email address that you will be using to login to the administrative backend.
接下来的三个选项,⽤户名,密码和电⼦邮件,⽤于管理员帐户。 在此输⼊⽤于登录管理后端的⽤户名,密码和电⼦邮件地址。
A screenshot of the “Step – 3 Configuration” screen is shown below.
下⾯显⽰了“ Step – 3 Configuration”屏幕的屏幕截图。
After you click on the continue button, you’ll be shown the final step, “Step 4 – Finished”. Seeing this means that you have successfully installed OpenCart.
单击继续按钮后,将显⽰最后⼀步,“步骤4 –完成”。 看到这表⽰您已经成功安装了OpenCart。
After the wizard is completed, you should delete the install directory from your server. This is the “installation directory”noted in the final wizard screen.
向导完成后,应从服务器中删除install⽬录。 这是最终向导屏幕中记录的“安装⽬录”。
OpenCart installs a sample store during installation, and this is how the sample storefront looks:
OpenCart在安装过程中会安装⼀个样本商店,这是样本商店的外观:
But in this article I’m going to delete all of the products, categories, and attributes and do everything anew so that you can see how they are created.
但是在本⽂中,我将删除所有产品,类别和属性,并重新进⾏所有操作,以便您可以看到它们的创建⽅式。
配置商店 (Configuring Your Store)
One of the joys of having your own online store is being able to add your own products and set their prices. To do all, first you need to login in to the administrative back-end and set up a few categories to keep things organized.
拥有⾃⼰的在线商店的乐趣之⼀就是能够添加⾃⼰的产品并设置其价格。 为此,⾸先,您需要登录到管理后端,并设置⼀些类别来使事情井井有条。
To access the administrative back-end, go ample/admin. Log in with the username and password you provided to the install wizard and you will be taken to the Administration Dashboard.
要访问管理后端,请访问ample/admin 。 使⽤您提供给安装向导的⽤户名和密码登录,
您将被带到管理控制台。
The Administration Dashboard shows a lot of useful information about your store. The overview pane
shows a summary of your total sales, orders, number of customers, etc. The Statistics pane shows a graph of your orders and customers. The Latest 10 Orders pane shows you the 10 most recent orders from your store.
管理仪表板显⽰有关商店的许多有⽤信息。 概述窗格显⽰了总销售额,订单,客户数量等的摘要。“统计”窗格显⽰了订单和客户的图表。 “最近的10个订单”窗格显⽰了您商店中的最近10个订单。
Let’s delete the existing categories, products, and attributes so you can start setting up your own inventory. The first piece of data to delete is the existing categories.
让我们删除现有的类别,产品和属性,以便您可以开始设置⾃⼰的库存。 要删除的第⼀条数据是现有类别。
To delete all the categories, select Catalog > Categories from the top menu. A list of all of the defined categories will be displayed.
要删除所有类别,请从顶部菜单中选择⽬录>类别。 将显⽰所有已定义类别的列表。
Tick the checkbox at the top left of the listing table next the Category Name label to select all of the categories at once, and then click the Delete button in the top left corner to delete them. A confirmati
on box will be displayed to confirm the action.
勾选清单表左上⽅的复选框,然后单击类别名称标签以⼀次选择所有类别,然后单击左上⾓的删除按钮将其删除。 将显⽰确认框以确认操作。
Then, repeat the process for the products list (Catalog > Products), attributes list (Catalog > Attributes > Attributes),
attribute groups (Catalog > Attributes > Attribute Groups), and manufacturers list (Catalog > Manufacturers).
然后,对产品列表(⽬录>产品),属性列表(⽬录>属性>属性),属性组(⽬录>属性>属性组)和制造商列表(⽬录>制造商)重复该过程。
Now it’s time to start adding your own data into OpenCart!
现在是时候开始将⾃⼰的数据添加到OpenCart中了!
创建⾃⼰的类别 (Creating Your Own Categories)
Categories are classification of related products. For example, the IPhone 5, Blackberry 9800, and Samsung S2 are all products that could be classified as SmartPhones. In OpenCart you can create an unlimited number of categories and sub-categories to organize your products how you see fit.
类别是相关产品的分类。 例如,iPhone 5,Blackberry 9800和Samsung S2都是可以归类为智能⼿机的产品。 在OpenCart中,您可以创建⽆限数量的类别和⼦类别,以按照您认为合适的⽅式组织产品。
To create your own categories, navigate to Catalog > Categories. Click the Insert button on the categories page and you’ll see this form:
要创建⾃⼰的类别,请导航⾄⽬录>类别。 单击类别页⾯上的插⼊按钮,您将看到以下表格:

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。