Category Archives: PHP

All posts related to PHP

Laravel 5.5 API Tutorial: Part 3 – Login & JWT

In parts 1 and 2 covering how to get started with a Laravel 5.5 API project, we covered creating a fresh Laravel project and then starting development with a User Registration API.  Up to this point things have been low … Continue reading

Posted in General, Laravel, PHP | 9 Comments

Laravel 5.5 API Tutorial: Part 2 – User Registration

This is Part 2 of multi-part walk-through of a Laravel 5.5. REST API example.  In Part 1 we covered how to install a fresh Laravel 5.5 project and prep it for API development, and in this part we’ll move forward with … Continue reading

Posted in General, Laravel, PHP | 13 Comments

Laravel 5.5 API Tutorial: Part 1 – Intro & Project Setup

After searching for examples on how to setup a Laravel 5.5 API project, particularly one that implements JWT for authentication, I was unfortunately left piecing together various bits and commands from different blog posts and github discussions.  Some of that … Continue reading

Posted in General, Laravel, PHP | 1 Comment

Implementing Session Timeout With PHP

PHP aims to make things simple.  So you’d think something like specifying session timeout would also be simple.  Unfortunately it can be a little tricky depending on your circumstances.  For example, if you Google php session timeout, you’ll find no … Continue reading

Posted in General, PHP | 25 Comments

Honeypot Technique: Fast, Easy Spam Prevention

Spam is one of those things we wish didn’t exist.  It’s annoying and serves no useful purpose.  Mail inboxes filled with junk mail, websites with bogus contact form submissions, and products hit hard by fake sign ups are only a … Continue reading

Posted in General, PHP | 63 Comments

Using Siege and KCacheGrind to Optimize SolutionPHP’s ORM

Some time ago we posted about how to install XDebug and KCacheGrind.  I think anyone serious about PHP performance should keep those tools handy and in regular use. And it just so happens they helped us uncover a huge performance … Continue reading

Posted in Database, General, Performance, PHP | Leave a comment

7 Best Practices For LAMP Projects

As a consultancy we’ve encountered all kinds of code.  Often times we inherit code from other teams, in which case we always make it a priority to review its style, structure, how it’s been deployed, if any frameworks were used, … Continue reading

Posted in General, Performance, PHP | Leave a comment

Ubuntu 10.10: Installing XDebug and KCacheGrind with PHP 5

After doing a fresh Ubuntu 10.10 install I spent some time re-installing some much relied on dev tools, 2 of which are XDebug and KCacheGrind. Their purpose is to add enhanced debugging and profiling capabilities to any dev environment. If … Continue reading

Posted in Performance, PHP | 2 Comments

PHPUnit in Kohana 2.3.4

I wanted to add unit test support to a current Kohana 2.3.4 project I’m working on.  Unfortunately, most of the posts I found on how to integrate unit testing into Kohana were for version 3.x, not 2.3.x.  The few hits … Continue reading

Posted in PHP | 15 Comments