Latest articles under Programming category

Remote debugging PHP using Xdebug on MAMP

A development tools such as Microsoft Visual Studio has debugging feature built-in where you can step through the code line by line and watch the variables. There are times when you may want to do the same thing with PHP script running in a remote (or it could be local as well) web server. It [...]

Posted on May 21st, 2009 under MacOS X, PHP  •  No Comments

Adding new lines to beginning of files.

I needed to do this when I want to debug my scripts for memory usage. My problem at that time was that as I include libraries, for some reasons PHP uses more memory even though I haven’t run a single code (other than require_once).
So my idea is to add memory_get_usage() function call on the beginning [...]

Posted on May 5th, 2009 under General Unix, Quick Tips  •  No Comments

Introduction to merging with SVN

One of the “problem” in using SVN with branches is that you have to figure out which revisions to apply. In most cases, one could not simply take the HEAD version and simply merge that to a branch or TRUNK.
On this page, I’ll attempt to explain why we can’t simply merge the HEAD version. On [...]

Posted on April 3rd, 2009 under General / Algorithm  •  2 Comments

Using PHP Variable Variable.

I’ve known the concept of PHP’s variable-variable from when I start working with PHP years ago. I thought it’s a neat feature that I’m not sure what, if any, it is useful for. Just recently, I found that it’s actually useful for me while generating XML using SimpleXML. If you’ve never heard about variable-variable, then [...]

Posted on March 27th, 2009 under PHP  •  No Comments

Split screen in vi

This is pretty simple to do. It’s also very usable if you just want to compare 2 files or different sections on the same file. Here’s what you do while in vi or vim.
Split screen horizontally

:split

The above code will split vi horizontally like the screenshot below. You can also supply an optional filename. If you [...]

Posted on February 17th, 2009 under Quick Tips  •  3 Comments

Page 2 of 4«1234»