Once again, I seemed to have drifted off into space instead of continually posting on this blog. 2008 was a big year with many changes both personally and professionally.
Much of 2008 I worked on a platform where much of my time, energy and motivation had been exhausted. This eventually lead to much less interaction with the development community as a whole and really disappearing from many of the areas I was involved in. In October I made a switch and joined a non-profit called CaringBridge. We are now working on building a new version that is built on top of the Zend Framework, memcached, apache and a few others. There has been much to write about, however, a lack of time has not allowed me to fully write what I have been up to or add to some of the articles I had began to write several months ago.
My plans for 2009 are fairly large and likely not fully obtainable but that’s what this is all about, setting a few goals and hopefully I will reach them this year. I have plans to finish out developing a new open source project related to project management in a development arena (think trac, bugzilla, wIT, JIRA). Secondly, I am planning to blog at least once a month and looking to post two or three times a month. Lastly, I will be going to a few conferences, PHP|Tek in Chicago will be the first one of the year.
Well, time to get back to it.
I’m always amazed to discover quite high profile sites letting goofy errors out in the open.
In case anyone missed it quite a nice PEPr proposal came in the other day, suggesting guidelines for software best practices and writing testable code.
Check out the original article too, it’s slightly better formatted.
On the SocialGeek blog there's a recent post that looks at making stubs for your URLs, making them easier to read and remember.
This is where the fun begins of course. How many times have you been confronted with someone sending you an indecipherable, thus untrustworthy link? Right, so we agree that for a user, it is important to have a clean URL that is readable and includes the title of the page or (at least) some description related to the content. Slug time!They explain what slugs are (and how they're useful for users) as well as how to convert a title into a "slugged" string by replacing anything that's not an A-Z or 0-9 character to remove the less URL friendly characters.
The Fliquid Studios site has posted their introduction to using the Google Search API via a cURL interface in PHP.
A lot of people these days use 3rd party sites or services to gain SEO data about their site or service. A lot of these people simply do not realize just how simple it is to build some tools to gain statistics from the big search engines. In this post I plan to give you a very basic introduction on how to go about getting some search engine statistics from Google using their API.They show how to create the connection (including the URL to search on) and a form that can be used to submit the terms back to the script. A demo and downloadable code are included.
The php|architect crew have officially posted their schedule for this year's php|tek conference (May 2009) and have announced a free webcast series on a range of PHP subjects.
We're happy to finally announce the schedule for php|tek 2009'"a bit late, we know, but with 250 proposals to sort and rank, it was tough work! In addition, we are also introducing a series of free webcasts on a wide range of topics relevant to the PHP world to keep all of us busy while we wait for the conference, culminating with Marco Tabini's opening keynote, live from Chicago at 9:00 on May 22.You can find out more about the conference from its website and more on the webcasts (and to sign up) here.
DevShed has posted the fifth part of their series looking at CodeIgniter and its use to make a simple blogging application. The focus this time is on the output, working with the views to "pretty up" the resulting pages.
Although in its current state, the blogger works well, its visual presentation looks pretty primitive. Therefore, in this fifth part of the series I'll be adding some CSS styles to the view files that comprise this blog application to improve its look and feel.They start with a review of the code so far - a simple blogging app with the ability to let users comment on each entry. The HTML and CSS you'll need to add to the views to make the output look more like this.
Johannes Schluter recently looked at one of the new features coming with PHP 5.3 - the goto functionality:
Over the last few days I already mentioned a few hidden gems from PHP 5.3. Now at Christmas I wanted to take a look at some new language feature of the upcoming PHP version: Added "jump label" operator (limited "goto"). (Dmitry, Sara)No, its not the sort of "goto" you're thinking of - its a bit more limited than that. Johannes mentions that it only allows you to jump within the same execution unit and you can't jump into loops. Used incorrectly, it can be bad but he points out two useful instances - one being a code generator and the other an instance where you might need to drop out of code but not kill off the script in the process (sample code is included for this second one).
In this recent post to his blog Doug Brown spends a little time comparing (at a high-level) some of the differences between ASP and PHP.
The difference between PHP and ASP is that ASP is a Microsoft product based on visual basic syntax whereas PHP has C and Java based syntax. ASP works better on Microsoft servers.He describes the target audience for each language and talks about the environments that they work best in as well as some general statements about their speed and flexibility. Basing his judgment on the facts he noted, he suggests PHP as the best alternative of the two for being more flexible, running in more places and being a bit faster overall.
Johan Mares has a recent post about using PHP on the command line:
I already knew how to run PHP scripts from the command line (CLI), although I never really used it. What was new to me was that there are 2 ways of doing this. The first one is by using the php command and the second, and new for me, is by adding a shebang on the first line of your script.His first way is to run the PHP file through the interpreter directly (via a command line call to something like "php myfile.php"). The second it to actually include the path to the interpreter inside the PHP file itself and use the shell to execute the contents based on that (adding something like "#!/path/to/php" at the top). Then you just make the file executable and you can run it like any other binary file.
Dave Marshall is having a contest to give away a few copies of the "Job Hunter's Handbook" (by Michael Kimsal) - all you need to do is sign up:
I've got a couple of copies of Php|architect's PHP Job Hunter's Handbook to give away, the only catch is you have to sign up to PHPPositions' feed via email. It's managed by Feedburner, so it can be trusted and you wont get any spam, just super smashing great php jobs in the UK.If you'd like to find out more about the book (or to order your own copy), head over to the book's page on the php|architect website. Normal price is $27 CAD for Print/PDF and just $23 CAD for the PDF.
Already a few days ago I got tagged by Manuel Pichler and Gaylord Aulke. I could not post as I was really sick the last two weeks. Today is the first day where I see light at the end of the tunnel and I feel good enough to answer the questions.
So you really want to know seven things about me ? Well - you asked for it
1. I earned my first money by creating a blackmarket in secondary school for sexual explicit material, which I bought cheap and sold expensive. This was one of the reasons I had to leave this school.
2. My first love was named Commodore 64. I teached myself Assembler and started to rip off music from games, creating my own demos.
3. My holidays are usually spent in croatia as my beloved wife was born there.
4. I work with a bunch of developers in lithuania, and hey - these guys (and girls!) are really good.
5. Recently I donated my book collection of > 2500 science fiction and fantasy books to a shop where handicapped sell the books to life from that.
6. Although I was born in bavaria my limit are 3 litres of beer, after that I am really really drunk.
7. I can’t stand cold weather - I feel well at an average of 26+ degrees. Oh, do you remember 4. ? In .lt the winters are really really REALLY cold and I hate it.
So - now my turn. Not so easy. I think nearly everybody who I know was already tagged, therefore - sorry about that - I need to tag a bunch of german people who I think are not yet tagged by this meme.
Here we go:
1. Nils Langner for teaching PHP
2. Thorsten Rinne just to remember him that he still ows me a self cooked thai menu.
3. Xenjo because I am curious what he would write….
4. Ralf Eggert to support his upcoming Zend Framework book (in german only)
5. Christopher Kunz who runs partly my servers for swoodoo and takes care about themeven from holiday. Thanks Chris !
6. Tomas Liubinas one of the .lt developers I mentioned and actually he was part of the team who won in plat-forms contest.
7. Max Horvath for… hmm… I still wait for the pics
These are the rules apparently:
Link your original tagger(s), and list these rules on your blog.
Share seven facts about yourself in the post - some random, some weird.
Tag seven people at the end of your post by leaving their names and the links to their blogs.
Let them know they’ve been tagged by leaving a comment on their blogs and/or Twitter.
Sometimes internet memes are something horrible. On PHP, right now, the whole idea is to share seven things about yourself (not things everyone knows about, it won’t be any fun), all of this because of Tony Bibbs (yes, it’s his fault, even if I don’t know him at all, he’s the one who started it all on the Who tagged who).
By the way I’ve been tagged by Mark Karpeles, myself. If you want to know why, you’ll have to read more.
For the people who don’t know me at all, I won’t eat you, you can come and try to talk to me. I started working on PHP’s WDDX extension (right now rewriting a part of it to use xmlreader instead of expat-like stuff) which was maintained by Andrei Zmievski (who wouldn’t have liked at all seeing the wddx functions assuming “everything is ISO-8859-1″, as he said before, “English is not the only language” and stuff like that).
Oh and now, I’m not using Coldfusion at all, I never touched Coldfusion, I use WDDX because it’s a nice serialization system, and because I got something to unserialize it on the other side.
Truncated by Planet PHP, read more at the original (another 1410 bytes)
Robert Basic has posted an example of the use of the Zend_Auth component of the Zend Framework inside of an example controller.
So, here's what I'm going to do: authenticate an user against a database table using Zend Framework's Zend_Auth component. It's really a piece of cake. You can see a working example here: http://robertbasic.com/dev/login/.He sets up a registry instance, a database table for the logins and the sample controller with both login and logout functionality. Complete code (and links to Zend Framework documentation are included).