Author Archives

  • Regular expressions in Atom for code consistency

    When we start working in a project that was previously developed by another company, we could fall in the disgrace that the code was written by more than one developer without agreeing in the same practices, something that we can fix with some regular expressions (regex) within Atom. In the examples below I decided how the code should looks like […]

  • Connection to MySQL through PHP with DAO

    I will try to explain to you a how DAO is a better approach to connect to MySQL through PHP, making the code readable and secure at the same time. Change our connection from mysql_connect() to new mysqli(): Imagine we have a connection.php file. Typically it looks like this:

    Instead of this we could change it into […]