OmniCart v3.00 - Level up your productivity

  • Home
  • Updates
  • OmniCart v3.00 - Level up your productivity
OmniCart v3.00 - Level up your productivity

OmniCart v3.00 - Level up your productivity

This has been so far the biggest change so far that has ever been introduced to OmniCart.

We introduced Latte as OmniCart's primary templating engine for:

  • improved security
  • better development experience
  • more flexibility
  • believe it or not, faster pageload

Let's go break down each of them.

Improved Security

"Latte" automatically escapes values, so you can ask anyone to redesign your website without having to worry about cross site scripting (XSS attacks).

Development Experience

This part contains a couple of things, but let's go through the main ones.

1. Before when you wanted to translate your theme into multiple languages, you specifically had to keep track of your translatable texts, and include them in your locales. Now Latte does that automatically for you. No need to keep track of them, since latte will automatically generate them for you during compilation.

2. It's much cleaner to look at, especially for a designer.

Let's take a look at the following examples:


 if ($items): ?>
	 $counter = 1 ?>
	 foreach ($items as $item): ?>
		<li id="item- echo $counter++ ?>">
		echo htmlSpecialChars(mb_convert_case($item, MB_CASE_TITLE)) ?>
	 endforeach ?>


<ul n:if="$items">
{foreach $items as $item}
	<li id="item-{$iterator->counter}">{$item|capitalize}</li>

3. Your css/js assets are automatically compressed/minified based on your development/production environment, no need to manually minify them, and keep switching between minified and unminified versions.


Now this is one of the main reasons for going into this direction. If we want to continue improving the overall user experience, we need to allow crucial things like dynamic email templates, dynamic copyright text, dynamic custom pages, and higher customizability of the theme pages. For all of these things, we need a clean and secure way to expose a template engine in the Admin Control Panel, which will serve as the fundation of the customizability of the platform.

With this, we already support dynamic year in the copyright text, and more to come in the upcoming updates.

Performance Improvement

I know what you're thinking. Isn't it minifying the assets, handling translation keys, and finally rendering the whole template and expensive process? Well, not really. Latte compiles your templates to PHP code, and when it's requested from the browser, it will be the PHP code running, and the template. See, before when we used a function to translate the text on the page everytime it was loaded, now they get translated on compilation, hence the mentioned performance improvement. Translations is just one of the many things, but the same thing happens to assets as well.


While the templating engine is huge, there's one more huge improvement in v3.0.

We introduced an email queue. Many of the email handling services have daily limits, which means that without an email queue, once you reach the limit, the rest of the emails would fail... Which is horrible. Imagine having 10000 subscribers, and can only send out a newsletter to 1000 of them. The 9000 would fail, so you'd have to manually resend it every day... Email queues come to your rescue. You can just send it out to the 10000 subscribers now, and the queue will automatically check your email sending quota, to only process as many as possible, the rest will be processed the next day until the quota is reached again, and so on.

Now that we got the elephants out of the way, let's mention a few smaller enhancements that are included in this update:

  • New stock availability product filter
  • Added clear all for product filters, when more than 1 filters are applied
  • Add support for custom image on navbar widget type
  • Store width and height of media images for more control over your themes
Accept Reject