JigoShop – Fixing those Variaton Slug’s in the selects

Posted on 06 October 2011

Jigoshop you are perfect and I do love you so! but when I came across an issue with the variation slugs appearing in the drop downs on the front end of the website I began to panic! Well my client began to panic so I looked for a quick fix and here is what I came up with (Its not the cleanest but it works until I find a better solution).

You will need to edit two core jigoshop files which can be located within the pugins/jigoshop directory.

jigoshop_template_functions.php (line 391)
Change:
<option><?php echo $option; ?></option>
To
<option value="<?php echo $option; ?>"><?php echo ucwords(str_replace("-", " ", $option)); ?> </option>

assets/js/script.js (line 195)
//current_attr_select.find('option:contains("'+attr_val+'")').removeAttr('disabled');
current_attr_select.find('option[value="'+attr_val+'"]').removeAttr('disabled');

That will about do it for now!

0 Responses

Have Your Say!

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>