Category Archives: Software Development

Post about software developing. Usually a solution to a particular problem, a code sample, etc.

JavaScript: Uppercase first letter in a string

In PHP there is a very handy function called ucfirst which Returns a string with the first character of str capitalized, if that character is alphabetic. Needed that in JavaScript, but discovered there was no such thing.

Posted in Software Development | Tagged , , | Leave a comment

PHP: How to easily provide JSON and JSONP

Have some server-side data that you would like to grab through an AJAX call? For example by using the jQuery.ajax method? A really easy way of doing this is by using the JSON format.

Posted in Software Development | Tagged , , , , | 2 Comments

PHP: Generating transparent PNG fillers

So, I was fooling around the other day with an HTML table and wanted to make the odd rows slightly darker. Figured I could use for example an 80% transparent black PNG to do that (or could have just assigned … Continue reading

Posted in Software Development | Tagged , , , , | Leave a comment

C#: How to send emails

Sending a basic email message in a C# application is quite easy thanks to a class called SmptClient. We simply need an address to send to, an address to send from, the message we want to send and the client: … Continue reading

Posted in Software Development | Tagged , , , , | Leave a comment

Kohana PHP framework

As you might know, I am developing some internal software for LifeStyleTV at the moment. Because of various slightly annoying circumstances I am stuck using PHP and MySQL for this. Not the worst of course, but I must say I … Continue reading

Posted in Software Development | Tagged , , | Leave a comment

How to check for duplicates

Say you have an IEnumerable<t></t> of some sort and you want to check if it contains any duplicates. How do you do that?

Posted in Software Development | Tagged , , , | Leave a comment

Test-Driven Development: By Example

I earlier wrote about the book, The Art of Unit Testing, which I finished a while ago. That book was very good and was focused on how to write good unit tests. It also mentioned Test-Driven Development, TDD, but not … Continue reading

Posted in Reviews, Software Development | Tagged , , , | Leave a comment