ehhhh, thanks for you answer, but I have to admit, I am posting a little bit off topic... I am asking for a non mapserver project this time, only php... so I have to build a function on my own... Joerg