Archive for the ‘CakePHP’ tag
DarkAuth for CakePHP
I thought I’d add a page to satisfy those of you who may have arrived here from the Cookbook, or anywhere else one of the DarkAuth pages was linked from.
I don’t really have much to do with this Component any more, although it still works great! I found that the built in Auth Component is plenty powerful enough, even if it doesn’t quite work work how I would have designed it.
Anyway, here’s the component (tested with CakePHP 1.2 RC3) DarkAuthComponent. Enjoy! It’s highly commented, so hopefully you’ll be able to work out what it does and how to use it…
CakePHP Evangelism and T-Cake
So I’ve had this blog for 3 posts now and none of them has a “cakephp” tag yet. Shocking. So here we go…
If you don’t know what CakePHP is and you’ve ever created a web application, or even a website that did more than show a static page, then you should check it out. CakePHP is a web application framework designed for rapid application development using the MVC Design Pattern and with a focus on Convention over Configuration.
What this means in practical terms is that you can built an access controlled, database driven, dynamic web sites/applications in a fraction of the time that it would to start from scratch. A simple blog could be built in a matter of minutes. I could go on for hours. So I won’t, I’ll talk about my latest project, which is – you guessed it! – built with CakePHP.
T-Cake
T-Cake is going to be a Torrent Controller. It’s not a Bittorrent Client, it can’t download using the bittorrent protocol or act as a tracker. It can provide an abstraction layer to a torrent client of you choice. Basically the application will allow remote access to control torrents which will then be activated using a torrent client.
The idea came from TorrentFlux which I used for a long while on my home server. However the time came when I wanted to do more, and was frustrated by the restrictions imposed by TorrentFlux being tied to BitTornado. The key idea in this whole project was choice of client.
To achieve this aim, I built a CakePHP datasource for interacting with a bittorrent client through an interface class. Then I designed an interface class for the Transmission Bittorrent Client which has a fairly simple JSON RPC for communication. I also intend to write an interface for rTorrent which has an XML RPC (slighty more complex, but potentially more functional).
The project is still in early stages, but going strong. The fact that I have abstracted the client, means I can add any features I want whether or not the client natively would support it, for example:
- Seeding to a pre-determined limit
- RSS torrent automation
- configurable queuing system
- Multi User option - with torrents only visible to their owner / admins
- Direct Torrent search and acquire via “engine” plugins
- Alerts for preconfigured events, e.g. torrent completion, new torrent added by RSS, new queue item starting, etc…
- Alerts could be theorectically pushed to any medium, email, SMS, an RSS feed, etc…
However the proviso on the client is that it has an API or RPC that I can hook into with PHP.
Well, sounds exciting doesn’t it? I think so, I’ll post some screenshots in a bit, so you can see the start of the interface, and maybe some of the techniques I’ve used in CakePHP to make it work.