CakePHP RESTFul Routes – Basics

Introduction

In my opinion, CakePHP is a well equipped framework for building web applications. In this article I will try to explain how I overcame certain obstacles challenges when dealing with CakePHP and RESTFul Routes. For this article I used CakePHP v2.4.3 with a slight alteration to the core code => will be fixed in 2.4.4.

“CakePHP RESTFul Routes – Basics” verder lezen

CakePHP 2.0 – Storing Sessions in the database and retrieving online users

Notice

An updated version of this article is available here: CakePHP 2.8.x: Storing Sessions in the Database Revisited

Preface

Because I want to make this example as easy to understand for everyone, I will write it in English. I’m not a native speaker / writer so there might be some grammar errors for which I apologize in advance.

Preamble

What I will be covering today is how to configure your CakePHP 2.0 system to use your database to store user sessions, if you have one obviously. This could be useful to manage multiple sessions from different devices / ip addresses and to make sure no one else is signed in when you sign in somewhere else. Those parts I won’t be covering today, because that wouldn’t make this a small-tutorial =]. What I will be covering is something I find to be extremely handy in some situations, and that’s a method that shows you who’s online by checking recent session data.

“CakePHP 2.0 – Storing Sessions in the database and retrieving online users” verder lezen