Associating CakePHP .ctp Files in Aptana, Eclipse


Viewing CakePHP’s .ctp files in Aptana Studio has been quite annoying due to the lack of syntax highlighting. I have grown use to it until earlier today when I was converting a .php file into a .ctp. I knew there had to be a way to associate .ctp files with .php files in Aptana/Eclipse. I did a bit of searching and found the solution.

  1. Go to Window/Preferences/General
  2. Select Content Types
  3. In the right pane, select the Text Navigation tree
  4. Select PHP Content Type
  5. Click the Add button
  6. Enter *.ctp and click Ok

If you have a .ctp file open, you will have to close and re-open it to view the changes. Much better.

Checkout My New Site - T-shirts For Geeks

Aptana Studio Won’t Open on Ubuntu


For some reason that I still have not been able to determine, I can no longer open Aptana Studio on my Ubuntu box. The splash screen displays, then nothing. Aptana closes. No error. No nothing. I think it has something to do with the JRE and/or XULRunner versions. Not sure. I used it one day, but couldn’t use it the next.

Continue reading

Checkout My New Site - T-shirts For Geeks

What Is Your Favorite IDE?


I have used Dreamweaver on my PC for many years. I think that it is the best IDE on the market. Why? Because both novice and seasoned web developers can use the same tool. And both will find it beneficial.

That being said, when I began to use my Mac for web development, I did not want to dish out the bucks for Dreamweaver, so I started using Aptana Studio.

I was moving deeply into Ajax development and I like the fact that Aptana Studio had built in support for many Javascript Frameworks (JQuery, YUI, Dojo, etc).

I also am a PHP developer, so Aptana Studio’s built in support for PHP was also a consideration. I’ve used this IDE when developing with CakePHP and CodeIgniter.

More recently, I have used Aptana Studio on my Ubuntu box while doing Django development (see my post: Setting Up Ubuntu For Web Development).

So what is your favorite IDE and Why?

Checkout My New Site - T-shirts For Geeks

Setting up Aptana Studio to work with CakePHP


I’ve been using Aptana Studio (based on Eclipse) on my Mac for over a year. It has become my default development IDE. When I first installed CakePHP, I could not understand why I was receiving errors when viewing test files in the browser. I eventually figured out that the problem was the location of my Cake files.

The important thing to remember is that the CakePHP files must exist on the root level of your web server – it can’t be located in a sub directory. Most of my projects are located under my ‘Aptana Studio’ workspace (a sub directory located on the root of my web server). So I assumed that I could do the same with CakePHP – although the documentation specifically says to place the files directly under root (at times it helps to follow the directions).

The problem is that I often work on multiple projects at a time so if I placed the Cake files outside my primary workspace, I would have to continually switch in and out of workspaces. But I found out that Aptana Studio (or eclipse) can be easily set up to work with CakePHP.

  1. Create a folder under root. Name it cake (can be named anything).
  2. Download CakePHP from here and unzip. Place the unzipped files in the cake folder.
  3. Start a new project in Aptana Studio (File->New->Project).
  4. Select PHP Project as a type and click next.
  5. On the next screen, name your project then uncheck Use Default Location
  6. Browse to the cake folder that you created (and select).
  7. Select this folder and then click finish.

That’s it. You should now be able to see your CakePHP files in your current workspace.

Checkout My New Site - T-shirts For Geeks

Setting up Ubuntu for Web Development


I’ve developed in the Windows environment for most of my career.  About 4-5 years ago I began to migrate to the Mac. Now my Mac is my primary computer.

I recently worked on a project where the target OS is linux, so I installed Ubuntu 9.04 desktop on an old PC. The following are the steps I took to create a web development box. This post assumes that you have already installed Ubuntu. Click here or here for installation instructions.

After you have installed ubuntu, you may want to select/download a theme for your box. Click Install Instructions to learn how to install gnome themes.

First, I will set up LAMP (Linux, Apache, MySQL, PHP) and phpMyAdmin. AMP is my default web development environment, regardless of OS.

Next, I will install Python, Django, PostgreSQL, phppgadmin, and pgAdmin (needed for my new project).  I will also install Aptana Studio and Java (need JRE to run Aptana). I have been using Aptana Studio on my Mac for over a year, and it has become my default development IDE.

Continue reading

Checkout My New Site - T-shirts For Geeks