How to change php variables for your vtiger CRM?

Sometimes you need to increase your php variables because you need it to properly working of vtiger (or other services) but How to do it?
You have 3 option how to change php variables.

  1. change php.ini
  2. .htaccess
  3. config.inc.php

First at all, it is good to know how to display current PHP variables and settings.
Please read our blog: How to display PHP configuration of your vtiger?

Change variables in php.ini

  1. Locate your php.ini. You can find it when you open info.php file
    How to find php.ini file

    How to find php.ini file

  2. Open your php.ini file
    nano /yourpathfrominfophp/php.ini
  3. Find please your variables that you want to change.
    post_max_size = 8M
    upload_max_filesize = 2M
  4. Change values
    post_max_size = 512M
    upload_max_filesize = 5M
  5. Save php.ini
  6. Restart server
    sudo service apache2 restart

How to edit .htaccess?

  1. Find .htaccess file
  2. Open this file
  3. Edit value or add new line
    php_value memory_limit 512M

This method will only work if PHP is running as an Apache module.

Change variables in config.inc.php

You can also change php variables in config file of vtiger.

  1. Open config.inc.php file in your vtiger installation
  2. Find php variables or add new lines
    ini_set('memory_limit', '512M');
  3. Save it

Your php variables have been changed. To verify if changing has effect on your vtiger, please open again info.php file and check changed values.

Share this post

Comments (2)

Leave a Reply

Your email address will not be published. Required fields are marked *