Posted in September 2015

PHP Ecommerce in 2015

Something I realized recently is how old and cranky the PHP based eCommerce tools have become. Tools such as OpenCart, ZenCart, WooCommerce, and Magento have been around donkey’s years, they’ve been hacked, patched and modulized. If you want to increase SEO on any of those platforms chances are there’s a huge marketplace of paid-for-modules that’ll claim to enhance your conversion and SEO. Problem is when you start looking at these plugins they tend to focus on one thing like meta and title tags. Other SEO plugins might focus on analytic. So what eventually happens is you end up installing several plugins to cover one area of shop. This comes then with it’s own problems not least compatibility but also security.

While those platforms and their marketplaces have served the PHP world and their merchants well over the years we’re now in 2015 and those players haven’t really stepped up their game all that much.

OpenCart

I’ve worked with OpenCart on and off since 2011 and it feels like it’s still in 2011. The code is lightweight, it has an MVC pattern behind it. But it’s very simple and feel old and dusty under the hood. But it’s a good solution for merchants who might be selling t-shirts or mugs and doing low-volume sales. But if you’re looking at low-volume sales why wouldn’t you consider using a hosted platform like Shopify? One thing merchants increasingly demand is a mobile presence, while the default theme for OpenCart is responsive there isn’t any APIs or anything else a mobile app can integrate with and building any kind of integration with the shop is going to be tough without changing the core unless you talk directly to the database (but that’s cheating!)

WooCommerce

A popular choice. WooCommerce provides a toolkit for selling things in your WordPress environment. I’ll admit I haven’t used WooCommerce but anything that plugins into something else to achieve it’s goal, such as WordPress in my book isn’t really a good solution. Sure there’s some good use-cases for bolting a shop onto a CMS or a blog, it might be convenient and it’ll get your foot in the door to selling stuff but if you’re a serious merchant I suspect it just won’t cut it.

Magento

Ohh Magento. I’ve worked on this beast now for the past year. It’s fantastic from a merchant point of view, but dreadfully slow to work on from a developer point of view. The code base although MVC and well documented is huge and very complicated. I often find working with Magento is quite difficult because it’s structure is quite ridged it has some flexibility out of the box with attributes but wanting to do anything different from what has been provided is quite tricky. Also don’t get me started on the EAV database design. In terms of scalability it’s quite tricky, it’s based on some of the Zend Framework (1) components so has several caching backends available, including Redis and Memcache. But developing with those turned off is painful and you need them turned off in development!

So the future… Magento 2 is around the corner and arrives end of this year, 2015. It’s promised to have a test framework with good coverage, and it’s meant to be based more on the Symfony components. It all sounds good but who knows if the community will adopt it? More importantly there is no upgrade path, so all the modules you have won’t work, and you’ll have to migrate all the data across too. It’s quite risky if you’ve spent along time building a stable system with finely tuned SEO and conversion. With that in mind it could be a good opportunity to migrate to another system anyway.

With the historic players in mind what else is available in 2015? In this day and age PHP developers tend to gravitate towards frameworks rather than fully built pieces of software. Probably because they offer the most flexibility long-term as well as more options for reusable components.

Sylius – http://sylius.org/

This is the most promising choice in 2015, an eCommerce framework built in Symfony 2 with good test coverage at unit, functional and behavioral testing levels. The test suite uses PHPSpec and Behat which is a tell-tale these guys aren’t messing around they’re taking testing seriously. Having looked into Sylius a couple times before it’s a little frustrating to see there’s a lot left on their roadmap before there’s a viable solution for a lot of people. It’s worth keeping an eye on their status on their roadmap page. For now don’t expect a feature full admin panel, or reviews and ratings.

One thing that is very encouraging is a recent tweet by Sylius – https://twitter.com/petewardreiss/status/614336914896912385 which shows a big UK Fashion Retailer hiring Sylius developers. It’s a good sign that the commercial world are keen to adopt Sylius early. You just have to google “Sylius” to find plenty of articles hyping it up.

Jiro – http://jiro.andrewmclagan.com/

Jiro is a Laravel based eCommerce framework. On the face of it it looks like it’s trying to achieve what Sylius is doing but using Laravel under the hood. It’s probably too early to really talk about this project as there isn’t any documentation yet and if you check out their Github repository you’ll note it only started in July 2015 this year. However knowing how fast Laravel become popular it wouldn’t surprise me to see this project get off the ground soon.

Thelia – http://thelia.net/

Unlike the others suggested here Thelia is a full eCommerce shop rather than a framework. It’s build on the Symfony2 framework, and looks pretty feature full. Already on version 2.1 this shop is really worth a consideration if you need something featureful right now. Having glanced through their demo and their feature list I think Thelia will be a real contender when Magento2 is released as it seems to contain everything you’d need to run your shop and more. It’s very SEO capable with meta tags and 301 redirects and more. It also contains a full REST API along with other features you’d expect from Magento such as Coupons, Customer Groups, Abandoned Carts, Analytics and Reporting.

Sonata Project – https://sonata-project.org/bundles/ecommerce/develop/doc/index.html

If you’re a confident PHP programmer or experienced with Symfony as a framework one route you can go down is to use a pre-made bundle. It means you can get an eCommerce experience out of your Symfony app with little effort. Does mean you’ll have to bootstrap and pull together all the bundles it includes so although the features are there you’ll have to be quite involved. The Sonata project from what I gather has been around a while and provides various bundles for the Symfony framework and are quite well used, so this bundle is probably very well supported across the Symfony community. Seems like a safe option to me if you want to create your own shop in Symfony and get a head-start on building the shop’s backend.

Conclusion

For me right now, I’d jump on Sylius. It’s going to be tricky being an early adopter but it’ll be worth it and as a developer means you can contribute back quite quickly. Although at pre-alpha stage the test suite around it is very encouraging so although not officially released you’d expect the framework to be fairly stable. With retailers hiring for Sylius and some noise on Twitter and Google search results I suspect this is a real contender.