Archives For about

I’ve been reading the book Technical Blogging, by Antonio Cangiano, over the past couple of months and am glad that I am. I’m reading it in the hopes of improving the quality of (and, potentially, income from) this blog, and I think it will pan out. Continue Reading…

Interview Posted Online

April 4, 2011

Sayyid Alireza Hoseini of bugX.ir recently conducted an email interview with me, that has now been posted on bugX.ir. In case you don’t read Persian, here’s the English version of the interview:

1- Where are you living?

I have lived in the United States my whole life, and currently live in the state of Pennsylvania.

2- Are you working in any special company?

I’ve been working for myself since 1999, although I’m technically incorporated.

3- If you were a person who was chosen to write a secure web service, what would you use to write your web service – PHP, ASP.NET, Zend, etc?

PHP is my first language of choice. I have worked with ASP.NET (in C#) and think it’s pretty good, but it requires Windows to both develop and to run, which is a problem for me. I like aspects of the Zend Framework, and occasionally use it piecemeal, but don’t use it extensively or exclusively. If I were to write a secure Web service today, I’d do it in straight-up PHP.

4- Have you been working on any new book lately?

Yes, thanks for asking! In the fall, my most recent new title came out: “Effortless E-Commerce with PHP and MySQL” (New Riders). The fourth edition of my “PHP for the Web: Visual QuickStart Guide” just came out in March 2011 (Peachpit Press). I just began writing the fourth edition of my “PHP and MySQL for Dynamic Web Sites: Visual QuickPro Guide” (Peachpit Press), which should be published around August 2011. (All dates are for the English language publication in the United States; availability elsewhere will follow.) In 2011, I’m also going to try self-publishing, starting with a book on JavaScript.

5- Nowadays programming is lot easier with current frameworks than a couple years age, some programmers prefer to use frameworks like CodeIgniter, Zend, etc. Do you prefer working with these frameworks, why and why not?

I’ve never used Kohana or CakePHP or CodeIgniter, although I’ve heard good things about them all. In 2006, I started using Ruby on Rails and like it a lot, although I don’t normally use Ruby for Web work. In 2009, I discovered the Yii framework and fell in love. It’s a great framework for PHP developers. I have used, and still use, the Zend Framework, but just don’t care for it as the basis of an entire Web site.

6- Could you tell us one of your greatest programming experiences which you had?

I can think of two important experiences, years apart. I tend to think of the greatest programming experience being the most recent one, or one of the most recent ones, in that one should always be improving as a programmer, meaning the work you did yesterday should be better than the work you did the day before. I have a client that I do a lot of work for and one of the best things about this client is that he gives me free reign to use the tools or approaches I think best. The project itself, a Web site, wasn’t extremely complicated, and I wrote the heart of it using the Yii framework. This provided quick development time, complete CRUD control, secure forms, and solid access control. One aspect of the site required dynamic PDFs as output, so I used the PDF module from the Zend Framework (within the context of a Yii-based site) to handle that. Part of the administration was complicated enough that I didn’t think Ajax and jQuery was the right solution, so I used Flex to create a Flash application for that particular part of the administration, with Web services provided by Yii. None of this was revolutionary or extraordinarily advanced, but reinforced my belief that there’s never one “always right” tool for the job. It’s best to have lots of tools in your toolbox so that you can choose the right one for the task at hand.

Another important experience happened ten years ago and wasn’t a programming one, but rather a business one that greatly impacted my programming career. I worked with a small team of people on a startup project. It was a very good idea, reasonably financed, and well marketed. Unfortunately a site that should have been successful never was, in my opinion, because of a lack of good leadership. I learned two important things from the experience. First, just having a good idea, or even executing a good idea, does not necessarily mean it will be successful. Many factors go into success, only some of which are under your control. Second, if I’m going to spend my time working for free on a project in the hopes it succeeds, it has to be my project. There’s just not enough time in the day to spend it trying to create someone else’s vision.

7- What other affairs do you do on your free times?

I used to like to read a lot, mostly fiction, and see movies. I’m also a big fan of many sports. In 2006, my wife and I had twins, so pretty much all of my free time since then is spent being a dad. Which is a pretty good gig, all in all.

Time for a Big Change

October 30, 2010

For quite some time, at least a year or more, I’ve been meaning to redo my company’s Web site (www.larryullman.com). Sadly, even though I largely write about and do Web development, my own site is always the last one that I work on. Now that I’m between books, I actually have the time to get to my own neglected site. I’m happy to say that the new version of the site will go live this weekend, but there’s more. First, a little background…

Digital Media and Communications Insights, Inc., the company that I work for, and am a very minor owner of, was founded by my in-laws as a vehicle for my father-in-law’s telecommunications consultancy. In 1999, I started by own “branch” of the company, doing primarily Web development, training/teaching, and, of course, writing. In the past decade, my father-in-law retired and although I sometimes hire individuals for project work, yours truly is the company’s only true employee today. Thanks to the success of my books, and later the blog, the Web site gets a decent amount of traffic (north of one million hits per month), and I think it is safe to say that pretty much no one cares who or what DMC Insights is. Visitors want to download the code for a book, visit the support forum, email me, and maybe even hire me to work for them, but the existence of DMC Insights really doesn’t factor into the equation. In revamping my company’s Web site, I’ve often considered dropping the company facade and just putting my name front and center (my apologies if any of this sounds egotistical). Serendipitously, the domain name www.larryullman.com just became available this month, after being owned for the past ten years by a Canadian gentleman, named…Larry Ullman. I am now the proud owner of my namesake domain and have been busy creating a new look for it. The new version of the site is now ready to go (or ready enough!), so this weekend I’ll be instituting redirects on www.larryullman.com to direct all traffic there (unfortunately, half a million books are in print with my company’s URL on them). Hopefully this will be a smooth process, but there will inevitably be something that I missed.

I hope that everyone likes the new site once it’s up and, as always, I gratefully welcome all thoughts and feedback on what I’ve done.

In this edition…

About This Newsletter

So it’s been about six weeks since my last newsletter, or roughly twice as long as I normally hope I get these things out. The cause for the delay is simple: I’ve been working night and day on my forthcoming “Effortless E-Commerce with PHP and MySQL” book, trying to make the end-of-this-month deadline. I don’t think I will, but it’ll be close. Anyway, this newsletter has some stuff about that book that you may be interested in, along with a couple of other notable things I’ve found online. I went looking for some good questions to answer in this newsletter, but didn’t have any set aside, so if you’ve got a question you’d like me to answer in a future newsletter, including one you’ve previously submitted but I apparently ignored, please send it along. As always, thanks for reading and for your interest in my work!

On the Web => First Example Site for “Effortless E-Commerce with PHP and MySQL”

My “Effortless E-Commerce with PHP and MySQL” book has four parts to it. In the first part, there are two chapters of general information: one on the process and another on security. In the second part, I develop an entire e-commerce site. In the third, I develop a second e-commerce site. In the fourth, I discuss and demonstrate additions you could make to both sites. My original intention was to get all the code done (at least for Parts 2 & 3), and then start writing. As with all good plans, this is not how things went. But I’m happy to say that the first example site is complete, as are the first six chapters of the book (the first draft of those chapter, that is).

If you’re interested in the example I came up with, you can check it out online at http://ecom1.dmcinsights.com. This is a fully functioning, live version of the site, complete with registration, login, password management, content managment, and PayPal integration. The PayPal integration is currently done using PayPal’s Sandbox (i.e., their test system), so you can even pretend to pay for site access.You can also download the source code for the site, if you’d like to get a look at what the book will discuss. The source code is fairly well documented, so you should be able to get a sense of what I’m thinking through that.

On each page of the online site (this isn’t in the book) is a comments form for you to raise questions, make suggestions, and so forth. I would love to get as much feedback and as many points of view as possible. I’ll also give away a few copies of the book specifically to people who’ve submitted commments.

I’m working on the second site example now (well, as soon as I send this newsletter out) and will make that available when it’s ready.

On the Web => Rasmus Lerdorf’s No-Framework PHP MVC Framework

Some years ago, Rasmus Lerdorf, original creator of PHP, posted on his personal Web site a discussion of what he would look for in a framework for the MVC architecture. It’s an interesting read, from the master’s voice. He specifically talks about how to properly use MVC, how to guarantee performance and security, and how to design with scalability and flexibility in mind. Although the post is a few years old, most of it is still valid, with only little changes such as the fact that the PECL/Filter extension is now part of PHP proper.

On the Web => ServInt: Customer Service Done Right!

I’ve been using ServInt for my Web hosting for some time now (three years, I think) and could not be happier. In the past eleven years, I’ve probably had five hosts, ranging from the really cheap and totally awful to the not-that-cheap but still rather awful. For me, finding a Web host that I can rely on has been a huge weight off my shoulders. One thing ServInt does right is that they only do high-end hosting, starting with VPS (Virtual Private Server) and going up to dedicated hosting. What they don’t do is put 50 clients and hundreds of domains on a single server, which is what the cheap hosts do. Don’t get me wrong: cheap hosting is fine for many people, especially with small projects and new ones, and in many cases spending only a few dollars a month makes sense. If you’re just learning Web development today, you should probably start with a cheap host.

By comparison, I’m using the most basic ServInt plan and it’s running me $50/month (US). But, again, that peace of mind… The other thing that ServInt does right, which is the bigger deal, is their customer service. They respond immediately to concerns of mine and often help out on things that aren’t really their problem (i.e., when I screw up). Moreover, ServInt has just, for at least the second or third time since I’ve been with them, opted to provide more services at no additional cost. I received an email a few weeks back indicating that my basic account has been upgraded from 30GB of storage to 50GB (which, frankly, I needed, as I was at about 28GB and thinking I’d need to start weeding through my drives). ServInt has previously upgraded the storage before, as well as the RAM and bandwidth allotments, so this isn’t entirely surprising but is still a fantastic thing to see.

I’m not writing this in order to sell you on ServInt (although I can definitely recommend them in good conscience) but rather to highlight an example of excellent customer service. Good customer service properly fixes problems when they arise. Great customer service does so nicely, promptly, and with a little extra. Excellent customer service prevents problems from happening in the first place and provides extra services at no additional cost. I’m not a marketing guy by nature, but I know that ServInt has my business for the long run because of things like this. And just as I’m writing this, I’m thinking that if times were tight financially, if I had a little extra free time, and if I was looking to improve my business, I might go back to some of my clients and offer something for free, too, such as doing a bit of software upgrading or adding a feature they wanted but couldn’t afford. I’m sure that’d make an impression and generate more business in the long run. Once they accepted that you weren’t trying to scam them, that is!

On the Web => Geek Humor

I came across this cartoon, which is funny in a geek-y way, and thought I’d share: http://xkcd.com/327/

On the Blog => Yii-related How-To’s

I wrapped up my fourth Yii-based site a couple weeks back (although I’m still making minor tweaks per the client’s requests) and I’ve been doing some consulting for a client that’s learning to use Yii for his projects, so a number of my blog posts as of late have been about Yii. If you look under the Yii tag at my blog, you’ll see articles on:

  • Handling Related Models in Yii Forms
  • Handling Checkboxes in Yii with non-Boolean Values
  • Forcing Login for All Pages in Yii
  • Caching the Database Schema using MemCached with Yii

These are just the most recent articles I’ve written on Yii. There are some older ones about authorization and authentication, plus my original eight-part series on learning Yii. Perhaps next year, depending upon how my experience in self-publishing a JavaScript book goes, I’ll self-publish a guide to Yii, as I’ll have informally written a book on the subject by then!

On the Blog => “Effortless E-Commerce with PHP and MySQL” Updates

I recently published an update on my “Effortless E-Commerce with PHP and MySQL” book. The update reflects the actual Table of Contents for the first five chapters of the book, based upon the rough draft of them. You can also learn a bit about the content of each. I’ll probably post another update in about two weeks.

What is Larry Thinking? => Teaching, Not Selling

My blog has gotten a lot of attention over the past several months because of my series on the Yii-framework (on the Yii’s documentation page, the first link for learning Yii is to my series). I’m glad people like what I’ve written and feel like it’s a good way to learn, as it makes the work I put into the blog meaningful. However, I’ve been surprised to get a percentage of questions along the lines of “Why should I use Yii?”, even though that is a resonable question. But I also get the less reasonable “Why should I switch to Yii from XXX framework?” or just “I can already do these things much more easily using XXX.”

Asking about the benefits, which is also to say the strengths, of any new technology is natural. As a person writing about certain technologies, I feel that it’s part of my job to cover this side of things. But there’s a line between teaching and selling that I don’t cross: it’s never my goal to talk someone into using X or Y; my only aim is, if you want to learn X or Y, to make that learning process smoother. I have opinions about Yii and jQuery and Ruby/Flex/AIR/Mac OS X/PHP/MySQL/just-about-everything but I don’t care whether people do or do not use any particular technology (and I don’t mean that to sound harsh). What I do care about is, if they are trying to learn X using my writing, that my writing is helpful in that regard. In short, there’s a large part of who I am that’s a teacher, but I don’t have a selling bone in my body.

So the answer to a question about using Yii, or using Yii instead of, say, Zend, is that I think Yii’s approach makes sense to me, I like that it autogenerates code for you, jQuery is built-in, and that Yii is easily extendible. My answer to a question about why someone should switch to Yii is I don’t know and/or maybe you shouldn’t. I think people in this industry get hung up on what’s best or, even worse, what’s hip or new (“Web 2.0”? Ugh!). Or they feel like the announcement of or praise for something different is in some way an affront to what they’re currently doing. This is all immaterial. At the end of the day, the only question that really matters is: does this work for you? And that’s a question I can never answer, except to say “Maybe give it a whirl and see for yourself.”

Book Giveaway=> “Effortless Flex 4 Development” Update

There was a great response to my “Effortless Flex 4 Development” giveaway and I think I made many people happy with the free copies they got. Everyone should have received their book by now (actually, a couple of weeks ago), so let me know if you didn’t get yours. I have a couple more copies left that I’ll give away in a future newsletter.

Larry Ullman’s Book News => “Effortless E-Commerce with PHP and MySQL”

As you can tell, pretty much all of my time these days is being spent on the “Effortless E-Commerce with PHP and MySQL” book, which is coming along nicely. After doing recent books on Flex, Ruby, and Adobe AIR, it’s nice to get back to my programming roots. And as people have been requesting this book for years, and as I should have written it last year, it’s great to get this done. My hope is to wrap up the rough draft in very early September, meaning the book should be out in October. The book will also be put online via Peachpit’s Rough Cuts series, and I’ll post that URL once I know it.

I received a lot of interest, in response to my previous newsletter, about my planned self-published JavaScript book. I’m happy to see such interest, because it’s going to be a lot of work! Many people also volunteered to help proofread the text and test the code, which is wonderful and extremely generous. One thing I’ve learned writing books all these years is that having more people look at the book makes it better. It’s not a case of “too many cooks spoil the broth”, it’s more a matter of lots of tasters provide great feedback!

I’m also talking to Peachpit Press about doing the fourth editions of my “Dynamic Web Sites with PHP and MySQL: Visual QuickStart Guide” and “PHP for the Web: Visual QuickStart Guide” books. Both will be published in 2011, updated for the latest versions of PHP and MySQL (and dropping the PHP 6 moniker, which is thoroughly dead in the water). Per repeated requests, I’m also going to integrate a page or two of questions, suggestions, and exercises at the end of each chapter. Right now, it looks like I’ll write the fourth edition of “PHP for the Web: Visual QuickStart Guide” this fall, so that it’s published in early 2011.

My series on Learning the Yii Framework has been getting plenty of attention, largely, I’m sure, due to the fact that the official Yii documentation references it first, being “best suited for people who just start with MVC and/or Yii programming”. Most of the comments I’m seeing are just complimentary or are asking for assistance in getting something to work. However, I’m getting a few questions along the lines of “Why should I use Yii?” and “Is Yii better than XXX framework?” I guess these are natural questions, but here’s the thing: I’m not a car salesman. I have absolutely no interest in convincing people to buy things. This even goes for my own books, which is the primary basis of my income: I’m not going to try to convince anyone to buy my books. I just don’t have that gene in me. Make no mistake: I would like you to buy my books (multiple copies of each, preferably), but I want you to buy my books because you want to, and because they’re good books, not because I’ve talked you into it. This is true for hiring me to do work. I’ve always had a policy that I wanted companies to hire me again for future work because they want to, not because they have to (tangentially, a hallmark of a good application is that anyone qualified could step in and work with it; I don’t handcuff the client into bringing me back in for any future changes).

I’m thinking about this now because someone just posted a question that included “Can you argue why I should choose Yii for my next project?” And the answer is “No, I can’t. In fact, I won’t even try.” Use Yii or don’t use Yii based upon whatever criteria you use to decide this things. All I’m trying to do in my work is explain how to use Yii, should you want to. And the answers to “Is Yii better than XXX framework?” include “I don’t know (because I haven’t used XXX).” and “Maybe, maybe not.” and “Probably in some ways and probably not in others.”

Yii works for me, for its pretty good documentation, its jQuery support, its auto-code generator, and more. For different reasons, PHP works for me, as does Adobe AIR and Flex and … These are technologies that I’ve found a use for and that appeal to how I think and work. It doesn’t mean that any of them are for everyone, let alone better than X, Y, and Z. So I’m never going to try to convince anyone that this is better than that. What I will do is explain how to use this and probably mention what I like about it. If you prefer that to this, fine. Maybe that’ll give me incentive to check out that, too. On that note, I will suggest that you always consider trying new things, even if you’re happy with what you’ve got. That’s how we learn and how we make progress.