Symfony Per Developer Configuration under Version Control

Are you a Symfony developer who work with several other developers, and you share your progress with them using a Version Control System (VCS)? Subversion, GIT, Mercurial, you name it. In a team based development environment, it's not uncommon that each of the developer needs to have some sort of personalized configurations. For example, in ProjectConfiguration.class.php, where you define your Symfony library include path: require_once '/home/user/projects/lib/symfony-1.4.8/lib/autoload/sfCoreAutoload.class.php';. In the single developer scheme, this works perfectly fine. However, in team development scheme under version control, this fails. That's because if you commit this file into VCS, it will alter the include path of the rest of the team.

Continue reading

Switch to External Monitor Connected via HDMI/VGA port in Ubuntu

This is more like part II of the article I posted earlier about my laptop issues in Ubuntu. I finally managed to get the HDMI (possibly VGA) port working. Keep reading if you are interested.

I found that I have to connect the HDMI cable before Ubuntu is booted up. If I do that, I am able to see the external monitor in Nvidia X Server Setting window. So either connect the cable before starting the OS, or connect the cable and then restart the OS will both work. This works well, but it's rather inconvenient. I want this to be done without restarting.
Continue reading

Fix Ubuntu (or Linux) Suspend/Hibernate Not Working Bug

I own an Asus N73JQ laptop, the spec is top notch. Since Windows has been long gone from my candidate OS, I installed Ubuntu 10.10 right away. So far the result is quite amazing. Smooth, reliable, and it feels just right. Although the OS itself is very impressive, I have 2 major issues with the hardware: (1) Function key that switches to external monitor does not work; (an update on the external monitor issue can be found here) (2) Suspend/Hibernate does not work. I have not found a solution for (1), which remains unsolved. I have, however, found a solution for (2). I am going to share this share this solution with those who having the same problem.
Continue reading

Selenium and symfony Integeration – the Non-plugin Approach (Tutorial)

I have been writing a lot test cases for a large web project built by symfony. From time to time I found the build-in testers are not sufficient to test my application thorough enough. Often times it is not possible to simulate the way a user would interact with the application. For this reason, I have turned to Selenium.

Though it takes some extra work to get it to work with symfony's Lime test framework, the result turns out to be very satisfactory. The following is for those who are interested at the integration process. All code examples shown here are written using a Linux box, but they should also work under Window environment.

Continue reading

Use Gedit as Remote File Editor via FTP and SSH (Ubuntu)

Migrating from Windows Vista to Ubuntu 8.04 and have been using it all the way to 9.10, I am now a complete Linux convert. As a web developer, I am frequently required to edit files on remote servers. Without some kind of mechanism to automate the upload process, it becomes laborious as number of files grows. On Windows system I use Notepad++ and its FTP plugin to edit remote files, which work pretty well.

Now I am using Ubuntu, I have to find a similar editor to accomplish this. After some investigation, I found that the bundled text editor gedit is capable of doing remote file editing -- but not without some tricks. In the rest of the article I am going to show you how to do this.

Continue reading