Skip to content| Skip to navigation

Miva Merchant Quick Tip: What to Do When Your Payment Gateway Fails

July 3rd, 2009 by Tiny Queen

A fire at the Authorize.net data center has caused massive disruptions in payment processing for ecommerce sites across the country today. Fortunately for Miva Merchant store owners, having your gateway go down doesn’t have to mean that you stop taking orders. By switching your payment method to Credit Card Payment with Simple Validation, you can keep your store humming along until your gateway service is restored.

Set up Simple Validation and Disable the Non-Functioning Gateway

  1. The first thing you need to do is to log in to your admin, and from the menu options at left, select Payment Settings. Check the box beside Credit Card Payment with Simple Validation and click Update.
  2. A new tab will appear, which will allow you to configure your credit card settings. By default, this module accepts American Express, Discover, Mastercard and Visa. If you don’t accept one or more of those cards, simply check the box beside it, and click Update. This will remove it from your settings.
    cc-options
  3. Next, you need to disable the crippled payment gateway so it won’t show up in your payment dropdown. You can’t simply unassign it, because it will likely have existing orders associated with it. Instead, click the plus sign to expand Global Settings, and click the link for Modules. In the search box, enter the name of your gateway, and click Go.
    disable-mod
  4. Find the gateway in the search results, and click the Edit button. Uncheck the box beside Active, and click Update.

Set Up Encryption

When you’re using simple validation, it’s very important to be certain that you have set up Order Encryption so that your data is securely stored.

  1. In the admin, click Order Processing. Click Store Encryption. Click Add Encryption Key.
  2. Choose an Encryption Prompt that will help you remember the key if you should forget it, and enter it in the Encryption Prompt input.
  3. Type your Encryption Pass Phrase, and then verify it. Choose a strong pass phrase. It should be at least 6-8 characters long, include both upper and lower case letters as well as numbers and punctuation marks.
  4. Write down your pass phrase in a secure location where you won’t lose it. If you forget your pass phrase, you will not be able to decrypt your orders and will be unable to process them.

Once you have your new payment method set up, test your store by completing test orders using each of the available methods.

Blog i360 – A Developer’s Review

July 1st, 2009 by Tiny Queen

I recently had the opportunity to work with a client to revamp an existing site and design she was unhappy with. My client had heard good things about Blog i360, and had her heart set on using it to build her new site. I hadn’t heard of Blog i360, so I did some looking around to see what I could learn.

For those of you who aren’t familiar with Blog i360, it’s a hosted platform based on WordPress that’s geared toward industries that commonly use squeeze pages and the like for marketing purposes.

I was disappointed to see that most of the results that came up for my search terms were affiliate sites that were understandably enthusiastic about the platform (you’re sort of expected to say, ‘Rah Rah’ when you’re selling stuff, after all). I did come across one blog post from a fellow developer expressing some reservations about the platform, but it was an awfully lonely voice in a sea of rave reviews. So, for whatever it’s worth, now that I’ve had a chance to live the Blog i360 experience, I’d like to add my own lonely little voice to the mix.

I should start by saying that I was impressed with the efforts of the Blog i360 staff to deliver quality customer support. I opened several support tickets during the building of my client’s site. All of them were answered promptly, and although I didn’t always get the answers I wanted, the support staff could not be faulted in any way.

That said, if I had the choice myself to build a site using Blog i360 versus a regular WordPress installation, I’d choose good old WordPress every time. Here are some of my reasons.

Search Engine Optimization

I was amazed to discover that Blog i360 doesn’t have any sort of SEO plugin enabled. There are some great WP SEO plugins out there that make adding custom title and meta tags to your site a snap. But you won’t find any of them on the Blog i360 platform.

Further, the Blog i360 system appears to use a single template that is then skinned to achieve something like the layout you’re looking for. Because some skins need hooks for creating curved corners or other similar aesthetic effects, the number of nested divs is simply astronomical, making the page code-heavy and slow to load.

Customization

The proponents of Blog i360 are quick to point out how easy it is to customize, but for anyone familiar with a regular WordPress installation, trying to customize Blog i360 quickly becomes an exercise in frustration.

  1. Custom Themes If you have a custom design or want a fully custom theme for your site, your only option is to pay Blog i360 to develop it for you, or to settle for working with the existing skins to create something less than what you had in mind.
  2. Page vs. Post There is no separate template for pages versus posts, which means that you can’t customize your pages to remove things like date stamps, related posts, meta information and so forth.
  3. No ID-Based Classes In a regular WordPress template, template developers can add classes to the site templates that incorporate the page or post id, allowing the site owner to target specific pages or posts with particular stylings or features. Unfortunately, the main Blog i360 template lacks this core functionality.
  4. Poor Integration of Home Page While the Blog i360 platform does allow you to choose between a static page or a blog page for your home page, if you choose the static page option, you must use a template specially designated by them for the home page. This template allows you to incorporate your blog headers and footers, but does not allow you to incorporate the sidebar. Any sidebar content has to be manually updated after changes are made to any of the blog pages.
  5. I will point out that the Blog i360 system does provide hooks that allow you to add custom html in a number of places throughout the template. This is great for people who know and understand html, but is not exactly what I’d call “easy customization.”

No Development Platform

As a hosted system, Blog i360 requires you to point your domain name servers to their servers in order to take your site live. Unfortunately, there are no provisions for setting up a development environment if, as in my client’s case, you have an existing site that you don’t want to have publicly mucked up while you’re working on it. The system is not inexpensive, and it would seem reasonable for Blog i360 to provide a development environment, even just for 30 days, that could then be moved to the site owner’s domain when development was complete. Instead, they recommend that if you don’t want to disrupt your current site, you purchase another domain name for your Blog i360 site. Of course, they neglect to mention that by doing so, you are likely to suffer a complete loss of search engine positioning, and create brand and customer confusion.

No FTP Access

Although Blog i360 sites are provided with a control panel for setting up email, etc, all ftp functions have been disabled. This is promoted as being more secure (and it is) but it is extremely disabling for anyone who wants to truly create a custom site.

  1. No .htaccess This means that if you do use Blog i360 on an existing live domain, you have no recourse to .htaccess files for setting up redirects from old pages to new.
  2. No Contact Form Script Blog i360 does not have an integrated contact form plugin, and since you have no ftp access, you can’t implement any sort of custom solution either.
  3. No Custom Scripting That kinda says it all.
  4. No Custom Upgrades The Blog i360 system, at the time of this writing, is using WP version 2.5. The current version of WP is 2.8, and the upgrades contain some important bug fixes that a site owner should have the freedom to implement.

Plugins

Of course, no ftp access also means no ability to install custom WP plugins to achieve the functionality you’d like in your site. That would be fine if Blog i360 weren’t lacking in some core functionality such as search engine optimization and contact form plugins.

Summary

The bottom line is this. If you want to build a quality web site that you control and that’s easy to use with little to no technical knowledge, you’re better off finding a decent web host and putting up your own WordPress site. If you’re not comfortable doing your own customization, hire a competent developer to get you up and running. In the end, it will cost you less, you’ll be happier with the result, and you’ll have a better web site.

Miva Merchant Quick Tip: Matching Multiple Variables in a Conditional

May 27th, 2009 by Tiny Queen

This morning I was working on a small project to modify the layout of the attributes on a product page template, and it occurred to me that others might find this little trick about writing conditionals where you need to match a multitude of variables useful.

In this particular project, I needed conditionals for two purposes: one in one location of the template to check to see if the attribute template code was either the word “Length” or the word “Width” and the second in a separate location to check to see if the template code was either “LengthFraction” or “WidthFraction.”

Since I was trying to match the code against a list of variables, I could have written my conditional like so:

<mvt:if expr="l.settings:attribute:template_code IN 'LengthFraction, WidthFraction'">

Anyone else see a problem with this though? The above conditional, which checks to see if the content of the template code variable exists in either the words LengthFraction or WidthFraction will return true not only if the template code is actually LengthFraction or WidthFraction, but also if the template code is merely Length or Width.

So, we need to be a little more specific. Since I was only trying to match one of two different variables, I could have written my conditional like this instead:

<mvt:if expr="((l.settings:attribute:template_code EQ 'LengthFraction') OR (l.settings:attribute:template_code EQ 'WidthFraction'))">

That’s fine when you only have a couple of variables to test against, but if you have several codes you want to match up, there’s a much cleaner and easier way. By making use of Store Morph Technology’s (SMT) concatenating feature, you can use the IN expression to check against a list of several codes, without the risk of inexact matches.

Here’s the code:

<mvt:if expr="'|'$l.settings:attribute:template:code$'|' IN '|Length|Width|'">

And here’s how it works.

The very first element in the conditional is a string (enclosed by single quotes) consisting of a pipe character, aka | . Next to the string is a $ sign. In many scripting languages the $ sign is used to indicate a variable, but in SMT, the $ sign is a concatenator. That is, it takes whatever string or variable is in front of it, and joins it to whatever string or variable is after it.

The next element in our conditional is the SMT variable we are wanting to test, in this case, the attribute template code. It’s followed by another $ sign and another string consisting of a pipe character. The result is that the first part of our conditional expression consists of the template code surrounded by pipes: |Length| |LengthFraction| |Width| |WidthFraction| etc.

The second element in the conditional is a string, consisting of a list of the codes we want to match. The list begins and ends with a pipe character, and the codes in the list are also separated with pipe characters.

What this means is that if the conditional tries to match |Length| to |LengthFraction| it will now return false, since there isn’t an exact character to character match — although the |Length part of the first element is found in |LengthFraction| the pipe at the end of |Length| does not appear in that same position in |LengthFraction| and so the conditional will return false.

So there you have it. A complex conditional made short and sweet.

My "Can't Live Without 'Em" List of Web Design Tools

March 21st, 2009 by Tiny Queen


I know, I know, pretty much every web designer out there has published a list of helpful tools they just couldn’t live without. And there are some great lists out there — I can easily waste an entire day just browsing from list to list and looking at all the nifty applications that can help make a web designer’s job just that little bit easier.

But I have a few handy little apps of my own that I’d like to add to the lists out there…because after all, you just can’t have too much of a good thing. Some are free, some are not, some are probably found on every other designer’s list, but all of them are well worth checking out.

HTML and CSS Tools

TopStyle – I own several html editors, and I admit I use them all for certain things, but my html/css/php editor of choice is this compact, easy to configure application. It has some terrific tools that make troubleshooting coding errors a snap (the tag matching feature is a must-have) and even has handy helpers for choosing color palettes, cleaning up your css, and overall site management. And best of all, with its intuitive menus and great built-in help files, you can set it up and learn to use its features in no time.

Firebug – This Firefox add-on is a must-have for troubleshooting layout issues, tweaking designs, and getting things downright pixel-perfect. One of my favorite ways to use it (aside from troubleshooting) is for trying out different design versions without having to create multiple mockups of a page. You can swap out colors, images, borders, change placement of elements, etc with just a few clicks, and see the results instantly on the screen.

Image Editing and Color Tools

Irfanview – Handy little photo editor that allows you to quickly resize, crop and do basic touchups on your photos.

Pixie – I’ve tried several color selection tools, but this tiny application is a fave. Need to match the colors in a logo to the colors in a site? Just launch this little helper, mouse over the color area on the screen, and you’re done. Simple and brilliant. I often use Pixie in combination with this Color Palette Creator to get a range of shades of a given color for use on a site.

Fireshot – This is another add-on for Firefox. With Fireshot, you can create quick screenshots of your browser window, or the entire web page. Add notes, text, drawings, shapes, crop, edit and save, email or simply copy the result to your clipboard. Great for quick tutorials on using a web application’s admin features, pointing out a section of the layout that needs tweaking, etc. And I have to admit…I’m a sucker for the camera shutter sound effect.

File Management Tools

Bulk Rename Utility – I recently worked on a project where an ecommerce site owner discovered he would have to rename in excess of 400 alternate product view images in order to get them to work with a custom script. He was not a happy camper until I shared this free utility with him. With just a few clicks, we were able to rename all of the photos in a matter of minutes. The flexibility of this utility is simply outstanding — with a little creative thought, it can handle pretty much any renaming needs you might have.

Dust Me Selectors – Over time, any large web site accumulates css styles that become obsolete, but are still cluttering up the stylesheet. Dust Me Selectors is a Firefox add-on that creates a list of selectors that aren’t being used. Great for cleaning up an overgrown site.

HTML Link Validator – We’ve all done it. You play with different versions of a page, and in the process wind up uploading index-test.html, index2.html, index-new.html to the server. Or, you’re updating a file, and want to preserve the original version as a rollback option if needed. So you end up with file.php, file.php.orig, file.php.bak, file.php.032009 and so on. Or, if you run an ecommerce site, you may have products that have been inactivated, but the images are still on your server. If you’re careful, you remember to clean up those files, but all too often, they get left behind on the server as orphans Over time, the number of orphans on even a well-maintained site can get overwhelming. This handy tool will browse your server and find those orphaned files so that you can delete them.

Miva Merchant: Customer Account Creation on INVC Page

February 26th, 2009 by Tiny Queen

Recently there’s been lots of buzz on the Miva Merchant User Support Forum about moving the account creation process to the end of the checkout. There are a number of good reasons for doing this. First, you eliminate one of the checkout screens, and streamline the checkout process. Second, and more importantly, you eliminate a decision from the checkout process.

There’s a great usability book out there by a fellow named Steve Krug, called “Don’t Make Me Think” That book title couldn’t be more apt for the checkout process in a shopping cart. When your shoppers commit enough to hit the checkout button, don’t present them with a new decision to have to make before they can get started.

As one person put it, your shoppers aren’t looking to develop a relationship with you. You have something they want, and they want to give you their money so you can send it to them. Since you want to get their money and send them things, it seems you have a common goal. So why not make it easier to achieve that goal? Get the sale, and then offer them the opportunity to create an account if they think they’d like to come back and shop again. But don’t clutter the checkout process with an unnecessary decision.

So, to the meat of the matter. How does one go about creating an account for a customer using the information available on the INVC page? Since they’ve already provided their shipping and billing information, there are only two additional bits you need from them: a user name, and a password. The rest you can feed to the form from what they’ve already told you.

In your INVC page template, decide where you want to present the account creation option, and add the following code. The hidden input for PrevPage isn’t required, but it gives you a global variable to test against if you want to customize the ACED page to display a “Thank you for creating your account” message instead of the account edit form.

You’ll have to do your own form styling, but this should give you the bare bones you need to get started.

<form method="post" action="&mvt:global:secure_sessionurl;">
<input type="hidden" name="Store_Code" value="&mvte:global:Store_Code;">
<input type="hidden" name="Action" value="ICST">
<input type="hidden" name="Screen" value="ACED">
<input type="hidden" name="PrevPage" value="INVC">
<label for="login">User Name</label>
<input type="text" id="login" name="Customer_Login" value="&mvte:global:Customer_Login;">
<label for="pass">Password</label>
<input type="password" id="pass" name="Customer_Password" size="25" value="&mvte:global:Customer_Password;">
<label for="verifypass">Confirm Password</label>
<input type="password" id="verifypass" name="Customer_VerifyPassword" size="25" value="&mvte:global:Customer_VerifyPassword;">
<input type="hidden" name="Customer_PasswordEmail" value="&mvte:order:bill_email;">
<input type="hidden" name="Customer_ShipFirstName" value="&mvte:order:ship_fname;">
<input type="hidden" name="Customer_ShipLastName" value="&mvte:order:ship_lname;">
<input type="hidden" name="Customer_ShipEmail" value="&mvte:order:ship_email;">
<input type="hidden" name="Customer_ShipPhone" value="&mvte:order:ship_phone;">
<input type="hidden" name="Customer_ShipFax" value="&mvte:order:ship_fax;">
<input type="hidden" name="Customer_ShipAddress" value="&mvte:order:bill_addr;">
<input type="hidden" name="Customer_ShipCompany" value="&mvte:order:ship_comp;">
<input type="hidden" name="Customer_ShipCity" value="&mvte:order:ship_city;">
<input type="hidden" name="Customer_ShipState" value="&mvte:order:ship_state;">
<input type="hidden" name="Customer_ShipZip" value="&mvte:order:ship_zip;">
<input type="hidden" name="Customer_ShipCountry" value="&mvte:order:ship_cntry;">
<input type="hidden" name="Customer_BillFirstName" value="&mvte:order:bill_fname;">
<input type="hidden" name="Customer_BillLastName" value="&mvte:order:bill_lname;">
<input type="hidden" name="Customer_BillEmail" value="&mvte:order:bill_email;">
<input type="hidden" name="Customer_BillPhone" value="&mvte:order:bill_phone;">
<input type="hidden" name="Customer_BillFax" value="&mvte:order:bill_fax;">
<input type="hidden" name="Customer_BillAddress" value="&mvte:order:bill_addr;">
<input type="hidden" name="Customer_BillCompany" value="&mvte:order:bill_comp;">
<input type="hidden" name="Customer_BillCity" value="&mvte:order:bill_city;">
<input type="hidden" name="Customer_BillState" value="&mvte:order:bill_state;">
<input type="hidden" name="Customer_BillZip" value="&mvte:order:bill_zip;">
<input type="hidden" name="Customer_BillCountry" value="&mvte:order:bill_cntry;">
<mvt:item name="buttons" param="Save" />
</form>

Sometimes it's ok to fudge it

November 23rd, 2008 by Tiny Queen

I stumbled across a laundry list of “Popular Web Design Links” over the weekend, and I’ve been having quite a spiffin’ time poking around other peoples’ blogs and forums, and reading posts and their related comments. I came across some interesting tidbits, had a few “aha” moments, and a little bit of just good old-fashioned validation of my own best practices when it comes to web design.

I have to admit, though, that I was a little bit put off by the number of posts I came across featuring people who are dead set on “doing it right.” Don’t get me wrong. I truly believe that coding to standards is always something to strive for, and I do try to stick to my principles as far as the whole “presentation” vs. “content” issue goes.

The fact is, though, that sometimes rules are meant to be bent. I admit it. I routinely set up styles called “left” and “right” and use them to float elements…you guessed it…to the left or to the right. Yes, I know that’s evil as far as the coding gods are concerned. But it’s also practical. When I’m typing my code, I can remember “left” and “right.” I don’t have to endlessly search for some sort of false semantic meaning for an image or a paragraph or even a table cell that I want to align to the right. I can just slap a label on the element and move on.

Yes, I know that someday that “right” might become “left.” I guess that’s a risk I’m willing to take. Sometimes it’s better to be simple and straightforward than to be…well…”right.”

Miva Merchant: A Store Morph Technology Mini-Primer

November 9th, 2008 by Tiny Queen

Store Morph Technology
When Miva Merchant released MM5, they revolutionized the way the software worked “out of the box” and opened a whole new world of customization to ecommerce store owners. Using Store Morph Technology (SMT), store owners could completely and…well, I was going to say easily customize their stores to suit their needs, but the truth is that at first glance, SMT isn’t in fact all that easy.

One of the common complaints from new developers of MM sites, is the lack of documentation about SMT and how it works. The new owners of Miva Merchant are working hard to remedy the documentation void, but in the meantime, here’s a mini primer on SMT and some examples of the things you can do with it.

You’ll see SMT in MM’s page templates in a variety of different forms.

Variables

There are two types of variables in SMT: local variables, specific to the page you’re on, and global variables, which are available sitewide. The best way to find out what variables are available on a given page is to download the free Store Helper Module from Latu.net.

Variables are displayed on MM pages in a variety of ways. Note that variables always begin with an ampersand (&) and end with a semicolon (;).

&mvt:product:code;
&mvte:product:code;
&mvta:product:code;

Variables that begin with &mvte are “entity encoded.” This means that any characters they contain will be displayed on the page in their exact form — they will not be interpreted by the browser.

Variables that begin with &mvta are “attribute encoded.” This means that any characters they contain will be converted to the correct format for use in a link.

Tags

SMT tags look similar to XHTML tags in that they are surrounded by < >, they include name / value pairs, with the values surrounded by double quotes, and all SMT tags must be closed, either by using a trailing slash, or with a separate closing tag.

Items

SMT tags may call in specific page items. These tags start with mvt:item, and use name=”xyz” to identify which page item is being called. They may also include parameters that more specifically identify the content to be called in. They are frequently self closing, but may have a separate closing tag depending on their form.

<mvt:item name="html_profile" />

<mvt:item name="fonts" param="body_font" />
Some content here
</mvt:item>

Loops and arrays

SMT tags may be used to loop through an array, and display specific data associated with that array. Common uses for these tags include such things as displaying the products in a category or search result, listing all of the products in the basket, or listing available shipping methods. All loops must be closed with a separate closing tag after you’ve worked with the content you’re pulling from the array.

<mvt:foreach iterator="product" array="products">
Some stuff about each of the items in this array
</mvt:foreach>

Conditionals

Finally, SMT tags may be used to create conditionals. This is far and away one of the most useful aspects of SMT, and is the building block of the store owner’s ability to customize his or her store (at least in my opinion!). Writing conditionals is probably worthy of a post all its own, but here are some basics.

All conditionals start with mvt:if and contain an expression to test for. A very basic conditional might look like this. This conditional checks to see if the product code is equal to the string 12345, and if it is, displays some text. Note that the string is enclosed in single quotes.

<mvt:if expr="l.settings:product:code EQ '12345'">
Display some text.
</mvt:if>

Conditionals can also be set up to do one thing if the condition is true, and another thing if it is false.

<mvt:if expr="l.settings:product:code EQ '12345'">
Display some text.
<mvt:else>
Display some other text.
</mvt:if>

Or even…

<mvt:if expr="l.settings:product:code EQ '12345'">
Display some text.
<mvt:elseif expr="l.settings:product:code EQ '45678'">
Display some other text.
<mvt:else>
Display yet some other text.
</mvt:if>

Expressions can be combined to create extremely specific situations to test against. For instance, if you want to display some text only if the product code is 12345 and the customer is logged in, you would write your conditional something like this:

<mvt:if expr="((l.settings:product:code EQ '12345') AND (g.Basket:Cust_id))">
Display some text
</mvt:if>

You can also easily test for a match in a single string or a series of strings, by using CIN or IN. CIN is case insensitive; IN is case sensitive. The strings to test against are enclosed in single quotes, and if there is more than one, they are separated by commas or some other delimiter such as a pipe. The conditional below will return true if the product code is 12345 or 45678 or 67890.

<mvt:if expr="l.settings:product:code IN '12345,45678,67890'">
Display some text.
</mvt:if>

Note that the conditional above will also return true if the product code is 1234567, 012345, or 98712356789. It checks merely to see if the content of the first variable is included in the second. If you need to look for an exact match, you would be better to use a conditional like the following.

<mvt:if expr="((l.settings:product:code EQ '12345') OR (l.settings:product:code EQ '45678') OR (l.settings:product:code EQ '67890'))">
Display some text.
</mvt:if>

Once you get the hang of them, you’ll wonder how you ever did without the power of conditionals to control your shopper’s experience on your site. Below are some of the most common conditional operators, along with what they do.

Operator Function
NOT Returns true if the condition does not match the variable
ISNULL Returns true if the variable is empty
AND Returns true if both conditions are true
OR Returns true if any of the conditions is true
EQ Returns true if the variable matches the string
NE Returns true if the variable does not match the string
GT Returns true if the variable is greater than the string
LT Returns true if the variable is less than the string
GE Returns true if the variable is greater than or equal to the string
LE Returns true if the variable is less than or equal to the string
IN Returns the first position of string_a in string_b. Case sensitive
CIN Returns the first position of string_a in string_b. Case insensitive

Comments

Finally, one of the most useful, and underused in my opinion, features of SMT is the comment feature. By carefully commenting your work, you make it so much easier on yourself or another developer when it comes time to try to make updates or changes to existing customizations. SMT comments take the following form. They are not parsed by the server, and won’t appear in your html source code.

<mvt:comment>
Here is an explanation of what this section of code is going to do.
</mvt:comment>

Miva Merchant Custom Product Field Conundrums

October 29th, 2008 by Tiny Queen

One of the handiest features of Miva Merchant 5+ is the inclusion of built in custom product fields. These fields can be used for an enormous variety of purposes, from adding product specific data (author, manufacturer, dimensions, materials, etc) to acting as a boolean-style test variable for setting up conditional displays of information.

Unfortunately, custom product fields are not quite as intuitive as they are handy. So here are some tips for working with them.

First, how to set them up?

  1. In the Miva Merchant admin, in the left hand menu, click Utilities (the word, not the plus sign). Check the box beside Custom Fields and click Update.
  2. You will now see some new tabs across the top of the configuration settings. Click Custom Product Fields.
  3. Click Add. Enter a Code (see Tips & Tricks below) and a Name and click Update.

Second, you have custom product fields, now what?

To add custom field data to your products, there are two methods you can use.

Method 1:

  1. In Quick Find, select Products. In the search box, type a search term for your product and click Go.
  2. In the row for your chosen product, click Edit.
  3. In the tabs above the input boxes, you’ll see Custom Fields. Click that tab, and you’ll see your new custom field displayed, with a text box beside it.
  4. Enter your text (see Tips & Tricks below) and click Update.

Method 2:

If you have a lot of products for which you need to add custom fields, the above method isn’t very practical. Instead, you may wish to use the built in import functionality. The easiest way to do this is to start by setting up a single product with some content for your custom fields.

  1. Start by following the steps above for a single product.
  2. Then, expand Utilities (this time click on the plus sign).
  3. Expand Export Data and click Export Products to Flat File.
  4. In the custom field sections, check the box(es) beside your new custom field(s).
  5. Select your other settings, and click Export.
  6. Your export file will be in your mivadata directory, typically above the root on your server. Contact your host if you are not certain how to locate this file.
  7. Import the file into Excel or another suitable program, and enter the data for your custom field(s).
  8. Save the file as tab delimited (this has its own issues, which I’ll address in another blog post) and import to Miva Merchant.

Third, you’ve got data…now how to get it to show up on the site?

So, you have your content saved in your new custom product fields, and now you’d like to display it somewhere on a product page. Here’s where the tricky part comes in.

Custom product fields are available by default on the PROD (Product), CTGY (Category), SRCH (Search) and PLST (Product List) pages. Other pages may require the Tool Kit from Emporium Plus to access custom fields.

In order to display a custom product field on your product page, you must enable it.

  1. To start, go to Pages> PROD and click Edit.
  2. Click the Tab for Product Display Layout.
  3. If you are in Advanced Mode, you will need to switch to Point and Click mode. Look for the link near the bottom of the screen.
  4. In Point and Click mode, you will see a section for Custom Fields, with your new custom field, and a checkbox to activate it.
  5. Check the box, and click Update.

Important: If you’ve made any modifications to your template, activating the custom fields will reset the template back to its original state.

  1. In order to both recall your changes and insert your new custom fields, you will need to switch to Advanced Mode by clicking the link at the bottom of the screen.
  2. From the version history, select your most recent version prior to this update, and click recall. Then click update.
  3. Now to insert your custom product field, you will need to paste the code below into your template where you would like it to appear. You may of course modify the code as needed to suit your purposes, and do be sure to replace YourCode with your actual custom field code.
<mvt:if expr="NOT ISNULL l.settings:product:customfield_values:customfields:YourCode">
&mvt:customfield_names:customfields:YourCode;:
<b>&mvt:product:customfield_values:customfields:YourCode;</b><br>
</mvt:if>

Finally, the Promised Tips and Tricks

There are some sneaky things about custom product fields that I’ve found out the hard way. If you’ve followed the steps above, and the custom fields still aren’t showing as intended, here are some things to check.

  1. Make sure the custom product field has data. Check that the product on the page you’re looking at actually has some content in its custom field.
  2. Make sure you enabled the custom field properly in the relevant template using the steps above (I know…but humor me and double check anyway).
  3. If you edited the page template to restore your customizations, make sure you correctly entered your custom field code in the store morph tokens.
  4. Check the length of the custom field code. It has been my experience (completely unverified and anecdotal though it may be) that custom field codes that are longer than 10 or so characters do not work as expected. The code seems to get truncated, which means that the store morph token doesn’t match it, and therefore it doesn’t display.
  5. Check for hyphens in your custom field code. Sometimes they work ok, but other times they create problems. If at all possible, keep your custom field codes short, and use alpha and numerical characters only.

One final word on custom fields. They have a character limit, set in the database, of 254 characters. If you’re using MySQL, you can edit the s01_CFM_ProdValues table and set the type for the Value field to tinytext or tinyblob depending on your needs. If you’re not experienced in working with MySQL, ask your host for help, or hire a professional to do this for you.

Taking Care of Business – Calendaring Important Web Events

October 13th, 2008 by Tiny Queen

On Friday, I got the sort of email every web developer dreads. The subject line…”BIG Problem”…said it all. The fact that I had spent that morning doing some updates on the site didn’t help my sinking feeling. My first thought, naturally, was that I had overlooked some major layout issue, and the site had gone haywire. In this case, though, it was something far more serious.

It turned out that the site’s security certificate had expired the day before. For this very busy ecommerce site, doing in excess of $1 million per year in online sales, an expired certificate, even for only a short period of time, meant significant revenue loss. I jumped in and tracked down the security certificate’s renewal information, helped the site owner generate and collect the information needed for the renewal process, and had the host set up a temporary shared certificate so that the site wouldn’t continue to lose sales while the security certificate company’s validation process was being completed.

Fortunately, we were able to minimize the damage that this administrative lapse might have caused, but it’s an important reminder to us all. Don’t rely on renewal emails for important details related to your website. You never know when they might go astray. Take the time to calendar your important web events:

  1. Domain registration renewal
  2. Security certificate expiration
  3. Web hosting contract renewal
  4. Software license renewals

This simple step can save you big headaches, and big bucks. Take control of your site. Take control of your business. You’ll be glad you did.

Nobody told me there was going to be math…

September 13th, 2008 by Tiny Queen

I’ve been working on a project for a new franchising opportunity. It’s a rather graphics-heavy design, and anyone who knows me will tell you how I feel about working with graphics — it usually involves more than one four-letter word.

In this particular instance, the site owner wanted a horizontal navigation system, with an extended tab on the currently active page. Easy enough to do, except that the navigation items were also divided by a small graphic image (in this case a paw print). In order for the drop-down tab not to bisect the paw prints, the tab needed to be wider than the menu item. To further complicate things, the site is built using the content management system Joomla!, which means that simply styling each page differently wasn’t an easy option. I’d have to come up with something that could be controlled by the Joomla! template.

I first tried styling the navigation bar with different background images assigned to the various elements. But I quickly ran into problems with the width of the list items. I just couldn’t add the dropdown tab without messing up the pawprints.

What to do?

This morning I finally had a brainwave. I decided to create six different background images, with the tab spanning the pawprints. So, I fired up my image editor and set about lining things up. Or at least trying to. Let’s see, the nav bar was 868 pixels wide, and there were 7 paw prints to add, evenly spaced out, and I needed to indent the paw prints on the ends a little, and take into account the width of the paw prints … oy! Out came the calculator, and several not so successful attempts…until I got the idea to add different colored bars above the image to represent each of the navigation items. Once I did that, it became much easier to see where my calculations were off, and in short order I had my six background images.

Navigation Bar

The next task was to code the Joomla! template to assign the appropriate background image to each page. I named my images navbg-1.jpg, navbg-2.jpg, etc, where the number represents the matching page id in Joomla!

In the Joomla! template, I started by adding the following code to the top of the page (above the DOCTYPE):

$page_itemid = JRequest::getVar(’Itemid’, ”);

Then the head tag section, I added a css styling as follows:

<?php if($page_itemid < '7') : ?>
<style type="text/css">
div.moduletable_menu {
  background:url(../images/navbg-<?php echo $page_itemid ?>.jpg) top left no-repeat
}
</style>
<?php endif; ?>

And the final result?
Navigation sample 1

Navigation sample 2

Navigation Sample 3

Navigation Sample 4

Navigation Sample 5
Navigation Sample 6

The only remaining detail was to add a css image preload to the bottom of the pages so that the background images would load quickly as the user navigates from page to page. I did this by creating a div at the bottom of the template that contains all of the navigation images, and setting its style to display:none.

It’s not a perfect solution, obviously, but it’s at least workable for now, and heaps better than the mess I had created before. If anyone has a better recommendation, I’d love to hear it.