tag:blogger.com,1999:blog-75791922893488777002024-03-13T20:07:13.156+01:00$this->phpOnce in a while, a thought or twoSteven Van Poeckhttp://www.blogger.com/profile/07164941745610394892noreply@blogger.comBlogger10125tag:blogger.com,1999:blog-7579192289348877700.post-34205429971138719072012-03-12T16:19:00.000+01:002012-03-12T16:21:31.908+01:00Installing Blitz templating engine for PHP 5.4Earlier today I wanted to install the Blitz templating engine on my brand new PHP5.4.
The docs say to do:
phpize
./configure
make install
However, make complains about safe_mode.h not being found and the compiling fails.
That's logical because safe_mode was removed from php 5.4.
There's an easy workaround: comment out or remove the #include "safe_mode.h" line from the blitz.c file and then run Steven Van Poeckhttp://www.blogger.com/profile/07164941745610394892noreply@blogger.com0tag:blogger.com,1999:blog-7579192289348877700.post-44181767598528653912011-12-31T17:10:00.000+01:002011-12-31T17:13:15.450+01:00Installing webistrano on Debian Squeeze 64bits
This is how *I* did it. By no means is this the perfect way, nor very probably how it should be done, but it worked for me.
As root:
1 activate default repositories
# vi /etc/apt/sources.list
add, if not already there:
deb http://ftp.debian.org/debian squeeze main contrib
deb-src http://ftp.debian.org/debian squeeze main contrib
2 update apt
# apt-get update
3 install the necessary packages
Steven Van Poeckhttp://www.blogger.com/profile/07164941745610394892noreply@blogger.com0tag:blogger.com,1999:blog-7579192289348877700.post-33466550787779242422011-11-25T10:28:00.001+01:002011-11-25T10:58:04.921+01:00[FR] Les slides de ma présentation au PHP Tour à Lille en 2011Pour ceux qui souhaitent récupérer les slides de ma présentation :)Steven Van Poeckhttp://www.blogger.com/profile/07164941745610394892noreply@blogger.com0tag:blogger.com,1999:blog-7579192289348877700.post-54808312324962436172010-12-19T15:19:00.000+01:002010-12-19T17:10:59.683+01:00Zend framework: imaging the menuHmm
This is more of a reminder to ::self than a post. Because it took me nearly a full day to figure out how to be able to put just a logo image in the menu with Zend_View_Helper_Navigation_Menu. So here goes.
Note 1: I used ZF 1.11
Note 2: For simplicity, I used "fullmoon" where you should use your application name. Take notice of case within the code, it's important and it changes Steven Van Poeckhttp://www.blogger.com/profile/07164941745610394892noreply@blogger.com0tag:blogger.com,1999:blog-7579192289348877700.post-26315042935383427392010-11-11T16:40:00.000+01:002010-11-11T21:12:55.588+01:00Should your company develop it's own framework ?Having had some discussions with colleagues about building a framework, I just wanted to share my point of view, hoping it may profit to someone.
Adapted to your needs
A framework, per definition, is generic. If you develop one yourself and you do it right, your home-made framework will end up having as much abstraction as a public one.
On the other hand, a public framework can be adapted to someSteven Van Poeckhttp://www.blogger.com/profile/07164941745610394892noreply@blogger.com1tag:blogger.com,1999:blog-7579192289348877700.post-64063051060657163292010-08-06T09:02:00.000+02:002010-08-06T09:15:34.850+02:00Setting the paper straightAs a reminder note to myself, and for anyone else it may help, here's how you can easily set the default page size for printing in Firefox.
fire up firefox
Type about:config in the address bar
Confirm that you'll be careful
In the filter bar, type paper_size
Double-click the entry print.postscript.paper_size and change it's value to A4 for example
Hit Ok to save your modification
Double-click Steven Van Poeckhttp://www.blogger.com/profile/07164941745610394892noreply@blogger.com0tag:blogger.com,1999:blog-7579192289348877700.post-43386834076464824372010-05-13T09:06:00.000+02:002010-05-13T09:39:33.207+02:00Ubuntu 10.4 ambiance theme: setting the buttons straightI just recently installed Ubuntu 10.4 LTS and set appearance to use the ambiance theme.
The window border buttons were on the left though by default.
Now, I'm not a fluent Mac user, so I prefer having those on the right.
It proved to be really simple to do so:
Hit <alt><f2>, type gconf-editor and hit <enter>.
Navigate to apps > metacity > general and edit the item Steven Van Poeckhttp://www.blogger.com/profile/07164941745610394892noreply@blogger.com0tag:blogger.com,1999:blog-7579192289348877700.post-54660893104760630772010-04-29T16:34:00.000+02:002010-12-19T16:03:10.317+01:00Quick trickWant to know easily if a given array is multi-dimensional ?
<?php
if (count($array) != count($array, COUNT_RECURSIVE)) {
echo "this is a multidimensional array";
}
?>
There you go.
Note that there's a caveat: if the second dimension element is an empty array, this will yield FALSE:
<?php
$array = array(
1,
2,
3,
array(),
4
);
?>
will NOT say this is a multidimensional Steven Van Poeckhttp://www.blogger.com/profile/07164941745610394892noreply@blogger.com0tag:blogger.com,1999:blog-7579192289348877700.post-38074341862410009462009-04-06T14:50:00.001+02:002009-04-06T15:41:38.144+02:00PHP Vikinger in my town of birth !This year, Derick Rethans is organizing the PHP Vikinger event for the third time. And it’s in Leuven above all places :)If I can make it to Belgium (I live in France) on the 30th of May, I will definitely be attending at least part of the (un)conference. You can find more information –and register for the event- on the PHP Vikinger website. Hoping to see a few of you there :)Steven Van Poeckhttp://www.blogger.com/profile/07164941745610394892noreply@blogger.com0tag:blogger.com,1999:blog-7579192289348877700.post-84599739133831297102009-03-05T12:56:00.000+01:002009-03-25T09:24:24.911+01:00Ghost cookie ? Strange behaviour
We last experienced a strange behaviour on one of our sites: marketing department wanted a tracking cookie to be written when customers came to the site through a sponsored link displayed upon a Google search.
So the sponsored link had a request part that indicated the marketing code to put in the tracking cookie.
But that marketing code was never put in the cookie. Why ?
Steven Van Poeckhttp://www.blogger.com/profile/07164941745610394892noreply@blogger.com0