Jonathan Street's Blog: Lightning Fast Sites & Better Benchmarks
497154
Jonathan Street has a few tips for developers out there looking to speed things up on their site - seven tips towards "lightning fast sites".   I was recently creating a small tool in PHP and found myself hitting the max execution time and getting a fatal error. As it was only for my personal use I just bumped up the max execution time but it made me stop and think about how I could improve the speed of those scripts I do put up for public use. Most people aren't going to wait for 60 seconds for a page to load. Naturally I hit the internet looking for tips.    The tips he came across (each including the simple benchmarks to show the differences) were:   sizeof vs count is_int vs is_integer chop vs rtrim doubleval vs floatval fwrite vs fputs implode vs join ini_alter vs ini_set   Be sure to also check out his follow up post talking about building better benchmarks to test the sorts of tips he's given above.
765546
On the Zend Developer Zone, there's a new tutorial looking at one of the unsung heroes of the web development world - one that, when you need it, it does what it does well - SQLite.   Is a full-blown database server even necessary for most PHP applications? What about a data-driven website like a blog or a simple family photo album or message board? In these and may other cases, the small, simple, and extremely powerful SQLite may be all you need. Let's take SQLite out for a test drive and see how it performs, find some of the quirks you might run in to, and how to get the most use out of it.   They talk about SQLite being a "staple" in PHP for a while now and how PDO plays so well with it. They move on to the code quickly, giving a simple example of how to create a database, and table, and inserting content into the latter.    Other more advanced features are discussed - data types, speed of queries, using transactions, and cleaning up the code to really make it fly. They even talk about "user defined aggregate functions", a method to make running a set of data through the same processes over and over a snap.
270729
Those that didn't get a chance to check out this year's PHP UK Conference can get a little taste of what it was like from Rob Allen's perspective in his latest blog post today.   Included in the happenings he mentions were the talk that Cal Evans of the Zend Developer Zone gave on mashups, Kevin Henney's look at Object Orientation, and Rasmus Lerdorf's look at PHP5 performance/security. He also mentions meeting up with Dagfinn Reiersol (author of PHP in Action) to "talk shop" a bit about writing books.   You can check out all of the details about the conference that was over on their website including summaries of the talks that were given during this jam-packed one day event.
325391
At work we're mostly an OSS shop.  Partly because I have a strong bias towards OSS but cost, reliability, security, etc are all leading factors.  For the last several months now I've been in an interesting position to prove the benefits of OSS in a real-world environment.  We've had to extend a number of OSS tools to fit into our production environment.  These are significant additions and non-trivial.  Open Source allows you to STAND on the shoulders of gods.  For example we've been having a problem with the Jakarta DBCP  connection pool.  It was running out of connections in highly threaded environments and is slow.  Certainly slower than would be necessary.  Long story short.  Last night  ...
680727
In an effort to have a definitive resource to point to when people ask about PHP scaling, Sebastian Bergmann is asking for suggestions and information on the topic in his latest blog entry.    In "The J2EE guy still doesn't get PHP", Harry Fuecks suggests that PHP really needs [someone] to get together and write a detailed paper on how it works and why PHP scales so we can all live happily ever after.   I could not agree more.    Sebastian even notes that just recently, such a document would have come in very handy in a discussion. Unfortunately, he hasn't had the experience needed to make such a paper himself, so he's asking the community to help on the project and give suggestions/comments/offers of help in the comments of this blog posting.
575210
Popular posts from PHPDeveloper.org for the past week:PHP-Coding-Practices.com: How I Turned A Slow Array Sort Into A Quick One Using Quicksort AlgorithmZend Developer Zone: PHP Abstract Podcast Episode 4: Planning ProgrammingWeb Development Blog: Save bandwidth with PHProxy and ip2nationJob Posting: Assembleron Ltd Seeks PHP 5/MySQL/Ajax Developers (Reading, UK)PÃ¡draic Brady's Blog: Complex Views with the Zend Framework - Part 6: Setting The TerminologyThe Bakery: Four New Articles - Load Balancing, Request Info, UUID Behavior & Upload ThumbnailsCommunity News: PEAR Installer version 1.6.0 releasedChristopher Kunz's Blog: Building PHP with cURL and libmysqlclient5DevShed: Working with Prepared Queries with PDO Objects in PHP 5Secunia.com: rPath update for gd, php, php-mysql, and php-pgsql
320730
I'm starting to realize that my blog is a bit of a time machine.  For example I can create a blog entry to warn myself about something that WILL happen in the future.    My current NTP  blog entry is a good example.  I wrote this for myself as much as for the people who read my blog (or find me via Google).  I know for sure that NTP on Debian is going to bite me sometime in the future and I'm going to forget WHY.  Then I'm going to (of course) go to Google or my aggregator and search for NTP and then find my blog post.    I've done this about a dozen times now and its saved me a TON of time!
164654
Welcome to a new on-line column here at LinuxJournal.com, "Linux Products Insider".  I'm James Gray, Products Editor at Linux Journal.  After the spam has been deencrusted and hucksters repelled, I'll use this space to update you on the latest and greatest products and services that I find using my secret channels.  This week, I had the chance to take part in a press conference with Mark Shuttleworth, Founder of Ubuntu.  Read on to learn why Shuttleworth's is so fired up about the new Ubuntu 7.10 "Gutsy Gibbon" (available this week), as well as why he thinks Ubuntu is so darned successful.  read more
343797
As a companion to the podcast version of his review, Matthew Turland has posted his comments in text form over on his blog today.   I received an e-mail recently from a very nice gentleman at Packt Publishing - their representative asked if I would be willing to review one of their books, namely PHP Web 2.0 Mashup Projects by Shu-Wai Chow. Reviewing books is not something I had done before, so I thought I would give it a good old-fashioned college try.   He mentions the size of the book (and how it's not an indication of the quality) and the basic structure of the book, including spotlights on some of the specific topics covered.
655122
Over the last week, I've been writing about the disconnect between flow and rank. Paradoxically, sites that are ranked high don't always deliver a lot of hits when they link to you. On the flipside, there are some sites that are rarely on Top 100 lists, or talked about very much, that deliver substantial flow. Two of them stand out, one a veteran site, and the other a relative newcomer. 1. Daring Fireball is a thoughtful blog written by John Gruber that focuses on the Macintosh. Since I've returned to the Mac in 2005, and have been writing more about Mac issues, I've started getting links from this site, and when I do, they usually send between 1000 and 2000 readers my way. And they're generally interesting people with useful information and ideas. I follow Gruber on Twitter and have learned that he is a Phillies fan and therefore disappointed this year. His posts are interesting there too, and irreverent, which I like of course.  2. A Digg-like memetracker, news.ycombinator.com is in the same league as TechMeme, about 1000 hits for a highly ranked piece. I don't know much about the site, I'm not a regular reader, and I don't know much about the people who visit from this site.
466365
Cameron Olthuis wants to share the tools that he finds th emost useful with the entire web, so he's posted them here on his blog.   His list includes libraries from all different technologies, not just PHP. Several are Javascript-related, but it's always good to have a complete toolkit on hand when trying to tackle some of the more difficult things.   Included in his list are things like:  Moo.fx - a Javascript effects library Swat - an open source web application toolkit PEAR - the PHP package repository Mochikit - lightweight Javascript library    Be sure to check out the post and its comments for more great resources!
696609
On his blog, Stoyan Stefanov takes a look at using on of the most popular pieces of PHP forum software out there - phpBB - and optimizing the front-end.   During this short workshop there will be no changes to the phpBB code, we'll create a new template instead, so that in case something bad happens, your board will continue to work normally. As an example, I'll use the bgcanada.com/phpBB2, the board I volunteer to administrate.   The tutorial is broken up into sections:   The plan New subdomains Creating a new template Moving CSS to an external file, merging Copying files to the new subdomains Serving gzipped content Turning ETags off Expires header Sysadmin summary   It looks like a lot of steps, but each section is relatively short and written well so as not to have more information than needed. In the end you'll have a simple template that uses Yahoo's 14 optimization rules to make things work that much faster.
437157
The Zend Developer Zone has posted a review of Theo Schlossnagle's book from the Developer's Library series "Scalable Internet Architectures".   I had the pleasure of meeting Theo Schlossnagle at OSCON 2006. He gave me 30 minutes to peek inside his brain and do an interview. 30 minutes just was not enough time. So when I received his latest book in the mail I was excited. Finally a chance to get more in-depth on some of the topics we covered. I've taken the time to collect my thoughts for you here so you can decide whether this book is a good one for you.   Cal talks about how he hated the book (from a reviewer's perspective, not a developer), the contents of the book, and his personal favorite section - "Distributed Databases are Easy, Just Read the Fine Print". His only critism is that the book seems to come across in a "demanding" tone (misunderstood by those that don't know Theo's style as just being matter of fact).
104466
Matthew Turland has mentioned his article in the latest issue of php|architect magazine (the December 2007 issue) covering web scraping.   Just a quick post to announce (albeit a little late) that the December 2007 issue of php|architect, which includes my article on web scraping. Please buy a copy, give it a read, and feel free to post comments on the forum thread for the article. I'd love to hear some reader feedback!   Other articles in the issue include "Writing an Object/Relational Mapper in PHP", "Understanding CLI" and the cover story "Going native with mysqlnd".
448742
Kore Nordmann has written up some benchmarks of some of the more popular PHP image creation libraries testing their output times and results for generating the same image.   In my article series I showed several ways on how to create images with PHP, going into implementation details etc. Now I just want to provide a very rough overview on speed and quality of the extensions.   He ran them with some settings disabled to optimize things as they ran and came up with results pointing to Cairo being the fastest to generate and output the image. It also had the benefit of outputting an image with the highest quality of the five tested (Cairo, SVG, Flash and GD with and without supersampling). His benchmark code is also included.
585276
Before heading over to the Web 2.0 conference at the Palace Hotel in SF this morning, I couldn't resist doing some more digging into alternate user interfaces for news reading based on the NY Times keywords.  One thing I learned the hard way is that when you access the Times site from a script (not through a browser) if you try to read an article that's too old (not sure what the time limit is) it tries to redirect you to a login page (which is pretty pointless considering that there's no human being around to log in). I hit this problem yesterday, and then hit it again this morning, but couldn't remember what the problem was. So by writing it up this time I hope to remember.  No doubt some debunked hack journalist posing as a tech industry mogul will slander me for this, but the asshat asshole has no idea how blogging works, and who the fuck cares what he thinks anyway. "cheesecake"
674304
Mike Wallner has thrown together some stats for the latest edition of the pecl/http package to test its response performance.   The results surprised me, because it clearly shows that the performance drop for starting the PHP engine and doing the neccessary negotiation to provide caching is not that bad.   There's a chart of the results as well as a full PDF with all of the stats the graph maps out. He includes the legend to make the graph easier to understand.