<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>OpenCart Archives - LinuxTuto</title>
	<atom:link href="https://www.linuxtuto.com/tag/opencart/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.linuxtuto.com/tag/opencart/</link>
	<description>Linux Sysadmin and DevOps blog</description>
	<lastBuildDate>Mon, 11 Jul 2022 15:02:29 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.1</generator>

<image>
	<url>https://www.linuxtuto.com/wp-content/uploads/2022/01/cropped-LT_faveicon-32x32.png</url>
	<title>OpenCart Archives - LinuxTuto</title>
	<link>https://www.linuxtuto.com/tag/opencart/</link>
	<width>32</width>
	<height>32</height>
</image> 
<site xmlns="com-wordpress:feed-additions:1">201456972</site>	<item>
		<title>How to Install OpenCart on Ubuntu 22.04</title>
		<link>https://www.linuxtuto.com/how-to-install-opencart-on-ubuntu-22-04/</link>
					<comments>https://www.linuxtuto.com/how-to-install-opencart-on-ubuntu-22-04/#comments</comments>
		
		<dc:creator><![CDATA[LinuxTuto]]></dc:creator>
		<pubDate>Mon, 11 Jul 2022 15:02:29 +0000</pubDate>
				<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[MariaDB]]></category>
		<category><![CDATA[OpenCart]]></category>
		<category><![CDATA[PHP]]></category>
		<guid isPermaLink="false">https://www.linuxtuto.com/?p=550</guid>

					<description><![CDATA[<p>OpenCart is a popular open-source and free to use content management system (CMS) designed for building online stores. It offers a lot of plugins that...</p>
<p>The post <a href="https://www.linuxtuto.com/how-to-install-opencart-on-ubuntu-22-04/">How to Install OpenCart on Ubuntu 22.04</a> appeared first on <a href="https://www.linuxtuto.com">LinuxTuto</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>OpenCart is a popular open-source and free to use content management system (CMS) designed for building online stores.</p>
<p>It offers a lot of plugins that help you to extend the platform’s functionality and includes features like user management, multi-store functionality, affiliates, discounts, multiple payment gateways, product reviews, and more.</p>
<p>In this tutorial, we will explain how to install and configure the OpenCart e-commerce platform on Ubuntu 22.04.</p>
<h2><span class="has-inline-color has-vivid-purple-color">Step 1: Update Operating System</span></h2>
<p>Update your <strong>Ubuntu</strong> <strong>22.04</strong> operating system to the latest version with the following command:</p>
<pre><code>$ sudo apt update &amp;&amp; sudo apt upgrade -y</code></pre>
<h2><span class="has-inline-color has-vivid-purple-color">Step 2: Install Apache webserver</span></h2>
<p>The Apache HTTP Server is a free and open-source cross-platform web server. You can install it via <code>apt</code> package manager by executing the following command.</p>
<pre><code>$ sudo apt install apache2</code></pre>
<p>You can start the Apache service and configure it to run on startup by entering the following commands:</p>
<pre><code>$ sudo systemctl start apache2
$ sudo systemctl enable apache2</code></pre>
<p>Verify the status of the <code>Apache</code> service using <code>systemctl status</code> command:</p>
<pre><code>$ sudo systemctl status apache2</code></pre>
<p>Output:</p>
<pre><code>● apache2.service - The Apache HTTP Server
     Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor preset: enabled)
     Active: active (running)
       Docs: https://httpd.apache.org/docs/2.4/
   Main PID: 2975 (apache2)
      Tasks: 55 (limit: 2200)
     Memory: 4.8M
        CPU: 137ms
     CGroup: /system.slice/apache2.service
             ├─2975 /usr/sbin/apache2 -k start
             ├─2977 /usr/sbin/apache2 -k start
             └─2978 /usr/sbin/apache2 -k start
</code></pre>
<h2><span class="has-inline-color has-vivid-purple-color">Step 3: Install PHP</span></h2>
<p>To install PHP and additional PHP modules to support OpenCart, run the following command:</p>
<pre><code>$ sudo apt-get install php php-cli libapache2-mod-php php-common php-mbstring php-gd php-intl php-xml php-mysql php-zip <span class="">php-curl php-xmlrpc</span></code></pre>
<p>Verify if PHP is installed.</p>
<pre><code>php -v</code></pre>
<pre><code>Output:
PHP 8.1.2 (cli) (built: Jun 13 2022 13:52:54) (NTS)
Copyright (c) The PHP Group
Zend Engine v4.1.2, Copyright (c) Zend Technologies
with Zend OPcache v8.1.2, Copyright (c), by Zend Technologies
</code></pre>
<h2><span class="has-inline-color has-vivid-purple-color">Step 4: Install MariaDB and create a database</span></h2>
<p>MariaDB is a free and opensource database engine that is flexible, robust and easy-to-use. To <a href="https://www.linuxtuto.com/how-to-install-mariadb-10-7-on-debian-11/">install MariaDB</a> run the following command:</p>
<pre><code>$ sudo apt install mariadb-server mariadb-client</code></pre>
<p>Verify the status of the <code>MariaDB</code> service using <code>systemctl status</code> command:</p>
<pre><code>$ sudo systemctl status mariadb</code></pre>
<p>Output:</p>
<pre><code>● mariadb.service - MariaDB 10.6.7 database server
     Loaded: loaded (/lib/systemd/system/mariadb.service; enabled; vendor preset: enabled)
     Active: active (running)
       Docs: man:mariadbd(8)
             https://mariadb.com/kb/en/library/systemd/
    Process: 26067 ExecStartPre=/usr/bin/install -m 755 -o mysql -g root -d /var/run/mysqld (code=exited, status=0/SUCCESS)
    Process: 26069 ExecStartPre=/bin/sh -c systemctl unset-environment _WSREP_START_POSITION (code=exited, status=0/SUCCESS)
    Process: 26072 ExecStartPre=/bin/sh -c [ ! -e /usr/bin/galera_recovery ] &amp;&amp; VAR= ||   VAR=`cd /usr/bin/..; /usr/bin/galera_recovery`; [ $? -eq 0 ]   &amp;&amp; &gt;
    Process: 26149 ExecStartPost=/bin/sh -c systemctl unset-environment _WSREP_START_POSITION (code=exited, status=0/SUCCESS)
    Process: 26151 ExecStartPost=/etc/mysql/debian-start (code=exited, status=0/SUCCESS)
   Main PID: 26109 (mariadbd)
     Status: "Taking your SQL requests now..."
      Tasks: 7 (limit: 2200)
     Memory: 61.3M
        CPU: 2.585s
     CGroup: /system.slice/mariadb.service
             └─26109 /usr/sbin/mariadbd</code></pre>
<p>By default, MariaDB is not hardened. You can secure MariaDB using the <code class=" prettyprinted"><span class="pln">mysql_secure_installation</span></code> script.</p>
<pre><code>$ sudo mysql_secure_installation</code></pre>
<p>Configure it like this:</p>
<pre><code>- Set root password? [Y/n] <strong>Y</strong>
- Remove anonymous users? [Y/n] <strong>Y</strong>
- Disallow root login remotely? [Y/n] <strong>Y</strong>
- Remove test database and access to it? [Y/n] <strong>Y</strong>
- Reload privilege tables now? [Y/n] <strong>Y</strong></code></pre>
<p>Now run the command below to log in to the MariaDB shell.</p>
<pre><code>$ sudo mysql -u root -p</code></pre>
<p>Once you are logged in to your database server you need to create a database for the OpenCart installation:</p>
<pre><code>MariaDB [(none)]&gt; CREATE DATABASE opencart;
MariaDB [(none)]&gt; CREATE USER 'opencart'@'localhost' IDENTIFIED BY 'Your-Strong-Password';
MariaDB [(none)]&gt; GRANT ALL PRIVILEGES ON opencart . * TO 'opencart'@'localhost';
MariaDB [(none)]&gt; FLUSH PRIVILEGES;
MariaDB [(none)]&gt; exit;</code></pre>
<h2><span class="has-inline-color has-vivid-purple-color">Step 5: Download OpenCart</span></h2>
<p>You can download the latest version of OpenCart from the Git repository using the following command:</p>
<pre><code>$ sudo wget https://github.com/opencart/opencart/releases/download/4.0.0.0/opencart-4.0.0.0.zip</code></pre>
<p>Then extract file into the folder <strong>/var/www/html/opencart/</strong> with the following command:</p>
<pre><code>$ sudo apt -y install unzip 
$ sudo unzip opencart-4.0.0.0.zip -d /var/www/html/opencart/</code></pre>
<p>Copy OpenCart configuration files:</p>
<pre><code>$ sudo cp /var/www/html/opencart/upload/{config-dist.php,config.php}

$ sudo cp /var/www/html/opencart/upload/admin/{config-dist.php,config.php}</code></pre>
<p>Enable permission for the Apache webserver user to access the files:</p>
<pre><code>$ sudo chown -R www-data:www-data /var/www/html/opencart/</code></pre>
<h2><span class="has-inline-color has-vivid-purple-color">Step 6: Create Virtualhost for Opencart</span></h2>
<p>Then, create an virtual host configuration file to host OpenCart:</p>
<pre><code>$ sudo nano /etc/apache2/sites-available/opencart.conf</code></pre>
<p>Paste the content as shown below:</p>
<pre><code>&lt;VirtualHost *:80&gt;
    ServerAdmin admin@your-domain.com
    DocumentRoot /var/www/html/opencart/upload/
    ServerName your-domain.com
    ServerAlias www.your-domain.com

    &lt;Directory /var/www/html/opencart/upload/&gt;
        Options FollowSymLinks
        AllowOverride All
        Order allow,deny
        Allow from all
    &lt;/Directory&gt;

    ErrorLog /var/log/apache2/your-domain.com-error_log
    CustomLog /var/log/apache2/your-domain.com-access_log common
&lt;/VirtualHost&gt;</code></pre>
<p>Remember to replace <strong><code>your-domain.com</code></strong> with the domain name of your server.</p>
<p>Save and exit the configuration file.</p>
<p>To enable this site run the command:</p>
<pre><code>$ sudo a2ensite opencart.conf</code></pre>
<p>To implement the changes, restart Apache webserver:</p>
<pre><code>$ sudo systemctl restart apache2</code></pre>
<h2><span class="has-inline-color has-vivid-purple-color">Step 7: Access OpenCart Web Interface</span></h2>
<p>To access the OpenCart Web Interface, go to your browser and visit <code>http://your-domain.com/</code>.</p>
<p>The first page displays the license agreement. Scroll down and click <strong>Continue</strong>.</p>
<p><img fetchpriority="high" decoding="async" class="aligncenter wp-image-560 size-large" src="https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_1-1024x557.jpg" alt="OpenCart license agreement" width="1024" height="557" srcset="https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_1-1024x557.jpg 1024w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_1-300x163.jpg 300w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_1-768x418.jpg 768w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_1-1536x835.jpg 1536w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_1-1222x664.jpg 1222w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_1-897x488.jpg 897w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_1-684x372.jpg 684w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_1.jpg 1913w" sizes="(max-width: 1024px) 100vw, 1024px" /></p>
<p>Make sure all the required PHP extensions are installed then click on the <strong>Continue</strong> button.</p>
<p><img decoding="async" class="aligncenter wp-image-561 size-large" src="https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_2-1024x582.jpg" alt="Required PHP extensions" width="1024" height="582" srcset="https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_2-1024x582.jpg 1024w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_2-300x171.jpg 300w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_2-768x437.jpg 768w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_2-1536x874.jpg 1536w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_2-1222x695.jpg 1222w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_2-897x510.jpg 897w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_2-684x389.jpg 684w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_2.jpg 1899w" sizes="(max-width: 1024px) 100vw, 1024px" /></p>
<p>The next page will require you to fill in the database details. Enter the details you defined in the MariaDB database and click <strong>Continue</strong>.</p>
<p><img decoding="async" class="aligncenter wp-image-562 size-large" src="https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_3-1024x576.jpg" alt="OpenCart database details" width="1024" height="576" srcset="https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_3-1024x576.jpg 1024w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_3-300x169.jpg 300w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_3-768x432.jpg 768w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_3-1536x864.jpg 1536w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_3-1222x687.jpg 1222w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_3-897x505.jpg 897w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_3-684x385.jpg 684w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_3.jpg 1888w" sizes="(max-width: 1024px) 100vw, 1024px" /></p>
<p>Once the installation has been completed, you should see the following page:</p>
<p><img loading="lazy" decoding="async" class="aligncenter wp-image-563 size-large" src="https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_4-1024x584.jpg" alt="OpenCart installation complete" width="1024" height="584" srcset="https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_4-1024x584.jpg 1024w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_4-300x171.jpg 300w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_4-768x438.jpg 768w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_4-1536x877.jpg 1536w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_4-1222x697.jpg 1222w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_4-897x512.jpg 897w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_4-684x390.jpg 684w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_4.jpg 1889w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></p>
<p>Then if you click on the <strong>Go to your Online Shop</strong> you should see your shop page:</p>
<p><img loading="lazy" decoding="async" class="aligncenter wp-image-565 size-large" src="https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_5-1024x521.jpg" alt="OpenCart Shop Page" width="1024" height="521" srcset="https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_5-1024x521.jpg 1024w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_5-300x153.jpg 300w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_5-768x390.jpg 768w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_5-1536x781.jpg 1536w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_5-1222x621.jpg 1222w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_5-897x456.jpg 897w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_5-684x348.jpg 684w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_5.jpg 1898w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></p>
<p>Or if you click on the <strong>Login to your Administration</strong> button you should see the login page:</p>
<p><img loading="lazy" decoding="async" class="aligncenter wp-image-566 size-large" src="https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_6-1024x439.jpg" alt="Login Page" width="1024" height="439" srcset="https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_6-1024x439.jpg 1024w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_6-300x129.jpg 300w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_6-768x329.jpg 768w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_6-1536x659.jpg 1536w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_6-1222x524.jpg 1222w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_6-897x385.jpg 897w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_6-684x293.jpg 684w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_6.jpg 1909w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></p>
<p>Provide your admin username, password and click on the <strong>Login</strong> button. You should see your administration panel:</p>
<p><img loading="lazy" decoding="async" class="aligncenter wp-image-567 size-large" src="https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_7-1024x516.jpg" alt="OpenCart Dashboard" width="1024" height="516" srcset="https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_7-1024x516.jpg 1024w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_7-300x151.jpg 300w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_7-768x387.jpg 768w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_7-1536x774.jpg 1536w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_7-1222x615.jpg 1222w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_7-897x452.jpg 897w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_7-684x344.jpg 684w, https://www.linuxtuto.com/wp-content/uploads/2022/07/opencart_7.jpg 1916w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></p>
<p>Now, open your terminal and remove the installation directory with the following command:</p>
<pre><code>$ sudo rm -rf /var/www/html/opencart/upload/install/</code></pre>
<h2><span class="has-inline-color has-vivid-purple-color">Comments and Conclusion</span></h2>
<p>Congratulations! You have successfully installed OpenCart. Thanks for using this tutorial for installing the OpenCart on Ubuntu 22.04 OS. For additional help or useful information, we recommend you to check <a href="https://www.opencart.com/" target="_blank" rel="noopener">the official OpenCart website</a>.</p>
<p>The post <a href="https://www.linuxtuto.com/how-to-install-opencart-on-ubuntu-22-04/">How to Install OpenCart on Ubuntu 22.04</a> appeared first on <a href="https://www.linuxtuto.com">LinuxTuto</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.linuxtuto.com/how-to-install-opencart-on-ubuntu-22-04/feed/</wfw:commentRss>
			<slash:comments>7</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">550</post-id>	</item>
	</channel>
</rss>
