Other Applications
How to fix the 10 most common Magento problems?

How to fix the 10 most common Magento problems?

How to configure Magento to work with a new domain?

Edit the Magento database

Go to your Site Tools > phpMyAdmin. Select your Magento database from the left menu, find the table called core_config_data and click on it. Click the Browse tab and edit the first two fields:


by clicking the pen icon in front of each of them. Replace your old domain name with your new one and click Go to save the change.

Clear the Magento cache

The Magento cache folder is located in your Magento installation directory > /var/cache. To clear the cache, simply delete the folder.

Many Magento issues can be fixed just by deleting the cache.

How to reset Magento Admin Password?

To change your Magento admin password, go to your Site Tools > Site >MySQL > phpMyAdmin, select your Magento database, click the SQL tab and paste this query:

UPDATE admin_user SET password = CONCAT(SHA2("XXXXXYourNewPassword", 256),":XXXXX:1") WHERE username = "YourAdminUser";

Note: You have to change YourNewPassword with your new password, and change YourAdminUser to your Magento admin username. Also, the XXXXX sequence can be replaced with any random characters.

Execute the query by clicking Go and your password will be changed.

How to enable Search Engine Friendly URLs in Magento?

To enable Search Engine Friendly URLs in Magento, you have to log in to the Magento administration area and go to Stores > Settings > Configuration. Under the General navigation menu, switch to Web from the sub-navigation panel on the left.

After that click on the Search Engines Optimization tab and turn on the Use Web Server Rewrites (choose Yes from the drop-down). Click on the Save Config button and your Magento SEF URLs will be enabled.

How to speed up Magento?

Many Magento issues are caused by slow performance. The recommended way to speed up Magento’s performance is to enable its optimization functions.  The performance increase is between 25%-50% on page loads.

To enable JS & CSS optimization go to Stores > Configuration in Settings Section > Developer in Advanced Tab > Section JavaScript Settings > Change to Yes the options “Enable Javascript Bundling“, “Merge JavaScript Files” and “Minify JavaScript Files“.

Also, in the Stores > Configuration in Settings Section > Developer in Advanced Tab again, expand the CSS section. There you should change the Merge CSS Files and Minify CSS Files to Yes.

How to redirect Magento to open through www?

For SEO and usability purposes you may want to redirect your visitors to open your site only through www (http://www.yourdomain.com).

To do this in Magento, you should open the .htaccess file in the folder where your Magento is installed. In it locate the RewriteEngine on line and right after it add the following lines:

RewriteCond %{HTTP_HOST} ^yourdomain.com$ [NC]
RewriteRule ^(.*)$ http://www.yourdomain.com/$1 [R=301,L]

Once you do this, save the .htaccess file and log in to the Magento admin area > Stores > Configuration menu in the Settings section and from the left panel expand the General menu and click on the Web button.

Unfold the Base URLs and Base Secure URLs set of options and change them from http://yourdomain.com to http://www.yourdomain.com.

Save the changes and your Magento will start working through www.yourdomain.com only!

How to disable the Compare products functionality?

You can disable the Compare products functionality in Magento easily. First edit theapp/design/frontend/Venustheme/fasony/Magento_Catalog/templates/product/list.phtml file and remove the following code:

compareHelper = $this->helper('Magento\Catalog\Helper\Product\Compare');
<a href="#"
 class="action tocompare"
title="<?php echo $block->escapeHtml(__('Add to Compare')); ?>"
aria-label="<?php echo $block->escapeHtml(__('Add to Compare')); ?>"
data-post='<?php /* @escapeNotVerified */ echo $compareHelper->getPostDataParams($_product); ?>'
<?php /* @escapeNotVerified */ echo __('<i class="fa fa-refresh"> </i>') ?>

How to set up a blog in Magento?

It is not difficult to set up a blog in Magento. However, note that this functionality is not included by default and you will have to use a custom extension to add it.

You can search Magento Marketplace for an extension that will fully suit your needs.

How to add a Contact Us form in Magento?

Magento includes contact form functionality by default. A link to a contact form can usually be found in the footer of your Magento installation.

Of course, you can add a contact form on any page. All you need to do is log in to your admin area and go to > Content Pages. Select the page you want to edit or create a new page. Paste the following code using the HTML option of the WYSIWYG editor in the Content block:

{{block type='core/template' name='contactForm' template='contacts/form.phtml'}}

Access denied issue

As a solution to the Access denied issue, you should log out from the Magento admin area and then log in again.

If the above does not help, you should reset the admin privileges. This can be done through the Magento admin area > System > Permissions section > User Roles.

Click on the Role Resources option from the left menu and make sure that Resource Access is set to All.

Click on Save Role and the permissions will be reset.

How to set a custom group of users?

You can add a new group from the Magento admin area > Stores > Other Settings section > Customer Groups > Add New Customer Group.

Once a customer registers, you can change the group he/she belongs to from the Magento admin area > Customers > All Customers. Click on the Edit link next to the customer you want to edit and change the group from the Account InformationGroup. Choose the new group from the drop-down and click Save Customer.

Share This Article