Wordpress Archives - ACTIVO

Integrating Magento and WordPress: Why decoupling is so important

Posted by | Magento, Web Development | No Comments

This week I have been busy with a typical setup out there: integrated website that runs on both WordPress and Magento. Theoretically the best of both worlds: CMS and eCommerce/Shopping Cart. Yes, essentially you run your home page and any content pages off of WordPress and then all category pages and product pages will be powered by Magento. This is fairly easy to accomplish by installing one of the two under a specific folder usually, Magento goes under /shop/ or /store/. The only thing left is similar themes and ready to go, right?

Wordpress and Magento Integration but decoupled

Yes, but… What happens if you want to integrate the menu between the systems. I have seen many variations on how to resolve this issue, some very creative like simply handling the entire menu manually in a file that is not part of any system and simply including the file in both themes. This is great as long as you want to manually manage your file. What if you want something more dynamic? anyway, you get the point. It can easily get challenging.

One thing to avoid is coupling. So, what you really want is to integrate two systems but keep them decoupled. Let’s review for a second what decoupled means in the Software Development world (skip the next paragraph if you know it):

This is streight from Wikipedia. Decoupling:

In software development, the term “decoupling” is used to identify the separation of software blocks that shouldn’t depend on each other. Some building blocks are generic and shouldn’t know details of others. Special design techniques allow software designers to have as little dependencies as possible. This typically reduces the risk of malfunction in one part of a system when the other part changed. It also forces the developer to focus on one thing at a time.

Notice that I highlighted the important part: if you apply decoupling practices when integrating between systems you reduce the risk of malfunctioning in one part when the other one changes. I know when a developer is deep in the trenches it is hard to believe that something may break, but this is just the nature of software development. In fact, it is more likely that it will break then not.

Anyway, the specific system that I have been working on had been using the menu system from WordPress ver 3.0.1 (which by the way, they have done a great job redoing the menu admin interface, kudos WP people!). The menu is then including some files from Magento which then added a few subitems into the menu depending on categories and products that exist in the Magento DB. This is great and should work fine, but the issue is when something goes wrong, like for example the wordpress was including cached versions of some files which may or may not be in use – and depending on what you are hitting first (Magento or WordPress) if there is no cache, Magento gets an empty inclusion file and as you know, it outputs the usual Exception Report and crashes.

Here is where decoupling comes handy: instead we have selected one main system that will be our control for the menu, that would be WordPress. Then we have decided that we will feed a JSON service from Magento into the WordPress files. The JSON Web Service essentially replaces a hard inclusion which may break. Then we will add a small piece of logic to actually check what comes through the JSON web service from Magento and decide what to do with it. Hence, the system is now integrated, decoupled, and has a nice fail safe mechanism.

I hope this helps someone out there who is trying to build an integrated website with WordPress and Magento… if you need more details, hit me up with some questions.

The Easiest Way to Sell Digital Goods Online with a Small Budget (2/4)

Posted by | Web Development | No Comments

In my last post I discussed how to sell digital goods online with absolutely no budget. In this post, I will discuss ways to sell digital goods with a small budget. To be accurate, I define a small budget to be between $50 to $1000. Let’s start:

  1. Research Keywords for your target market. This can be easily done by a few google searches and several of free tools offered by Google, such as Google Trends, Google Keyword Tool (External), and Google Insights for Search. All three are great in understanding what people are looking for in your target market. Your goal is simply to nail down 5-10 key phrases (yes, phrases not only key words) that you will use in the next steps.
  2. Buy a domain name to match your keywords. There are many ways to combine a few keywords together, so if your key phrase is taken, try to find an available domain with a spin on it, or add a prefix/suffix to distinguish it. i recommend the .com domain extension but you can always venture out as well. The key point is to have the keywords in the domain name.
  3. Get a simple hosting environment that supports wordpress. Today hosting is relatively inexpensive, you should be spending anywhere from $3-$10 monthly for a new wordpress site.
  4. Buy a wordpress theme from themeforest.net. Anything works, just make sure that your theme suits your needs and is something that you are comfortable with for a while. This should cost no more than $50 (one time charge).
  5. Purchase and install aMember Pro – membership software. With this software you essentially make certain folders on your site to be accessible by members who pay membership.
  6. Set it all up: Point the domain to the website and install wordpress or call your host and have them set it up for you. Most hosting environments have clear and easy instructions or may have a one click button installations. Install the new theme. Start customizing the store to your liking: add content, add contact us info, add pages, menus, posts, etc. Install and configure the aMember Pro software, make sure you can successfully accept payments and allow downloads.
  7. All you need to do now is add your digital goods in the secure folders and link to them from your posts and pages.

There is quite a bit to do, but when it comes down to it, these steps are relatively easy to perform, especially these days with one click wordpress installers and hosting environments that can be ordered with wordpress pre-installed. Unless you already have chosen vendors, for simplicity sake I recommend purchasing the domain and hosting with the same company. Let’s add the total so far:

  1. Keyword research: Free
  2. Domain name: $10/year
  3. Hosted WordPress: $3/month
  4. WordPress Theme: $50
  5. aMember Pro Software: $179.95

Total cost to start: $242.95

There you have it, with this setup you will be competing with well known online brands and companies that are doing this for a while now. All these tools are there for you – you just need to go ahead and use them. In the next post I’ll discuss how to sell digital goods with a medium size budget (less than $5000).

To your online success!