I thought I would share something I have been using for quite a while now and find incredibly useful. They are two snippets for Visual Studio that create the standard file start and file end for php files in the codeigniter framework. If you are not sure what I mean then check out the files …
PHP
CodeIgniter: Using set_value with Form Posts
Today I came across an interesting bug in a codeigniter application I was working on where I encoded ampersands (&) were appearing in a report. I did some rudimentary debugging and realised that for some reason, values from a form were being saved to the database html encoded. I stepped through the code and discovered …
IIS7 WordPress and Friendly URLs
As a developer who uses Vista as their main OS, I have always found developing php sites a little bit awkward. Php never liked to play nicely with IIS and unless you installed and used Apache, friendly URLs were even more difficult to get working. I use IIS extensively for ASP.NET development and I never …
Check your PHP UTF-8 Checklist
I spent way too long this weekend on a problem that had such a simple solution. I guess this issue may have been a little to do with the fact that I use the CodeIgniter framework, which does so much of the hard work for you. it’s easy to get complaisant. I have been working …
Revisited: Tcpdf – Variable Height Table Rows With MultiCell
A few weeks ago I wrote an article about creating variable height table rows using tcpdf. It was a neat solution and I liked it, which was the reason I blogged about it in the first place. However, it turns out that ‘sharing the love’ is not the only reason to blog about these things. …
Tcpdf – Variable Height Table Rows With MultiCell
This post as been superseded. Please see my new post on the subject. During my use of the excellent tcpdf library for creating pdf documents with php, I came across an interesting problem when creating a pdf featuring a grid of data. Although I could have use an html grid to present the data, I …
CodeIgniter Error CSS Classes
When version 1.7 of CodeIgniter was released, they introduced a new form validation class that vastly simplified things. I particularly liked the new way in which any errors that occurred during form validation were displayed on screen. Where as before, an error message for a field was displayed as follows: <?=$this->validation->myfield_error?><?=$this->validation->myfield_error?> It seemed much neater …
Creating PDF Documents in PHP Using Tcpdf
When developing websites, it is not going to be too long before you are required to generate a pdf for users to download. One usually searches for a suitable library for this and in php, there are a few options out there. My personal favourite, and one that is still receiving regular updates and improvements, …