Blogs Bookmarks Computere og Internet Kim Blog (English) Resources

DrupalCamp Copenhagen 2008 – Drupal Danmark: You’ve come a long way, baby

Drupal.OrgRegular readers might know that I’m a big fan of the Content Managment System Drupal. I’ve been actively promoting this system for 3 years, and I was active when Drupal Danmark, the Danish Drupal community, was established in the spring of 2006.

Despite this, I’ve never really managed to build anything useful using Drupal!

It’s not that I haven’t tried, actually I’ve ventured into a number of projects where I’ve tried to use Drupal as an application framework, because I, strongly, believe that Drupal is so much more than a CMS.

The projects haven’t failed completely, and I’ve learned valuable lessons, but I never really managed to finish them.

As a developer trying to work with a CMS for development is rather frustrating, since you get to spend most of your time configuring the system, and you constantly run into limitations, that mostly are related to the fact that developers and non-developers alike, has to be able to configure the system.

Why did the projects fail? Was it due to lacking skills on my part, or is Drupal not suited to use as an application framework or are there additional factors?

I’d like to explore this, so I’ve signed-up for the very first DrupalCamp Copenhagen, that will be held November 15th and 16th 2008 in Copenhagen.

I’ve also proposed a session: Using Drupal as a Web Application Framework, let’s see if that is accepted, but for sure I’m not going to be a tourist, and I’m going to actively pursue an answer to my questions.

You’ve come a long way baby
Like I mentioned, I was present when we took the first steps trying to establish the community back in spring of 2006, but since late 2006 I’ve been mostly absent from the community.

Since then Drupal, and Drupal Danmark, has grown stronger and stronger, and if you take a look at the sign-ups for DrupalCamp Copenhagen 2008, you can see how strong the community has grown.

The fact that there’s a significant number of international attendees is impressive. This has a lot to do with Drupal Danmark and evangelists like Morten DK’s and Mikkel Høgh’s very active participation in the international community.

So thank you all for growing the community, and having the guts to go ahead with DrupalCamp Copenhagen 2008. YOU ROCK!

Drupal Danmark: You’ve come a long way baby.

Hope to see you at DrupalCamp Copenhagen.

See also:

Blogs Computere og Internet Historier/Stories Kim Blog (English) Technology

No _compiler_ detected errors – but shouldn’t I, at least, have received a warning?

One of the first compilers I worked with, VS-Pascal, had a very “HAL-like” confident behaviour, after it had finished a succesful compile, it wrote:

“No compiler detected errors”

I found that almost rude, but it was also something to keep in the back of your mind, and today I remembered this clearly.

For the last week or so I’ve had a mysterious ASP.NET/C# problem on the back-burner. I’m trying to populate a drop-down list on a webpage. The list is based on a list of documents. For that purpose I had an entity class with a constructor, in the Page_Load code of the webform, I’m initialising the drop-down with a desciption and an id from the document list.

The list was populated just fine, but when I did a post of the form, I was consistently told that the first item was selected, even if I selected item number 2, 3 or 4.

This was very frustrating, especially because I have two drop-downs, and the other was working just fine.

Today I couldn’t postpone the problem any longer, and I tried a number of things, including moving the drop-downs, and finally I started doing websearches for bug-reports, but it’s extremely unlikely that ASP.NET has such a fundamental bug, so I was clearly doing something wrong.

When you’re using frameworks like .NET, a lot is done behind the scenes, luckily I know HTML so I finally hit View/Source, and to my surprise all the option values in the select tag were set to 0, why was that, I knew that my list was initialised to values from 0-4, but it was consistent with the test-results.

I was clearly doing something wrong. Below is the C# source-code for the entity class, can you spot the problem?

public class ShredYearDocument
       private int _shredYearId;

       public int ShredYearId
           get { return _shredYearId; }
           set { _shredYearId = value; }

       string _shredYearDescription;

       public string ShredYearDescription
           get { return _shredYearDescription; }
           set { _shredYearDescription = value; }

       public ShredYearDocument(int ShredYeadId, 
           string ShredYearDescription)
           _shredYearId = ShredYearId;
           _shredYearDescription = ShredYearDescription;

I’ll give you a hint: there are no compiler detected errors, but I’d argue that the compiler should,at least, have generated a warning, because I have something that could be likened to unused, or uninitalised, local variables.

Another hint: Remember that I always had the id set to zero (0), no mater what.

But shouldn’t the compiler generate a warning here?

Blogs Bookmarks Computere og Internet Hackers Kim Blog (English) Open Source Technology

PHP blues – drawing a blank

Software development can be extremely frustrating, and it might be true that the computer only does what you tell it to do, but these days a lot of people, besides yourself, are telling the computer what to do, a fact that complicates matters “somewhat” (understatement of the year).

The following experience documents a case, where I was sure that I wasn’t doing anything wrong, and you could argue that I didn’t, I just didn’t know any better, but thanks to the community I solved the problem.

The setting

I’ve recently begun doing some PHP programming, and I like it a lot, mostly because of all the wonderful community. it’s my gut feeling that I find answers to my questions much faster when I have PHP related questions, compared to .NET questions.

So I was experimenting with generating some XML code from PHP, but when I gave the URL to the W3C validator, it told me that the XML wasn’t well-formed, and that it was the header that was the problem.

I couldn’t see anything wrong, until I took a closer look. There was a mysterious space prefixed the output when I did a View/Source, a space that I for sure knew I didn’t echo. Hmm…

I tried several things, including flushing the output, but nothing helped.

Then it dawned on me: it’s very likely that someone else has had this problem, and if they did, for sure they would have the generosity to share it, so Google to rescue.

I googled: problem php output leading blank, and hit number two yielded this article:

Script for removing blank spaces before and after PHP tags « memento

The solution

It turns out that PHP is quite sensitive if you, by accident, leave prefixed or sufficed blank spaces outside the starting and ending php tags.

So I went through my PHP files, luckily I only have two, made sure there were no leading or trailing blanks og lines, and I get well-formed XML now.

This is a rather annoying bug in, or should I say feature of, PHP, and it exists in both PHP4 and PHP5.

Once again the community came through, without it I’d still be drawing blanks.

And I love the drawing on the memento site, it doesn’t get geekier, and I think I’ll remember to strip leading and trailing blanks now.

I’m still looking for a modern development environment for PHP development (e.g. sourcecode debugging). PHPEclipse, a plug-in for the Eclipse development environment, should provide a relatively modern development environment, even though it’s not up to the standards set by Microsoft VisualStudio, that I’m so accustomed to, Microsoft has spoiled me.

Blogs Bookmarks Kim Blog (English) Technology

CodeGear | Delphi for PHP – promising IDE for PHP development

CodeGear | Delphi for PHP

I’ve just discovered the product Delphi for PHP and it looks very promissing.

Based on the qstudio project from qadram, Delphi for PHP is an IDE (Integrated Development Environment) for PHP, here’s what Borland writes on it’s CodeGear site:

Revolutionize Your PHP Web Development

Delphi® for PHP revolutionizes PHP web development with Delphi’s proven visual Rapid Application Development (RAD) approach for accelerated visual PHP web development. Delphi for PHP is the fast and easy way to build robust PHP web applications.

Some highlights:

Delphi® for PHP

The RAD visual PHP development environment

  • Delphi’s proven visual (RAD) framework for PHP
  • Delphi’s comprehensive PHP for VCL libraries
  • Sophisticated editing and integrated debugging speeds up the process of tracking down bugs and errors in the code
  • Integrated development environment streamlines code management and navigation so managing and organizing PHP code has never been easier.
  • Open source runtime
  • Out of the box support for MySQL and InterBase

The IDE runs on Windows only, but the applications can be deployed to any application server running Apache, Internet Information Server and PHP5.

Priced at $299 (introductory price $249) it sounds like good value for money, there are accademic discounts, so you can get it for $99, and you can download a free trail version.

I’ve always loved Borland’s products for their powerful IDEs, and PHP has clearly been lacking a product, like Delphi for PHP, with professional support, and a great out-of-the-box experience.

DAPUG is organising a 2 day Delphi for PHP Workshop dedicated to Delphi, at the Hotel Hesselet in Nyborg, Denmark, on the 1st and 2nd of May 2007.

Read more about Delphi for PHP