Installing Yii2 via Composer

Installing Yii2 via Composer is not hard. Currently, the stable version available is 2.0.6.
Here's how to really do it, the easy way:
sudo apt-get install composer
composer global require "fxp/composer-asset-plugin:~1.1.1"

For installing the basic version of the framework:
composer create-project yiisoft/yii2-app-advanced mywebsite 2.0.6

For installing the advanced version of the framework:
composer create-project yiisoft/yii2-app-advanced mywebsite 2.0.6

You will require a GitHub token, which requires an account, but it's an easy an straightforward step.

./M6

Video Conversionn with ffmpeg

While searching for how to convert a2v video into a mov, I found everything that one wanted to know about ffmpeg but was afraid to ask explained in a simple way in here: this forum answer.

In short, just do

ffmpeg -format
to list all formats. Then use this simple command to convert between video formats:
ffmpeg -i {input_video_file} -f {format} {ouput_video_file}
In my case, my command was:
ffmpeg -i Passadeiras\ Ativas.m2v -an -f mov teste.mov
since I was converting to a mov file and stripping the sound.

./M6

Could not close zip file php://output.

Ever got a "Could not close zip file" when using PHPExcel Writer? Usually the full error message is something like
[exception.PHPExcel_Writer_Exception] exception 'PHPExcel_Writer_Exception' 
with message 'Could not close zip file php://output.' 
in /var/www/vhosts/yourdomain/phpexcel/Classes/PHPExcel/Writer/Excel2007.php:399

This is caused because the PHPExcel requires access to the /tmp directory but the apache configuration is not allowing it.

The solution is easy and fast, just add the /tmp to your php_admin_value open_basedir parameter, as in this example:
php_admin_value open_basedir "[your current paths]:/tmp"

When using EHCP, it is recommended to update the Virtualhost configuration in all your templates (apachetemplate, apachetemplate_ipbased, apache_subdomain_template, apache_subdomain_template_ipbased) located in /var/www/new/ehcp:
php_admin_value open_basedir "{homedir}:/usr/share/php:/usr/share/pear:/tmp"

./M6

Embracing SQL in Postgres

On the flame ware between SQL vs. ORM, I prefer SQL, and here's some hits why: Embracing SQL in Postgres

./M6

Virtuemart 3 Plugin Development

Here's some "hard to find" Virtuemart plugin development documentation that will help in the development of version 2 and version 3 of Virtuemart plugins: Virtuemart vmPSPlugin.

./M6

Debugging in PHP with XDebug

Debugging in PHP does not necessarily mean "print" or "log" debugging, even if one's using Lampp.

While checking out how to set up a good Joomla! 3 development environment, I've learned how to set up XDebug and configure it for PHP debugging.
Just check the correct XDebug version numbers and don't just "copy-paste" the settings.

./M6

Virtuemart Tutorials

While looking for some Virtuemart information, I came across this Virtuemart Tutorials and found it simple yet complete. It's for version 2.5, but it's still accurate.
./M6