Skip to main content

Agile testing: the first quadrant

The first quadrant contains unit tests and component tests. The following image is about the Lisa Crispin's 4 quadrants Unit testsTesting function, classes and methods following the discipline of test driven development and other extreme programming practices. We have a lot of unit testing frameworks that can he......

Installing PHP and the Oracle Oci8 extension

This post is the right and updated procedure to install the PHP Oci8 extension with the Oracle instant client on Linux (Ubuntu, Kali, Debian distributions). That's because I have spent a lot of time finding the right steps and combinations. The procedure seems very long but I ensure you will not need more than 10 minutes! I......

Getting started with Redis

From redis.io: "Redis is an open source (BSD licensed), in-memory data structure store, used as database, cache and message broker". To scale an application can be a big problem and using the right tools can make the difference. Redis is excellent and many big companies are choosing it. Let's see how to use it in p......

Getting started with Rabbit MQ

Rabbit MQ is a software for messaging that implements the Advanced Messaging Queuing Protocol. About the definition of Rabbit MQ from the official website:Robust messaging for applicationsEasy to useRuns on all major operating systemsSupports a huge number of developer platformsOpen source and commercially sup......

Kali Linux 2 installation and post installation

Kali Linux 2 came out in August 2015. I removed my Ubuntu installation after an ugly kernel panic caused by the acpi probe failed error (I've not solved this problem with my PC!). I can tell Kali is really amazing: you will have all tools for security, penetration testing and even web development like PHP, MySQL, Git, Java,......

Getting started with Laravel 5

I like PHP MVC frameworks and now Laravel has all my curiosity. It's fast, modern, clean, more lightweight and with good documentation both in the code and on the official website. Built using Symfony and the Symfony components, Laravel has tools and libraries to work even more efficiently with all modern features like diffe......

Web security: XSS

XSS is one of the most common security issues we have to worry about. It can be simple to prevent it but sometimes it's not. We must pay attention not only on our PHP code but even on HTML and Javascript ocde without forgetting old browsers. Some malicious users can use old version of Internet Explorer to explore the DOM and......

Clean Code part 2: variables names

We have the power to assign a name to a variable and it's a great power! We must assign a name to a variable that it must reveal its intents just when I read the name of the variable. If we can assign the right name and understand what the variable will do and its role on the software and on the algorithm, it would be perfec......

Clean code: bad code

What is bad code? Why we write bad code? Well Uncle Bob ask us many questions and then help us to understand how to improve gradually and start writing clean and maintainable code. We must learn to recognize bad code (code smell) and let us to update and improve existing code without breaking anything (refactoring). Let's st......

Becoming a Zend PHP engineer

I have finally passed the test for the Zend PHP certification. The exam consists in 70 questions and you will have 90 minutes. You have to answer right at least to 70% of them (49 questions). You need to buy the voucher from the official Zend website and, optionally, the Zend Study Guide for PHP 5.5. Be sure to select and b......

Setting a LAMP enviroment on Linux

Yet another tutorial about installing a LAMP on Linux (I'm using Ubuntu). I've found all info I needed online but for it wasn't so easy. All informations are different, for different tools and purposes and you can't find them in single tutorial. Here I'm listing all commands we need to set up a good PHP devel......

PHPStorm and PHPUnit autocomplete

To work with PHPUnit without autocomplete is almost impossible and sometimes PHPStorm doesn't show it. We must ensure we have enabled the IDE to see where PHPUnit is installed. I use the phar file. Since when  they have removed the PEAR installation, we have to install PHPUnit with the phar file. So download the phar fi......

Zurb Foundation and HTML5 accessibility

Ok this year Symfony3 will be launched but in the best practice book there are some good recommendations and warning for the next future. I'll try to summarize the most interesting concepts and warnings. There are a lot hints about what you can or must do and some warning about common mistakes and what you must not do.......

Symfony2 best practice

Ok this year Symfony3 will be launched but in the best practice book there are some good recommendations and warning for the next future. I'll try to summarize the most interesting concepts and warnings. There are a lot hints about what you can or must do and some warning about common mistakes and what you must not do.......

Zend2 vs Symfony2. Pro and cons

Zend2 and Symfony2 are the most popular and probably the best PHP framework. YII is a good alternative and there are other good choices like Fuel PHP or Phalcon. But I love these 2 frameworks. Let's see a comparisonZend framework 2ProStrong coreGood communitySupport for various database systems and servi......

Doctrine custom repository on Symfony2

Here I am with the first post of the 2015. Happy new year! I'm still learning and working with Symfony2 and today I've had some problem about setting a custom repository class that extends a Doctrine entity. Here is the specific page and paragraph on the offcial documentation. They Symfony documentation is great, much be......

Generate PDF documents using ZF2 and DOMPDF

If you are searching a library to generate PDF documents using Zend framework 2 in PHP, I suggest DOMPDF. You can integrate it with the framework and easily convert HTML documents to PDF.This is very useful if you have some data into your MySQL database and you want to create reports and documents. Just create a simple web pag......

Symfony 2 and Doctrine

If y0u have a database, probably you need to generate entities automatically. We'll use the console on app\console. But there are other small tricks you have to know. Let's see some very useful commands:MySQL enumUsing basic Doctrine commands you can have an error about enum types. It's highly recommende......

Amazon S3 storage, getting started

My Zend2 application must store attachment files but we don't want to store them on a shared hosting. We can have files from multiple website, so I was searching for a cloud storage solution. Here we have Amazon S3, an alternative to Dropbox or other services like this. We can interact with the AWS platform using SDK for our......

Writing a Doctrine custom function

Unfortunately Doctrine does not support so many SQL function so you have to build a class to let him use a custom function. Let's start building a DATE_FORMAT function. Let's write the class:namespace Application\Model\Doctrine\Functions;use Doctrine\ORM\Query\Lexer;use Doctrine\ORM\Query\AST\Functions\Functi......

This website and/or any sub domains use cookies to understand how you to improve your experience.