Jun 14 2010

SEO = voodoo

Pavel Lutskovsky

I admit, every time I see the word SEO, I think of some witch doctor sticking pins into a doll or spitting rum on a bundle of spices. I know my aversion to SEO isn’t unique and not unfounded. The mix of voodoo and marketing probably irritates a good amount of developers who prefer solid science to fancy claims. SEO takes the focus off the user and puts it on Google. Big mistake.

First things first: no amount of SEO will help a bad product. A poorly functioning site, or one with a bad user experience or one that is unattractive will quite likely be harmed by being easily found in a search engine. My clients with an immediate interest in SEO instead of developing their product have all heard this lecture — the more people see this mess, the more people will never be back. Premature search engine optimization is evil. Product first.

“Those who can, do. Those who can’t, seem to always work for SEO companies.”

That being said, I tend to see SEO as a product of two things – the implementation of the site and the process of promoting it. The implementation is the easy part, summed up with primum non nocere. A well-implemented site following current standards is all that’s required. A quick run through the W3C validator will show where the flaws are. In the dark ages of web development, the marketing wizards even went so far as to claim that certain HTML elements (tables, I’m looking in your direction) were somehow bad for SEO. Of course, this is bullshit. The top search engines all have great parsers that don’t choke on nested tables. But they do take note of invalid and outdated elements, unclosed divs, etc.

The second part to SEO, probably 90%, is not a product you pay some offshore marketing firm for, nor an AdWords account. It’s a process. Once you have a good product and are ready for people to use it, promoting it is only natural. But stuffing keywords into the meta tags, adding alt tags to images, stuffing the title attributes of links, etc is an exercise in wasted time, money and can get your users to leave your site in a hurry.

Here are my alternatives to the voodoo of SEO:

1. Sell to people you know

Before the web, when you wanted to sell a product that you knew was good, you talked to your friends and family and if they liked it, they would talk to their friends and family. Let that be your start with your web product/application. If your friends and family aren’t interested, chances are no one else is either. Go back to the drawing board. There’s something fundamentally wrong with a product that requires extensive marketing to get people interested. If it’s not obviously appealing, doesn’t solve real problems or doesn’t interest the target audience, it’s a bad product. SEO, in this case, is lipstick on a pig. Waste your money on marketing instead of reworking the product and you’ll guarantee abandoned visits.

2. Communicate with real people

Yes, it takes work and yes, the results aren’t immediate. But they are real. Connecting with people face to face (no, not on discussion forums, not on twitter, not on Facebook) and getting them interested in your product is effective. If you can’t be excited about your site/application/product in front of a potential customer, it won’t sound sincere online either. And if you’re not excited about your new app/site, no one else will be either.

3. Become an expert

With minor exceptions, you should probably be an expert in your field and be seen as such by others. Be it photography, mining, gardening, basket-weaving, event scheduling, or whatever your product addresses, you should be very good at it. If you already have the non-skeptical users in the bag (friends, family), the next group of people you’re trying to attract are the skeptics. They don’t want to spend their time and money on your site if you don’t know your field. If there are discussion forums or blogs in your field, you should know them, follow them, be actively contributing to them and possibly have one of your own.

buy dianabol

This is not a prescription for a successful site. It’s just a common-sense process that costs absolutely nothing. No client of mine has ever wanted just clicks or visits on their site. They wanted a way to interact with their customers, current and potential.

If you’re after clicks, by all means, play the Google game. Hand your $500 to some SEO quack who will give you a vial of snake-oil that rockets you to the top of a search-result set. Then, give Google your credit card number so you stay up there week after week. You’ll get lots of unique visits, few repeat visits and very few sales. Once people figure out that you’re only invested enough in your product to part with your money and not your time they’ll take their money elsewhere. Once your money runs out, you’ll quickly descend into the ranks of açai berry peddlers on page 4 of Google’s search results and you won’t have to worry about people abandoning your site.

Rant over.

pure omega 3 fish oil

Jul 30 2009

NetBeans – a PHP IDE for the VS crowd

Pavel Lutskovsky

I know I’m not the only PHP developer on the planet who despises Eclipse, refuses to pay for Zend and thus does most of their development in some text editor devoid of the basic conveniences of an IDE. At the same time, I’m not the only PHP developer who spends quite a bit of time in the .NET world being spoiled by VisualStudio and ReSharper’s conveniences.

I’m sure this makes me a Microsoft sellout on many levels, but I’m not ashamed to admit it. Visual Studio (despite its many flaws) is the best IDE I’ve ever used. No it is not perfect. Yes I curse at it daily (no different than the mechanic cursing a wrench he’s used for years). But I get my job done. I don’t have to jump through too many hoops to do it. I just need an average machine with Windows.  The combination of Visual Studio with ReSharper is what allows me to stop worrying about using software and focus on writing good clean code. Yet for my PHP work, I’ve been stuck to Notepad++ and vi for too long.

Since I paid quite a bit for VisualStudio, I’m not too interested in dropping a lot of money on another IDE, so for the purposes of this comparison, I looked at free products.  Until recently, my choices came down to decent but not user-friendly IDEs in the Aptana/Eclipse vein, half-baked free IDE versions of a paid product (Komodo) or a simple text editor.

For small things, Notepad++ and vi are still my go-to tools.  But for the big stuff, the glamor (or lack thereof) of being known as the guy who codes in Notepad++ is finally gone. Good riddance. Since picking up NetBeans 6.5 in RC mode I haven’t looked back. Bottom line: NetBeans gives me an IDE where I can focus on my code rather than on learning how to use some oddly designed beast (Eclipse).  Yet, being an IDE, I have the conveniences I’m used to from my .NET development.

Here are a few of my favorite things:

  1. Code completion – all IDEs have this, but NetBeans is better for someone used to VS.  Full documentation for standard functions and linked files is made available with a simple keyboard shortcut.  Aptana’s and Eclipse’s default code completion is laughable. Just listing the name of the function?
  2. File browsing – just like in ReSharper, hitting a simple keyboard shortcut (Ctrl-O) to browse by type (and it takes CamelCase, whoohoo!) makes moving around in a large project incredibly easy.  The completion also takes into account linked code (i.e. PEAR, CakePHP, CodeIgniter) types.  Ctrl-Shift-O lets me browse by filename.  No more hunting for files across library directories. Ctrl-Alt-Shift-O browses by method.
  3. Search usages – surprisingly, even the shortcut is the same as my ReSharpered VS installation, Alt-F7.  I get a list of every instance of the variables usage across the project.  No more grepping and checking context to see if it’s really a different variable by the same name.
  4. Code walking – Ever since my Delphi (Borland studio) days, I’ve found Ctrl-clicking a variable or type to go to declaration indispensable.  VS doesn’t do this by default, but thankfully the guys behind ReSharper thought of this.  To my surprise (or are they reading my mind?), the guys at NetBeans did too.  Clicking a function’s usage takes me straight to its declaration.  What could be simpler? Aptana, take note, when I accidentally click on “require_once”, don’t take me to the file that’s being included.
  5. Decent javascript and CSS support.  I don’t spend a lot of time on them since I mostly do backend work, but it’s nice to know code completion, documentation and even CSS preview are available.  These are not my strong suit and it’s nice that NetBeans gives me a crutch with them.

To be fair, NetBeans isn’t perfect.  The CamelCase support for type browsing, CakePHP support and the SVN plugins could be improved.  Still, it’s the best free tool I’ve seen.  It fits my needs, as a guy who spends at least 40 hours a week staring at Visual Studio and wondering why PHP IDE’s are so far behind.

Apr 29 2009

The INTJ and You

Pavel Lutskovsky

Yes, there’s a bit of arrogance in publicly describing my arrogance or introvertedness, but I feel it’s a necessary step.

Scott Hanselman’s latest sparked me to write this when he mentioned his Myers-Briggs type in his latest post on tact.  The problem with people is that we’re all so different that even our understanding or even perceptions of the same behavior are completely different.   I would probably arrive at the same exact conclusion Scott did about the bad taste presentation.  But probably for very different reasons.

A couple years back, I worked for a pretty cool company that had a (novel to me at the time) way of dealing with teams — everyone took a personality test and everyone on the team had the results of every other member of the team.  I was a young arrogant developer seeing absolutely no purpose to this exercise: I just wanted to write code.  Then I learned I’ve been cursed with INTJ;  my project manager and the QA also learned about my curse.  Here’s the kicker: any friction I’ve ever had with QA and my project manager VANISHED. Overnight. They understood my quirks, my habits, my approaches, my strengths, my weaknesses and how I saw other people’s roles in my life.

So, on that note, after reading the INTJ description, Hello, I’m your friendly neighborhood INTJ.

I have already judged you.  No, I won’t tell you what I’ve decided about you and yes, that judgment can change if you give me more data.  If I think you’re a fool, the worst you can do is open your mouth and prove it.  Then you might as well not exist.  If I admire you, you won’t have to work too hard at keeping that.  But I have my limits and they’re pretty rigid.  If you cross them, you may not find out right away.  That’s my problem, not yours.

I can work hard. But I choose not to unless there’s a reason.  If there’s a more efficient way to do something, I can spend a ridiculous amount of time looking for it, often longer than doing something the less efficient way.  I can learn more, but unless I really want to, I will not.

I will not indulge your idle chit-chat unless we’re already good friends.  If you just met me and are trying to tell me about your cat’s “cutest noise” or why your wife’s cousin shouldn’t be involved with someone I don’t know, you may get silent treatment.  For a while.  A couple weeks at least.  I expect you to figure it out on your own.  But you probably won’t.  That’s my problem in expecting you to be like me, not yours in not being like me.

Yes, I am fully aware how terse, arrogant and cold the above makes me look.  No, it does not mean the same thing to me as it does to others.  Yes, I know how you perceive me.  No, I will not change for you.  I may change for me. If you are good friends with me, you have seen a much softer caring side.  If you are not, you may have observered it toward others, but not you and have felt like I’m intentionally being a jerk toward you.  You are wrong.

If you’ve worked with me, you may have seen me at my worst — completely detached from personal relationships, looking almost angry, etc or just the opposite, 100% unfocused, entertaining lazy ideas and surfing the net.  This is either because I’m focused or bored.  If you ask me about it, that is what I’ll tell you.  This is truth.  Question it and you will get the same answer.   You may have seen me at my best too — turning around impossible deadlines, finding bugs that others have been trying to find for several months, coming up with previously unimagined ways of saving money or implementing technology.  When challenged, I will give you my best.  When not challenged, you will know I’m bored.  I will probably send up 20 tweets a day and browse Craigslist for things I will never buy.

On a final note — you probably have a personality type too.  If you tell me what it is, I will feel challenged and research it.  I will also (for the sake of efficiency and correctness) learn your strengths and weaknesses and learn to apply myself toward you in a way that takes advantage of both.  This would be a good thing.

Mar 5 2009

Contracts, CYA

Pavel Lutskovsky

It’s another Thursday. I’m neck deep in development and a a small job comes my way.  It’s so small that I can do it in 4 hours.  A carpenter’s equivalent of building a bookshelf.  Should I bother with a contract? What if it gets bigger? What if there’s scope creep? What if I don’t get paid?

The fun and exciting world of freelance became a lousy craphole where money talks and BS walks (especially when your clients lawyer up) and you get burned the first time.  Almost everyone gets burned. The smart ones only get burned once.  I’ve been burned. More than once.  Clients fail to pay and use your designs anyway, clients throw your work to someone else when they run out of money, clients try to change the scope of the project and don’t want to pay extra.  And I don’t blame them.  They’re out to make a buck any way they know how — just like me.  They don’t want to pay any more than they have to and if I’m dumb enough to work without a contract, I guess it’s on me.  Here, an ounce of prevention is worth a pound of cure.

So, rather than whine and complain, I started using a simple but effective contracts to make sure I’m protected, the client’s protected and no one feels like they’re stepping into an episode of Law and Order in the process.  Namely, I’m after defining the scope of the work, defining who own things when I’m done, how I am to be paid and how much.  There are a lot of other pieces that I could include, but they would not be in line with keeping things simple.

To further keep it simpler, I don’t charge the client for drawing up the contract (though some do and there are arguments for why they should). Granted, I’m not a lawyer (nor do I ever want to be one) and can’t say that these steps will prevent things from getting tense or prevent the client and I from disagreeing.  Rather, these steps give us some pieces to agree on so any disagreements are generally minor.

  1. Purpose.  A basic statement of the fact that someone is hiring you to do something specific (in my case develop a web application or web site)  won’t hurt.
  2. Description of work. I use whatever the client gave me in my initial interviews but in my words.  Their signature denotes agreement with my analysis.  I intentionally don’t include any language about scope creep or how to handle change orders.  I prefer to  discuss that as it comes up.  This is a good place to describe how the finished product is to be delivered.
  3. Content ownership. There’s a lot of argument within the development community about site ownership and copyrights.  I prefer the KISS approach (Keep It Simple Stupid).  The client owns the content once I’m paid.  Yes, I use the “work for hire” method.  Yes, I could follow along with the copyright train and give the client the rights to the work if I wanted.  But then comes the inevitable explaining of what that means to them and how they should treat the work if they want changes made.  If I lock them in, they’ll grudgingly come back to me.  If I don’t, they’ll happily come back to me for future changes because they don’t feel like I tried to pull some legaleze on them.
  4. Payments. I’ve done time and materials, I’ve done project fee, I’ve done share of profits.  Whatever your choice is, document accordingly.  If you have an hourly rate, write it down. If you want a retainer, write it down. If you’re going to bill the client every two weeks, put it in the contract.  If you expect those invoices to be filled by 30 days, put that in the contract.  If you plan on charging a penalty for non-payment, put it in the contract.  It doesn’t have to be complicated, but it prevents an unpleasant surprise when the client calls wondering why they owe you so much and why they should pay before the site is done.
  5. Development schedule.  This one can get tricky because you may feel like you’re locking yourself in and not everything is in your control.  I avoid the “locked in” feeling by giving myself a margin of error – 20% is reasonable, I think.  If you’re not great at estimating — pad your time more; you’ll get better.  I further put the client at ease by giving myself a penalty for exceeding the deadline.

If you’d like a sample copy to use, let me know, I’ll email you a copy under GPL.

Feb 17 2009

toad for mysql

Pavel Lutskovsky

In my recent quest to migrate a shopping cart from osCommerce to ZenCart, I realized that I missed the SQL comparison tools I used in my Delphi programming days — namely redgate SQL Compare.  But like most that only freelance occasionally, I simply cannot justify spending several hundred dollars on a tool I’ll only use some of the time.  

I needed something cheap (free) to compare both the schema and the data and spit out a difference between tables on different databases.  Hand-comparing would be a waste of time for a low-paying project and I was fairly certain from a quick once-over that there would be few differences in structure since Zen Cart started as a branch of osCommerce. 

I’ve used MySQL GUI Tools issued by MySQL for the last few years on PC and Mac and found their performance to be generally good on PC and less than adequate on a Mac.  There was always phpMyAdmin — old, clunky, definitely a tool of the last resort when remote logins aren’t allowed.  Additionally, SQLyog’s free edition has been quite useful.  Sadly, none of them offered any sort of data/schema comparison tools.  

  • MySQL’s Migration Toolkit (part of MySQL GUI Tools) offered a very cool interface for moving one db to another.  I will likely have to review that separately for its ease of use, speed and flexibility in doing that one task. But there wasn’t a way to take one database’s objects and compare them to another database’s objects for the purposes of moving data.
  • SQLyog was another excellent GUI for DB work.  Free was a good price.  But still no comparison features.
  • phpMyAdmin is a tool of last resort for me.  It offers backup and restore but little else. I despise the GUI and the features are lacking quite a bit.

With my hopes down and settling in for a tedious hand-compare process I ran across Toad for MySQL which promised “utilities to compare, extract and search for objects.”

I’m impressed.  Within minutes, I had two schemas compared on the tables I needed and scripts generated to move data from one to the other.   The usability of this software was excellent and incredibly intuitive, without nags, useless prompts, unclear instructions, etc.  

Reasons why Toad is my new MySQL GUI: 

  1. Powerful schema and data comparison. Free.
  2. SQL debugging, query planning, query builder for when you’re lazy, auto-generation of statements.
  3. Decent, intuitive GUI.  Even the ability to use whatever style you’re used to, like SQL Query Analyzer or Management Studio.
  4. It didn’t attempt to take over the .sql file extension.  I can still use anything else I want.  It doesn’t pretend to run my life and I’m quite happy with that.
  5. Did I mention it’s free?

Feb 7 2009

Goodbye osCommerce, hello Zen Cart

Pavel Lutskovsky

After several months battling osCommerce for a client of mine, I’ve thrown up my hands and embraced ZenCart.  The only pain in the process is knowing that had I done this sooner, I could’ve finished this project last month.  To compare the two is to compare a paraplegic to Michael Phelps.

OK… Maybe that’s a gross exaggeration.  I’m sure there are plenty osCommerce users in the world for whom it works well.  The problem is it didn’t work for me without having to debug payment modules.  Out of the box, the latest version was clunky, required register_globals to be on (deal-breaker), used a non-W3C compliant layout, had zero skin previews on its site and refused to work with PayPal Advanced Web Payments. This makes it a poor solution for my client — small business, no merchant account with a large bank, limited budget, limited time.  Something had to be done and after going through seven circles of hell with osC,  on a whim I tried Zen Cart.  I was hooked.  Not only did it work out of the box, but there was actual documentation, W3C compliance, much more flexibility, AND it worked with PayPal immediately.

So, if you’re stuck with an e-commerce package that requires you have register_globals set to on, doesn’t quite work with paypal and isn’t W3C compliant out of the box, this is for you.

It’s time to lose osCommerce and use a more modern solution.  The process is quite simple because Zen Cart’s schema is very similar in all key places to the osCommerce schema.  This is because ZenCart was branched from osCommerce a while ago. While the PHP changed, the schema remained very close to the original. The upgrade is simply a matter of installing ZenCart where you need it, running some DB scripts, and moving a few image files.  I went from osC 2.2 to Zen Cart 1.3.8.  I’m not sure if the below instructions will work for other versions, so you should check the schema before proceeding.

First, install ZenCart.  I put mine at /[site directory]/zen.  Create a DB for it and then just follow the instructions.  If you’re on DreamHost, there’s a one-click installer available.

Next, you’ll need to run some db scripts to move your data over.  If you don’t want to mess around with manually reviewing each table, a data compare tool is imperative.  If you have a Windows machine available, Toad for MySQL is a free tool which has a data compare function. There are alternatives that cost over $200.  You can also use phpMyAdmin to export the necessary data and import it into Zen Cart.  The bare minimum tables you’ll need are below.  When preparing this, note how many tables you selected. This will help debug the import if things go wrong.


You may have other content in tables like newsletters, specials, etc.  As long as you understand the general idea of comparing the tables before moving data, you can move those too.  In phpMyAdmin, select your osC database and click on the “Export” tab at the top.  Select the tables you want and use the following options:

Select SQL radio button under tables selection
un-check "Structure"
check "Data"
    x Complete inserts
    x Extended inserts
check "Save as file"

Next, just click “Go”. You can save or open the file.  You should have a SQL script containing all your really important product and customer data to move into your Zen Cart database.  So, select your Zen Cart database in phpMyAdmin and click on the Import tab. It’s time to move data.

Click “Browse” and select the file you just downloaded. Make sure the format of import file is set to SQL and click Go. You’ll get a status message telling you how many queries were successfully executed.  The number should be equal to the number of tables you selected.

Next, it’s time to move your product images.  The images directory in osC is /[installation dir]/images.  This is the same in Zen Cart.  You can use FTP, command line, a file manager, whatever you want to do this.  I just ran “cp -i * [zencart images dir]”. The “-i” flag will make sure you get prompted if there’s a conflict.

That’s it! You’re done.  Configure your store and start selling.