Magento file and folder permissions set method

  

Such as: install plug-ins, batch import, background configuration, and so on. There are two ways to handle this permission problem now

SSH mode (for standalone server or VPS)


The code is as follows: find . -type f -exec chmod 644 { } ; find . -type d -exec chmod 755 {} ; chmod o+w var var/.htaccess app/etc chmod 550 mage chmod -R o+w media If that is not working, try setting all directories to 777 by doing This: find . -type f -exec chmod 644 {} ; find . -type d -exec chmod 777 {} ; chmod o+w var/.htaccess chmod 550 mage

operation in magento
< For example, the secondary menu is not available, Magento Connect is not available, the picture is not displayed, etc. Most of the reasons are caused by file permissions not set or improper settings. Below are the basic file and folder settings.

755 Permissions


The code is as follows: magento/app/etc magento/media magento/app magento/skin magento/var magento/var/.htaccess magento/js magento /downloader 644 permissions magento/index.php magento/downloader/index.php

php modify permissions

The code is as follows: <?php ## set file 644, directory 755 function AllDirChmod( $ Dir = "./", $dirModes = 0755, $fileModes = 0644 ){ $d = new RecursiveDirectoryIterator( $dir ); foreach( new RecursiveIteratorIterator( $d, 1 ) as $path ){ if( $path- >isDir() ) chmod( $path, $dirModes ); else if( is_file( $path ) ) chmod( $path, $fileModes ); } } ?>

Copyright © Windows knowledge All Rights Reserved