cancel
Showing results for 
Search instead for 
Did you mean: 

Problem in Installing Magento 2.3 on LocalHost

SOLVED

Problem in Installing Magento 2.3 on LocalHost

Hello Guys;

I want to install Magento 2.3 version with sample data on local host on Windows 10 by xampp version 7.2.26, but after i finished all installation steps successfully and tried to go to home page and admin control panel that is i found here for home page:

sdafasdfasd.jpg

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Problem in Installing Magento 2.3 on LocalHost

Hello @mustafa_abdel a 

 

  1. open file /vendor/magento/framework/View/Element/Template/File/Validator.php in magento install dir , find

    $realPath = $this->fileDriver->getRealPath($path);

replace with :

$realPath = str_replace('\\', '/', $this->fileDriver->getRealPath($path));

Finally login page showing, but the icon is missing in login page and after login

  1. open file app/etc/di.xml in magento install dir, find

    Magento\Framework\App\View\Asset\MaterializationStrategy\Symlink

and replace with

Magento\Framework\App\View\Asset\MaterializationStrategy\Copy
  1. Then go to var/cache , delete all folder / file
  2. refresh the page, done.

For more just refer:

https://stackoverflow.com/questions/53565012/blank-admin-page-after-installing-magento-2-3-on-window...

Manish Mittal
https://www.manishmittal.com/

View solution in original post

3 REPLIES 3

Re: Problem in Installing Magento 2.3 on LocalHost

Hello @mustafa_abdel a 

 

  1. open file /vendor/magento/framework/View/Element/Template/File/Validator.php in magento install dir , find

    $realPath = $this->fileDriver->getRealPath($path);

replace with :

$realPath = str_replace('\\', '/', $this->fileDriver->getRealPath($path));

Finally login page showing, but the icon is missing in login page and after login

  1. open file app/etc/di.xml in magento install dir, find

    Magento\Framework\App\View\Asset\MaterializationStrategy\Symlink

and replace with

Magento\Framework\App\View\Asset\MaterializationStrategy\Copy
  1. Then go to var/cache , delete all folder / file
  2. refresh the page, done.

For more just refer:

https://stackoverflow.com/questions/53565012/blank-admin-page-after-installing-magento-2-3-on-window...

Manish Mittal
https://www.manishmittal.com/

View solution in original post

Re: Problem in Installing Magento 2.3 on LocalHost

@mustafa_abdel a You can go ahead with the solution suggested by @Manish Mittal .

 

But in that only step 1 is needed .

After doing step 1 just run the below command.

 

php bin/magento deploy:mode:set developer
php bin/magento setup:static-content:deploy -f

Thanks

Re: Problem in Installing Magento 2.3 on LocalHost

- Download Magento Project using composer

 

composer create-project --repository-url=https://repo.magento.com/ magento/project-community-edition=2.4.0

 

- Install Magento 2 using the command

 

php bin/magento setup:install --base-url="http://localhost/magento240" --db-host="localhost" --db-name=magento240_db --db-user=root --db-password=admin --admin-firstname="Admin" --admin-lastname="Magento" --admin-email="admin@gmail.com" --admin-user="admin" --admin-password="admin@123" --use-rewrites="1" --backend-frontname="admin"

 

Install sample data modules:

 

- Using composer:


1. Add dependencies to the `composer.json`:
composer require magento/module-bundle-sample-data magento/module-widget-sample-data magento/module-theme-sample-data magento/module-catalog-sample-data magento/module-customer-sample-data magento/module-cms-sample-data magento/module-catalog-rule-sample-data magento/module-sales-rule-sample-data magento/module-review-sample-data magento/module-tax-sample-data magento/module-sales-sample-data magento/module-grouped-product-sample-data magento/module-downloadable-sample-data magento/module-msrp-sample-data magento/module-configurable-sample-data magento/module-product-links-sample-data magento/module-wishlist-sample-data magento/module-swatches-sample-data magento/sample-data-media magento/module-offline-shipping-sample-data --no-update
2. Run:
composer update
- Using magento:
1. Deploy sample data:
bin/magento sampledata:deploy
2. Enable sample data modules (it's important!):
bin/magento module:enable Magento_CustomerSampleData Magento_MsrpSampleData Magento_CatalogSampleData Magento_DownloadableSampleData Magento_OfflineShippingSampleData Magento_BundleSampleData Magento_ConfigurableSampleData Magento_ThemeSampleData Magento_ProductLinksSampleData Magento_ReviewSampleData Magento_CatalogRuleSampleData Magento_SwatchesSampleData Magento_GroupedProductSampleData Magento_TaxSampleData Magento_CmsSampleData Magento_SalesRuleSampleData Magento_SalesSampleData Magento_WidgetSampleData Magento_WishlistSampleData
3. Remove old files:
rm -rf var/cache/* var/page_cache/* var/generation/*
4. Upgrade magento files:
bin/magento setup:upgrade
5. Recompile files:
bin/magento setup:di:compile
6. Do reindex:
bin/magento indexer:reindex
7. Deploy static content:
bin/magento setup:static-content:deploy