Archive | CSS RSS feed for this section

Digital Base v3 – Launch

14 Dec

I am proud to announce we launched our new website. On this website you’ll find a detailed portfolio & more about us. Although there is still alot of work todo (optimise css/xhtml, w3c validation, content correction). Check out our site in english & dutch

Propel / Pager / Datagrid

15 Dec

Because we are using propel in most of our larger projects, it’s very common we need a datagrid for the listing of the objects. A year ago we made a datagrid with the most important features combined with an ajax approach (sorting, filtering…), for the ajax functionality we wrote our own javascript function calls, what led to alot of unmanageable code, both javascript and php.

As time moved on, this loading of the datagrid became slower and slower (due to increasing objects, about 9000 records with multiple joined tables). This was mainly because the old datagrid first loaded all objects, and then sorted the entire array by the columns as defined by the user….don’t tell me..i know ! This is a bad approach, that means all records get looped, and if you are using propel that would mean for each of those 9000+ records an object is created…that’s crazy…(it has some advantages though)…

So now i finally found some time to do a total rewrite of this datagrid, combined with the power of the propel pager, propel criteria & the php/ajax framework xajax, i came up, faster then expected, with a powerfull scalable datagrid that only loads the visible records. All switchpages, sorting & filters call a corresponding ajax function. These functions change the criteria in the object and reload the datagrid. I’ll elaborate on this later, by showing you some code and perhaps an online example.

Zend Studio Performance

8 Dec

Lately i noticed Zend Studio wasn’t running as smooth as before. When going into hibernate or logging off, i often notice javaw.exe has crashed, that caused the system not to shut down. To fix this problem i’ve found several solutions, i’ll list those here for future reference :

  • make sure the power settings do not use the option to enable cpu throttling (this seems to be a java issue)
  • try replacing zends jre by JRE 6 (http://java.sun.com/javase/6/download.jsp)
  • disable the OS look&feel in your zend application
  • disable all power management for your video card
  • if you are using a dual monitor setup, make sure the editor & palettes are on the same monitor/display
  • remove the Zend Project cache file : /Documents and Settings/{Win username}/ZDE/config_5.1/caches/
  • expand the heap sizes (to more then 256 MB) the JRE needs for the Studio to function [file: {studiopath}/bin/ZDE.lax]
  • if you have a 64b machine, make sure you have the 64bit java lib
  • try disabling your antivirus for a second and check if performance goes up
  • if you are using an external subversion client (not ZDE’s), make sure your options in ZDE are on CVS. (options > source control). Performance gets a huge boost (integrated svn is causing a problem when using 3th party tools)
  • submit a support ticket (http://www.zend.com/support) (make sure to mention you tried all t he above steps, and provide as much detail as possible, because they won’t fix your problem untill they have everything they are looking for : hardware, software, ZDE.log, description of the project)

Here’s the info I found posted over at the PhpBuilder.com Zend Studio Forum by MStaniszczak (post is no longer there). This item addresses the speed of the java virtual machine, and for those of us running Intel processors, this tends to be faster than the Sun JRE. If you’ve got an AMD processor, this may or may not yield any performance.

Head on over to BEA Systems and get the JRockit 5.0 JRE. Don’t worry about the SDK, unless you’re a Java programmer. It’s about 30 megs, so dial-up beware. After downloading it, extract the exe (right click, extract archive).

After you’ve done that, you should see some files, as well as another archive or zip file named something like win_ia32_jrockit150_04_jre.zip. You’ll want to extract that as well, to it’s own directory or folder (name it jre) , and that’s going to be what we need.

First, make sure the ZDE is not currently running. If it is, exit it. Now, find your installation of the Zend Studio client. It should be something like C:/Program Files/Zend/ZendStudioClient-5.0.0/. You’ll see a directory already named jre. Rename it to jre_old. Copy the directory we created from the archive into the ZendStudioClient-5.0.0/ directory.

For me the HEAP size, in combination with the source control tab (to cvs) did it, as i am using tortoisesvn for version management.

My first project in Symfony

11 Jul

I’ve started on a project using a very good framework i am pleased about. If you take your time to have a look around on the website, you can clearly see this is a framework with alot of documentation, one of the major requirements for selection (in my case).

I decided to give it a go and use the framework on my latest project for EuPR (www.plasticsrecyclers.eu), as the timeframe for this project was quite limited, i needed a good framework, with plenty of documentation to solve the issues i would run into…

A snippet from the symfony about page :

Symfony is a web application framework for PHP5 projects.

It aims to speed up the creation and maintenance of web applications, and to replace the repetitive coding tasks by power, control and pleasure.

The very small number of prerequisites make symfony easy to install on any configuration; you just need Unix or Windows with a web server and PHP 5 installed. It is compatible with almost every database system. In addition, it has a very small overhead, so the benefits of the framework don’t come at the cost of an increase of hosting costs.

If you want to have a look at the results, go over to plasticsrecyclers.eu, i implented a login form, upload functionality (in different categories and a pager to browse through the various results of newsletters & documents…Keep in note that this is a “non-released” website still open for feedback & improvements….

Whatta ya think ?

Internationalization – seo – mod_rewrite : Part 1

10 Jul

I am running a pretty big company website that uses multiple languages so users can browse the website in their language. Lately i have been working on the Search Engine Optimalisation, and i noticed google (and some other crawl bots) do not correctly crawl the other languages, this had something todo with various reasons :

  • language selection was saved in session or by $_GET argument
  • meta language tag was not always set
  • there was no clear line how the language was selected, user couldn’t see by url which language he selected

I did a few lookups on the internet, some various SEO forums, and i’ve collected this information and, with the help of Apache mod_rewrite, turned the website into a fancy, easy-to-use, multilanguage environment, and this is how i did it. I will explain you in 3 different parts, which i will try to finish in the upcoming 3 days….

To start off i am using .xml files to hold all the different language strings, nowadays you can find some php frameworks that fully support i18n, but back in the days i was making international websites, they were not that commonly available. If you would go for a framework i would choose Mojavi, Prado or Symfony, i am not going to elaborate on that, as this post is not about frameworks, but howto put different languages on your website, and making sure google (and other search engines), crawl em like they should….

Start off by making sure you have a google sitemaps account and have a way to gather website statistics, very good would be a package where you can list the crawl bots seperately (i prefer awstats)

Sitemaps what/where went wrong when crawling your site. The Google Sitemaps program has two major components:

I’ll leave you the time to make sure you have both of the above items + it’s a really nice excuse to stop writing and do something else…Part II soon…

Awstats

Another Development Week

3 Feb

At this moment i am managing a project with 3 programmers and a designer. Because of the deadline of the project i had to allocate some extra resources to make sure everything is finished in time.

We are creating a system to analyse “Post Construction Waste” that is being transferred in Europe. To satisfy the need of our customer we designed a [tag]framework[/tag] that uses some of the most recent technologies including ajax, output caching, templating, xml language parsing and more…Because i prefer working with the recent available technologies, we decided to develop the project in php5, mainly because of the new/extended oop features and exception handling.

For version management we use Subversion, on my windows machine powered by TortoiseSVN with some extra scripts to commit/update/export with a simple click of the mouse (or shortcut combination). I noticed this week we crossed revision 700, we passed the cape of 500 programming hours on this project too….Time to move to the next one ?