Integrating Agile Toolkit with WordPress

Tuesday, October 25th, 2011|Beginner tips, Version 4|by Romans|1 Comment

The question I get asked a lot is how to integrate Agile Toolkit with other frameworks.

One of the best qualities of Agile Toolkit is that it can be very nibble when you want to use it to fill the gap. So let’s scrap the whole page routing mechanics and simply create a SINGLE PHP file which would work on it’s own. For this, you will need to have most up-to-date Agile Toolkit (4.1.3).

Read more

Creating Smart Buttons in Agile Toolkit

Monday, October 17th, 2011|Uncategorized|by Romans|3 Comments

I am working on a project, which features numerous places where it’s possible to select a client from a drop-down. I thought about creating a single class, which will work as a button, but would also contain the logic of actually adding the client through a form in jQuery UI Frame.

As a result, I’ve created a universal “NewEntry” button, which can be added anywhere like this.

->setLabel(‘New Client’)->setModel(‘Client’,array(‘name’));

This produces the following:

  • Button is added next to the field
  • When button is clicked, new dialog is displayed offering to add new client
  • After form is submitted, dialog closes and new client is automatically selected in auto-complete field
  • Works with any model, label and list of visible fields can be customized

Read more

Build awesome re-ordering interface in PHP/ATK4 with one line of code.

Wednesday, October 5th, 2011|Uncategorized|by Romans|2 Comments

Agile Toolkit is awesome because it’s simple. Sometimes it lacks a feature, but it’s simple to add this feature. Having all those features in the core would be an over-kill, so many features are not in there on purpose.

An example is this controller, which will make items in your Grid order-able. Here is the screenshot of how it performs:

This sexy interface is implemented as a stand-alone controller in Agile Toolkit in about 70 lines of code and small bit of HTML,  no JS or CSS. But more importantly, it can be added to any Grid out there with just this:


Why is it important / cool?

  • It uses standard interface and will look right at home inside your project.
  • Relies on standard elements of Agile Toolkit.
  • Simple enough for you to read through and understand
  • Object-oriented so you can extend it to make it behave differently.
  • Requires no change to Grid.
  • Works with any model (just add numeric field “ord”)

Share your code!

When you develop your software, your goal is to get it done. This controller  took me about 30 minutes to implement. To properly document it and share, it would take some more time.

I’m pretty sure it’s same for you. If you are developing with Agile Toolkit, you might have a few interesting bits out there. My plan is to make it super-easy for you to throw a link to your Github repository and then let others convert your code into the properly documented add-on. Instead of re-inventing it, they could clean it up and document.

This way we don’t have to re-implement every bit and we’ll have a great library of add-ons growing!

How to share.

First – put your code into github and make it public. Even if it’s your personal project, it won’t hurt.

I’ll be working on the section on where you will be able to “share” some goodies you have in your code. Leave it to other devs to extract it from your code, clean it up and improve. Your contribution to Agile Toolkit community would be highly appreciated.

A recipe to help you find error in your program, when nothing else works

Sunday, October 2nd, 2011|Beginner tips|by Romans|1 Comment

Once in a while, I see people who are stuck with a problem and who say they have tried everything and it still does not work. I often find myself in a similar situation, but I have found a recipe to resolve it.

Read more