Currently browsing php
Wed, 23 Sep 2009 20:32 UTC
I’m breaking a long and terrible habit of not blogging in order to share my experiences at CodeWorks over the next two weeks. As you may know, CodeWorks is a touring PHP conference that is traveling to seven cities. I’m privileged to be speaking in each of the cities.
My trip to San Francisco began on Monday, when the metro Atlanta region received up to 15 inches of rainfall in a 24-hour period. I think the average across the region was 8-10 inches, but the point is that we received a lot of water in a short amount of time on top of having already received a lot of rain over the course of the previous week. Over 200 roads were closed and interstate highways shut down. So, I made the decision to go to the airport on Monday night and spend the night there, despite the fact that my flight didn’t leave until ten the next morning. It was the right decision, since traffic the next morning was outrageous and roads were still closed, but it led to a very long day, since I did not sleep at all. Still, it allowed me to polish my slides for two very good presentations I gave today.
After a fine evening yesterday with friends at La Trappe, a Belgian Bistro and Trappist Lounge—with very good beer, I might add—I retired to sit around a fire pit at the hotel with even more friends. Keith brought along marshmallows for roasting, and Jason provided the beer. Good times were had by all.
This morning, while sleeping off the jet lag and recuperating from my lack of sleep the night before, I awoke to a call from Travis, asking if we could switch talk time slots. He wasn’t feeling well, so I agreed, and got up for the early 9am talk, but I’m glad I did. Now, my talks are over, and I’m going to spend the afternoon enjoying San Francisco. Travis, you owe me one, buddy.
Tomorrow, we head to Los Angeles, and after that, Dallas, Atlanta, Miami, DC, and New York. If you’re in any of these cities and you’re not yet signed up for CodeWorks, don’t miss a great opportunity to hear some excellent talks. Sign up today, and I’ll see you there!
FYI, for those looking for slides, I’ll post them on October 7th at the conclusion of the CodeWorks tour.
No Comments
Permalink
Tags: codeworks, conferences, cw09, php
Sat, 31 Jan 2009 3:42 UTC
When I was contacted by a representative of Packt Publishing to review RESTful PHP Web Services by Samisa Abeysinghe, I was naturally interested. After all, I’ve written and spoken a lot about representational state transfer (REST). But I was also skeptical because plenty of people these days talk about RESTful web services, but they don’t really explain REST.
Abeysinghe approaches the topic from a very practical level. From the very first chapter to the last, RESTful PHP is chock full of code samples and discussion of tools to access and build RESTful services. The problem, though, as Lorna Mitchell points out, is that ”[v]ery few services that claim to be RESTful actually are, which makes writing anything along these lines very tricky.” I agree. I would have liked to have seen a more critical look at the so-called RESTful services profiled in the book, with the author explaining the principles of REST by showing how the services examined are or are not RESTful.
In addition, the book devotes very little space to actually describing the principles of the REST architectural style. Instead, there is only a small section in the first chapter that lists some of the principles of REST in a bullet list. I say “some,” because the book fails to mention the principles of client-server, caching, layering, and code-on-demand. Of particular importance to me are the principles of caching and layering because I think these make for the most compelling arguments for using the REST style. Later, when the book tries to make a case for the need for RESTful web services, it talks only about the need for web services and why PHP programmers need to know how to consume REST services, rather than actually explaining why REST itself is important.
While my criticism of the author’s lack of focus on defining and explaining REST is harsh, I will return again to my point about the practically of the book’s examples. It is filled to the brim with working code examples that show how to consume Flickr, BBC News, Yahoo Maps, and other web services, and he discusses many tools to use as HTTP clients in PHP, from curl to Zend_Rest_Client. He also goes into much detail explaining how to design and implement RESTful web services, using a fictional library service as an example. In truth, the real focus on the book isn’t on REST but on the resource-oriented architecture, and to that end, he does offer some good discussion, even covering such topics important to the community as PUT vs. POST and URL design, nuances of design that REST does not cover. And, at the end of the day, what is really more important to a programmer who needs to quickly consume web services for a project: pragmatism or theoretical discussion? My bet is on pragmatism, and this book offers plenty of it.
So, if you’re looking for a full-fledged definition of representational state transfer, this book is not for you. Read Roy Fielding’s dissertation, if you want that. However, if what you’re looking for is a practical approach to consuming resource-oriented web services, then RESTful PHP Web Services is what you’re looking for.
3 Comments »
Permalink
Tags: books, php, rest
Sun, 25 Jan 2009 2:42 UTC
We’re well into the New Year—24 days to be exact—and I’ve long since been putting off this post, but it’s not really a single post. Instead, it’s a collection of things that I’ve been wanting to say but have been putting off, and it’s a look forward to things I’m working on, would like to see happen, or would like to be involved with this year. So, rather than the obligatory look back at what I did last year, this is a look forward at what I’m interested in for the coming year (in no particular order).
First of all, I would like to offer some congratulations to a handful of friends of mine. These congrats have been a long time coming from me and are already old news to many of you. In no particular order, I want to congratulate: Andrei Zmievski on being hired as an Open Source Fellow at Digg; Jon Tan on taking a role as the new Creative Director at OmniTI; Cal Evans, who moved to the Netherlands to be the Director of the PHP Centre of Expertise at Ibuildings; Marco Tabini and Keith Casey for launching Blue Parabola, and Matthew Turland for joining them; Eli White for accepting a position at Zend as the Zend Community Manager/Leader & DevZone Editor-In-Chief; and last, but not least, Brian DeShong for his promotion to Director of Technology at Schematic.
Next, I wanted to take a moment to mention and promote the writing I’ve been working on. I didn’t publish a single thing last year, and in 2007, I published only one article, so I resolved this year to get off my ass and remedy this. In February, php|architect will publish my article entitled “Grokking the REST Architectural Style.” This article attempts to explain what Representational State Transfer really is by going beyond peoples’ fascination with designing URLs, using XML, and focusing on HTTP methods. Instead, I’ll look at the real heart of REST with hopes that readers will fully understand what it means to build a RESTful application. A fellow web services aficionado said of the article, “I think you expressed very nicely what the concepts are all about—and without a URL or HTTP verb in sight!”
Following the REST article, in March php|architect will begin publishing my monthly column “From the Cloud.” In “From the Cloud,” I’ll be looking at practical web services you can use, as well as exploring trends that are transforming the way we use the Web. Here’s a quick blurb from the column that describes its focus:
As the Web matures and enters its third decade of life, many services are turning to cloud-based models of data storage. End users are becoming more and more comfortable with the notion that their data lives in the ether of the Internet rather than on their personal computers. Finding that data, retrieving it, manipulating it, and using it in meaningful ways are the challenges that face the era of the intelligent Web. I hope you’ll join me each month as we explore these services and technologies From the Cloud.
Finally, later this year, php|architect will publish another article I’m working on that will take a practical look at using HTTP in your applications in a RESTful way. There may also be a book idea or two in the works for me, but more on that later.
Oh, and I also had the privilege of being invited again to write a PHP Advent post during the month of December. I wrote a post entitled “Practice Safe & Idempotent Methods.”
Furthering my ramblings in this post, I also wanted to mention some community projects I’m working on this year. As always, I’d like to see PHPCommunity.org evolve and grow into a real website that offers real value to the PHP community, so that’s on my list of things to do. I’ll post more on that in the future. In addition, I have some plans for Atlanta PHP this year that include a new website, incorporation so we can accept donations, and an event to occur later in the year, but you’ll hear more from me about this as the details are finalized. Inspired by my own writings for the “From the Cloud” column, I’ll also be developing a PHP library of classes for interacting with various web services. This began with the Amazon Web Services library in PHP project, but I’ll be migrating that elsewhere to be part of a larger project in the near future, so be on the lookout for that.
Last, but not least, I wanted to mention the website that I built for my dad over the holidays. He recently launched his own business, Small Business Resource Associates, that provides services to small businesses and commercial real estate investors. I did all of the HTML/CSS and PHP programming for the website, while my aunt did the design work. It was an interesting project for me because I haven’t really touched front-end (client-side) web development in several years (I stick mainly to back-end, server-side development these days), and I was proud that I was able to make a website that validates successfully as XHTML 1.1. Another interesting part of the site is that it has a blog, something that I don’t believe many in the financial services industry are doing, so I think that’s one thing that sets apart Small Business Resource Associates from the competition. If your small business is looking for a loan, business plan, business consulting, SBA help, etc., please check it out.
Well, that’s a wrap. I’ve got a growing list of topics I want to blog about, so I hope that you’ll be hearing much more from me this year than you did last year.
Happy New Year!
1 Comment »
Permalink
Tags: atlantaphp, http, php, phpc, phpcommunity, rest, webservices
Sat, 3 Jan 2009 5:12 UTC
Started by Tony Bibbs (or maybe Marcus Whitney before him) and tagged by Elizabeth Naramore and Jon Whitcraft, I have succumbed to the 2009 blogging phenomenon known as “tagging.” Initially, I was going to ignore the tag, but when Elizabeth tagged me “just because,” I knew it was on.
So, here I am, writing the seven facts about myself. Happy, Elizabeth ?
- I was a youth minister for just over 4 years; I quit because I was burned out and tired of parents telling me what to teach their children; I have now become jaded and cynical of organized religion… maybe I’ll get better some day.
- I didn’t drink any alcohol until I was 21 (honest).
- I was in a short-lived, lounge-rock band in college called Not Quite Seven; we played mostly at Uncle Calvin’s in Carrollton, GA; our last show was at GA Tech in 2000—I played bass and sucked.
- My degree is in English Literature, not Computer Science.
- I go by my middle name, so consider “Ben Ramsey” a pseudonym of sorts and not my legal name.
- I taught myself to play guitar and hammered dulcimer, though I am long out of practice for both.
- My first program was written in BASIC on an Atari 400, and it was a Mad Lib generator that prompted the user for input (nouns, adjectives, adverbs, etc.) and plugged these variables into a story it printed out; I was 8 or 9 years old.
And now I get to tag people! Yay! Here are my tagees:
And here are the rules:
- 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.
No Comments
Permalink
Tags: meme, php
Fri, 7 Nov 2008 15:54 UTC
Next week, I’ll be speaking at php|works and PyWorks in Atlanta on Representational State Transfer (REST). My talk is in the general track this time, so it’s good for both the PHP and Python audiences who will be attending the conference.

I’ve already invited the Atlanta PHP community, and if you’ll be in the Atlanta area, you should come, too. I can’t say it enough: the price of this conference compared to the value you receive from the talks and networking is a steal! In addition, if you sign up for the tutorials, you get a free training course at php|architect. You really can’t get a better deal at any other conference. I guarantee you’ll be glad you attended.
1 Comment »
Permalink
Tags: atlanta, atlantaphp, php, phpworks, pyworks
Mon, 3 Nov 2008 20:41 UTC
I usually don’t announce Atlanta PHP meetings from my blog, but given the short notice, I figured that greater exposure would be best, so here we go…
When: Thursday, November 6, 2008—7pm-9pm
Where: Consulate General of Canada
November Topic: Got a problem? We’ve got answers!
Got a bug that’s been nagging you for hours? How about a feature that you just can’t seem to implement? This month at Atlanta PHP, we’re diverging from our usual presentation format and opening the floor for a “round table” discussion about development problems you are facing.
So, feel free to bring your coding problems to us, and as a group, we’ll come up with the solutions. Bring your laptop or a thumb drive containing snippets/samples of your code or application, so we can look at it as a group. This is sure to be a learning experience for us all.
Our meeting takes place at the Consulate General of Canada at 100 Colony Square in Midtown Atlanta (at the corner of Peachtree and 14th Streets). Click here for directions. You will need to see the concierge in order to gain access to the 17th floor.
PHP Basics at the Atlanta Web Design Group Meetup on November 11
On November 11 at 7:00pm, Matthew Turland will speak to the Atlanta Web Design Group about PHP, covering basics of the language and best practices from a designer’s perspective. This will include basic output, variables, conditional branches, loops, output modularization using includes, coding style, and escaping output for security purposes.
Matthew is the Lead Programmer for a Web application service provider, is Zend PHP Certified, and works with PHP and MySQL on a daily basis. He’s also a member of the PHP Community organization and serves as an organizer for the Acadiana Open Source Group. You can also read his blog at http://ishouldbecoding.com/.
There will be a 30-40 minute presentation followed by Q&A and discussion.
You must RSVP at Meetup.com for this meeting.
php|works and PyWorks in Atlanta November 12-14!
Atlanta PHP invites you to join us at php|works and PyWorks in Atlanta, GA November 12 through 14!
Atlanta PHP user group members receive $100 off the price of registration!
The publishers of php|architect and Python Magazine, are proud to invite you to php|works and PyWorks, two great conferences that will take place in Atlanta, GA, USA, between November 12 and November 14.
With over 65 talks in 5 tracks, 10 tutorials and great networking events and parties, php|works and PyWorks represent a unique opportunity to not only hone your technical skills, but also meet and interact with members of a vibrant community of developers from all walks of life. And remember—your attendance fee covers access to both conferences!
No Comments
Permalink
Tags: atlanta, atlantaphp, php, phpworks, pug, pyworks, user-group
Tue, 16 Sep 2008 23:25 UTC
See below for the slides from my Distribution and Publication With Atom Web Services talk given at the 2008 Zend PHP Conference and Expo in Santa Clara, CA.
As we move toward “Web 3.0,” the Web is slowly transforming into a platform upon which massively distributed applications run. Rich clients turn personal computers into thin clients, not storing or processing any data locally but, rather, connecting to a web service where the data resides. These services may target intranets, extranets, or the global Web community, but to work they need a common language. One such language is the Atom Publishing Protocol.
Since its inception as a draft recommendation in 2003, the Atom Syndication Format (RFC 4287) has been used as an alternative to Really Simple Syndication (RSS) feeds on blogs throughout the blogosphere. Most have understood Atom as just another feed format, but the publication of the Atom Publishing Protocol (RFC 5023) opens the door for far more uses of the Atom format as both a means for distribution of data, as well as publication.
Ben Ramsey will introduce the Atom Syndication Format and Atom Publishing Protocol, explaining in depth how these can form the foundation of any web service for publication and distribution of data in any environment, from the enterprise right down to the small business level. Ramsey will also discuss RESTful design principles as they relate to the Atom Publishing Protocol.
2 Comments »
Permalink
Tags: atom, atompub, http, php, presentations, rest, talks, zendcon, zendcon08
Sun, 14 Sep 2008 19:06 UTC
As I write this post, I’m sitting at about 38,000 ft on a Boeing 757-200, flying high above the now tropical storm Ike. My destination is Santa Clara, CA and the Zend PHP Conference and Expo.
This year, I’m giving a talk at the main conference, as well as moderating a discussion at the ZendCon Unconference, coinciding with the main conference. While it’s a shame that Zend does not open up the Uncon—perhaps even for a small fee—to the general public (you must be a registered ZendCon attendee to attend the Uncon), it is good that they’re opening up the space for anyone attending the conference to share ideas through presentation and discussion in an open forum. The Uncon is the community space and the place to be if you want to engage the PHP Community while at ZendCon.
The “round-table” discussion I’m moderating at the Uncon is titled—with tongue firmly planted in cheek—“PHP Developers’ Groups: Cat Herding 101.” User group leaders and volunteers will likely agree with me that organizing meetings often feels like herding cats. This discussion is primarily for user group leaders and volunteers, but it’s not exclusive. It’s open to everyone who would like to listen, learn, and participate in discussion about planning for user group meetings and events, and how to reach out and communicate with your user group members and the local developer community in your area. If you’ve ever had an interest in starting a user group, by all means, please be sure to attend! The user group discussion will take place on Wednesday, September 17th at 5:15pm in the Uncon space.
At the conference proper, I’ll be giving my “Distribution and Publication With Atom Web Services” presentation. This is the second time I will have given this talk, and it has been greatly improved since I gave it at DC PHP earlier this year. The previous incarnation of this talk was geared more towards developers, but this time, I think the presentation will be of interest to both programmers and managers alike, since I not only describe in technical detail how Atom works, but I also give high-level information explaining how Atom Web Services may be beneficial to your business or organization. I make the case for why Atom is important for any application that distributes or publishes content.
As for the remainder of the day today, I’ll be hanging out in sunny California, possibly taking a day trip into San Francisco to walk around and sight-see.
Hope to see you at the conference!
1 Comment »
Permalink
Tags: php, zendcon, zendcon08
Tue, 9 Sep 2008 19:55 UTC
After a long hiatus and a very quiet mailing list and forum, I am delighted to announce that the main communication channel for PHP Groups is moving to the official PHP project at php.net!
You may recall PHP Groups being created over a year ago for the purpose of networking together the leaders and organizers of PHP user groups around the world. I’ve been very bad about keeping things moving on this front, but I want to pick things back up and get us talking again. I also want to get us back on track for the mission of this group:
PHP Groups networks PHP user groups into a tighter community, provides a means to share information and resources among its community members, and aids in the formation of new PHP user groups.
In the near future, we’ll have more discussion about what we can do to progress toward fulfilling this mission.
In the meantime, if you help with the organization of your local PHP user group in any way, feel free to join the ug-admins mailing list or subscribe to the ug.admin news group at php.net:
ug-admins-subscribe [ at ] lists.php.net
news://news.php.net/ug.admins
Also, look to this list for announcements about meet-ups of user group leaders and organizers at upcoming conferences!
And, as always, I’m lurking in #phpgroups on Freenode IRC, so feel free to join me, if you like.
No Comments
Permalink
Tags: php, phpcommunity, phpgroups, pug, user-group
Wed, 4 Jun 2008 16:32 UTC
As promised to the attendees of my talks, I have posted the slides for my presentations on SlideShare.
Distribution and Publication With Atom Web Services
The Web is transforming into a platform for distributed applications. Rich clients connect to web services to retrieve and store data. The Atom Publishing Protocol provides a common language for these services. Ben Ramsey introduces AtomPub, explaining how it can form the foundation of any web service for publication and distribution of data for enterprises down to small businesses.
Give Your Site a Boost With Memcache
Today’s high-traffic websites must implement performance-boosting measures that reduce data processing and reduce load on the database, while increasing the speed of content delivery. One such method is the use of a cache to temporarily store whole pages, database recordsets, large objects, and sessions. While many caching mechanisms exist, memcached provides one of the fastest and easiest-to-use caching servers. This talk will cover memcached and the memcache extension for PHP from setting up a memcached server to using it to provide a variety of caching solutions, including the use of memcached as a session data store.
2 Comments »
Permalink
Tags: atom, atompub, dcphp, memcache, memcached, php, presentation, rest, roa, talk