Tag » Posts Tagged ‘PHP’

How to upload large files in PHP

By default PHP is configured to allow files upload of size upto 2M.

We need to adjust the following PHP configuration directives:

  1. upload_max_filesize: By default this value is 2M. We need to increase it to the maximum size of single file that we want to upload.
  2. post_max_size: It defines the maximum size of POST data that PHP will accept. This value should be greater than ‘upload_max_filesize’.
  3. memory_limit: This sets the amount of memory a PHP script is allowed to use during its execution. Set this to a value greater than ‘post_max_size’ so that PHP script can load and process the uploaded file.

Continue reading »

Installing “Composer” – Dependency Manager for PHP in Windows

Composer

Composer is a dependency management tool in PHP. It allows you to declare the dependent libraries your project needs and it will install them in your project for you.

You must have PHP installed in your machine prior to installing “Composer”.

Composer requires PHP 5.3.2 or above (at least 5.3.4 recommended to avoid potential bugs).

Continue reading »

PHP Warning: include(): realpath failed to canonicalize

Warning

I was getting the following warnings when I was running Magento shell scripts from the command line using PHP CLI (PHP Command Line Interface).

PHP Warning:  include(): realpath failed to canonicalize Mage/Core/Model/App.php - bailing in /var/www/magentoproject/lib/Varien/Autoload.php on line 93

PHP Warning:  include(): realpath failed to canonicalize Varien/Event/Collection.php - bailing in /var/www/magentoproject/lib/Varien/Autoload.php on line 93

PHP Warning:  include(): realpath failed to canonicalize Varien/Event/Observer/Collection.php - bailing in /var/www/magentoproject/lib/Varien/Autoload.php on line 93

To remove this warning I started debugging Magento code but no success. Then I googled and came across various posts/forums saying that it was possibly due to APC.

Continue reading »

Magento System Requirements

Magento

Magento is an open source e-commerce platform built on PHP/MySql. It uses parts of the PHP Zend Framework. Like any other software, Magento also has certain system requirements which must be met in order to install and run it.

Lets go through the list of requirements which must be met for successful setup and functioning of Magento.

Continue reading »

Back to top