[Skip to main content](#vessel-content)

#   Trouble with characteristics selection

##

- **[midgetwithamatch](/forum/user/15657-midgetwithamatch "View midgetwithamatch's Profile")**
- [![midgetwithamatch's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/15657-midgetwithamatch "View midgetwithamatch's Profile") Topic Author
- [ Offline](/forum/user/15657-midgetwithamatch)

Less More

- Posts: 9
- Thank you received: 0
-
-

13 years 3 months ago -  13 years 3 months ago [\#113874](#113874) by [midgetwithamatch](/forum/user/15657-midgetwithamatch "View midgetwithamatch's Profile")  *[Trouble with characteristics selection](/forum/4-how-to/85323-trouble-with-characteristics-selection#113874 "Hello there,  I'm currently working on a project for client. I am in need of some help as I can't figure out what is causing this behaviour.  Here a screenshot of how the product page looks when you initially load the page:  This is what happens when you select a characteristic from the dropdowns:  This is some information of how it is behaving in in chrome:  As you can see in the third picture it is changing the width of the hikashop&#95;product&#95;main&#95;image&#95;thumb div from 378px wide to 489px. There is a large margin added to the left side of the hikashop&#95;product&#95;main&#95;image&#95;subdiv div but I have the margin in the CSS set to  I have modified the show&#95;block&#95;image to wrap each thumbnail in a div with the class of thumbnail&#95;wrapper and to place a  after each thumbnail so that they sit one per line.  I'm assuming that the hikashopUpdateVariant javascript function might have something to do with this?  If anyone wants a login to the website so that they can test it and provide me with feedback just let me know!  Any help here is much appreciated. I can't figure out what exactly is causing the margin and the change in width in the main product image.  Thank you for any help")* was created by *[midgetwithamatch](/forum/user/15657-midgetwithamatch "View midgetwithamatch's Profile")*

Hello there,

I'm currently working on a project for client. I am in need of some help as I can't figure out what is causing this behaviour.

Here a screenshot of how the product page looks when you initially load the page:
[ ![screenshot&#95;1.jpg](/forum/attachment/11108) ](/forum/attachment/11108 "screenshot&#95;1.jpg")

This is what happens when you select a characteristic from the dropdowns:
[ ![screenshot&#95;2.jpg](/forum/attachment/11109) ](/forum/attachment/11109 "screenshot&#95;2.jpg")

This is some information of how it is behaving in in chrome:
[ ![screenshot&#95;3.jpg](/forum/attachment/11110) ](/forum/attachment/11110 "screenshot&#95;3.jpg")

As you can see in the third picture it is changing the width of the hikashop_product_main_image_thumb div from 378px wide to 489px. There is a large margin added to the left side of the hikashop_product_main_image_subdiv div but I have the margin in the CSS set to Code:

margin: 0px !important;

I have modified the show_block_image to wrap each thumbnail in a div with the class of thumbnail_wrapper and to place a &lt;br&gt; after each thumbnail so that they sit one per line. Code:

&lt;?php /** * @package HikaShop for Joomla! * @version 2.1.1 * @author hikashop.com * @copyright (C) 2010-2012 HIKARI SOFTWARE. All rights reserved. * @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html */ defined('_JEXEC') or die('Restricted access'); ?&gt;&lt;?php $variant_name = ''; $variant_main = '_main'; $display_mode = ''; if(!empty($this-&gt;variant_name)) { $variant_name = $this-&gt;variant_name; if(substr($variant_name, 0, 1) != '_') $variant_name = '_' . $variant_name; $variant_main = $variant_name; $display_mode = 'display:none;'; } ?&gt;&lt;div id="hikashop_product_image&lt;?php echo $variant_main;?&gt;" class="hikashop_global_image_div" style="&lt;?php echo $display_mode;?&gt;"&gt; &lt;div id="hikashop_main_image_div&lt;?php echo $variant_name;?&gt;" class="hikashop_main_image_div"&gt; &lt;?php if(!empty ($this-&gt;element-&gt;images)){ $image = reset($this-&gt;element-&gt;images); } $height = $this-&gt;config-&gt;get('product_image_y'); $width = $this-&gt;config-&gt;get('product_image_x'); if(empty($height)) $height=$this-&gt;config-&gt;get('thumbnail_y'); if(empty($width)) $width=$this-&gt;config-&gt;get('thumbnail_x'); $divWidth=$width; $divHeight=$height; $this-&gt;image-&gt;checkSize($divWidth,$divHeight,$image); if (!$this-&gt;config-&gt;get('thumbnail')) { if(!empty ($this-&gt;element-&gt;images)){ echo '&lt;img src="' . $this-&gt;image-&gt;uploadFolder_url . $image-&gt;file_path . '" alt="' . $image-&gt;file_name . '" id="hikashop_main_image" /&gt;'; } } else { $style = ''; if (!empty ($this-&gt;element-&gt;images) &amp;&amp; count($this-&gt;element-&gt;images) &gt; 1) { if (!empty($height)) { $style = ' style="height:' . ($height + 20) . 'px;"'; } } $variant_name=''; if(isset($this-&gt;variant_name)){ $variant_name=$this-&gt;variant_name; } ?&gt; &lt;div id="hikashop_small_image_div&lt;?php echo $variant_name;?&gt;" class="hikashop_small_image_div"&gt; &lt;?php if (!empty ($this-&gt;element-&gt;images) &amp;&amp; count($this-&gt;element-&gt;images) &gt; 1) { foreach ($this-&gt;element-&gt;images as $image) { echo '&lt;div class="thumbnail_wrapper"&gt;'; echo $this-&gt;image-&gt;display($image-&gt;file_path, 'hikashop_main_image'.$variant_name, $image-&gt;file_name, 'class="hikashop_child_image"','', $width, $height); echo "&lt;br&gt;"; echo "&lt;/div&gt;"; } } ?&gt; &lt;/div&gt; &lt;div class="hikashop_product_main_image_thumb" id="hikashop_image_main_thumb_div&lt;?php echo $variant_name;?&gt;" &lt;?php echo $style;?&gt; &gt; &lt;div style="&lt;?php if(!empty($divHeight)){ echo 'height:'.($divHeight+20).'px;'; } ?&gt;text-align:center;clear:both;" class="hikashop_product_main_image"&gt; &lt;div style="position:relative;text-align:center;clear:both;width:&lt;?php echo $divWidth;?&gt;px;margin: auto;" class="hikashop_product_main_image_subdiv"&gt; &lt;?php echo $this-&gt;image-&gt;display(@$image-&gt;file_path,true,@$image-&gt;file_name,'id="hikashop_main_image'.$variant_name.'" style="margin-top:10px;margin-bottom:10px;display:inline-block;vertical-align:middle"','id="hikashop_main_image_link"', $width, $height); if(!empty($this-&gt;element-&gt;badges)) $this-&gt;classbadge-&gt;placeBadges($this-&gt;image, $this-&gt;element-&gt;badges, '0', '0'); ?&gt; &lt;/div&gt; &lt;/div&gt; &lt;/div&gt; &lt;?php } ?&gt; &lt;/div&gt; &lt;/div&gt;

I'm assuming that the hikashopUpdateVariant javascript function might have something to do with this?

If anyone wants a login to the website so that they can test it and provide me with feedback just let me know!

Any help here is much appreciated. I can't figure out what exactly is causing the margin and the change in width in the main product image.

Thank you for any help

- [ ![screenshot&#95;1.jpg](/forum/attachment/11108) ](/forum/attachment/11108 "screenshot&#95;1.jpg") [ ](/forum/attachment/11108?download=1 "screenshot&#95;1.jpg")
- [ ![screenshot&#95;2.jpg](/forum/attachment/11109) ](/forum/attachment/11109 "screenshot&#95;2.jpg") [ ](/forum/attachment/11109?download=1 "screenshot&#95;2.jpg")
- [ ![screenshot&#95;3.jpg](/forum/attachment/11110) ](/forum/attachment/11110 "screenshot&#95;3.jpg") [ ](/forum/attachment/11110?download=1 "screenshot&#95;3.jpg")

Last edit: 13 years 3 months ago by [midgetwithamatch](/forum/user/15657-midgetwithamatch "View midgetwithamatch's Profile").

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzg1MzIzLXRyb3VibGUtd2l0aC1jaGFyYWN0ZXJpc3RpY3Mtc2VsZWN0aW9uP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86290
- Thank you received: 14268
-
-

13 years 3 months ago [\#114006](#114006) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Trouble with characteristics selection](/forum/4-how-to/85323-trouble-with-characteristics-selection#114006 "Hello there,  I'm currently working on a project for client. I am in need of some help as I can't figure out what is causing this behaviour.  Here a screenshot of how the product page looks when you initially load the page:  This is what happens when you select a characteristic from the dropdowns:  This is some information of how it is behaving in in chrome:  As you can see in the third picture it is changing the width of the hikashop&#95;product&#95;main&#95;image&#95;thumb div from 378px wide to 489px. There is a large margin added to the left side of the hikashop&#95;product&#95;main&#95;image&#95;subdiv div but I have the margin in the CSS set to  I have modified the show&#95;block&#95;image to wrap each thumbnail in a div with the class of thumbnail&#95;wrapper and to place a  after each thumbnail so that they sit one per line.  I'm assuming that the hikashopUpdateVariant javascript function might have something to do with this?  If anyone wants a login to the website so that they can test it and provide me with feedback just let me know!  Any help here is much appreciated. I can't figure out what exactly is causing the margin and the change in width in the main product image.  Thank you for any help")*

Hi,

Hard to say precisely what to do as the page is heavily customized (and the issue apparently comes from that customization since it works fine by default).
We would need to look directly at the CSS/HTML of the page to see what's going on, so yes, we'll need an access.

The following user(s) said Thank You: [midgetwithamatch](/forum/user/15657-midgetwithamatch "View midgetwithamatch's Profile")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzg1MzIzLXRyb3VibGUtd2l0aC1jaGFyYWN0ZXJpc3RpY3Mtc2VsZWN0aW9uP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[midgetwithamatch](/forum/user/15657-midgetwithamatch "View midgetwithamatch's Profile")**
- [![midgetwithamatch's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/15657-midgetwithamatch "View midgetwithamatch's Profile") Topic Author
- [ Offline](/forum/user/15657-midgetwithamatch)

Less More

- Posts: 9
- Thank you received: 0
-
-

13 years 3 months ago -  13 years 3 months ago [\#114021](#114021) by [midgetwithamatch](/forum/user/15657-midgetwithamatch "View midgetwithamatch's Profile")  Replied by *[midgetwithamatch](/forum/user/15657-midgetwithamatch "View midgetwithamatch's Profile")* on topic *[Trouble with characteristics selection](/forum/4-how-to/85323-trouble-with-characteristics-selection#114021 "Hello there,  I'm currently working on a project for client. I am in need of some help as I can't figure out what is causing this behaviour.  Here a screenshot of how the product page looks when you initially load the page:  This is what happens when you select a characteristic from the dropdowns:  This is some information of how it is behaving in in chrome:  As you can see in the third picture it is changing the width of the hikashop&#95;product&#95;main&#95;image&#95;thumb div from 378px wide to 489px. There is a large margin added to the left side of the hikashop&#95;product&#95;main&#95;image&#95;subdiv div but I have the margin in the CSS set to  I have modified the show&#95;block&#95;image to wrap each thumbnail in a div with the class of thumbnail&#95;wrapper and to place a  after each thumbnail so that they sit one per line.  I'm assuming that the hikashopUpdateVariant javascript function might have something to do with this?  If anyone wants a login to the website so that they can test it and provide me with feedback just let me know!  Any help here is much appreciated. I can't figure out what exactly is causing the margin and the change in width in the main product image.  Thank you for any help")*

Thank you nicolas for the help!

This is the login info for anyone wanting to help:
URL: [ www.olmecapparel.com](http://www.olmecapparel.com)
User: hika_test
Password: thankyouforhelping

If you need me to post any modified views just let me know.

Last edit: 13 years 3 months ago by [midgetwithamatch](/forum/user/15657-midgetwithamatch "View midgetwithamatch's Profile").

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzg1MzIzLXRyb3VibGUtd2l0aC1jaGFyYWN0ZXJpc3RpY3Mtc2VsZWN0aW9uP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86290
- Thank you received: 14268
-
-

13 years 3 months ago [\#114173](#114173) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Trouble with characteristics selection](/forum/4-how-to/85323-trouble-with-characteristics-selection#114173 "Hello there,  I'm currently working on a project for client. I am in need of some help as I can't figure out what is causing this behaviour.  Here a screenshot of how the product page looks when you initially load the page:  This is what happens when you select a characteristic from the dropdowns:  This is some information of how it is behaving in in chrome:  As you can see in the third picture it is changing the width of the hikashop&#95;product&#95;main&#95;image&#95;thumb div from 378px wide to 489px. There is a large margin added to the left side of the hikashop&#95;product&#95;main&#95;image&#95;subdiv div but I have the margin in the CSS set to  I have modified the show&#95;block&#95;image to wrap each thumbnail in a div with the class of thumbnail&#95;wrapper and to place a  after each thumbnail so that they sit one per line.  I'm assuming that the hikashopUpdateVariant javascript function might have something to do with this?  If anyone wants a login to the website so that they can test it and provide me with feedback just let me know!  Any help here is much appreciated. I can't figure out what exactly is causing the margin and the change in width in the main product image.  Thank you for any help")*

Mmm. I don't see why you didn't add a float:left; to the class hikashop_product_main_image_thumb
That should fix that problem as it should actually display wrongly all the time without it.

The following user(s) said Thank You: [midgetwithamatch](/forum/user/15657-midgetwithamatch "View midgetwithamatch's Profile")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzg1MzIzLXRyb3VibGUtd2l0aC1jaGFyYWN0ZXJpc3RpY3Mtc2VsZWN0aW9uP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[midgetwithamatch](/forum/user/15657-midgetwithamatch "View midgetwithamatch's Profile")**
- [![midgetwithamatch's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/15657-midgetwithamatch "View midgetwithamatch's Profile") Topic Author
- [ Offline](/forum/user/15657-midgetwithamatch)

Less More

- Posts: 9
- Thank you received: 0
-
-

13 years 3 months ago [\#114223](#114223) by [midgetwithamatch](/forum/user/15657-midgetwithamatch "View midgetwithamatch's Profile")  Replied by *[midgetwithamatch](/forum/user/15657-midgetwithamatch "View midgetwithamatch's Profile")* on topic *[Trouble with characteristics selection](/forum/4-how-to/85323-trouble-with-characteristics-selection#114223 "Hello there,  I'm currently working on a project for client. I am in need of some help as I can't figure out what is causing this behaviour.  Here a screenshot of how the product page looks when you initially load the page:  This is what happens when you select a characteristic from the dropdowns:  This is some information of how it is behaving in in chrome:  As you can see in the third picture it is changing the width of the hikashop&#95;product&#95;main&#95;image&#95;thumb div from 378px wide to 489px. There is a large margin added to the left side of the hikashop&#95;product&#95;main&#95;image&#95;subdiv div but I have the margin in the CSS set to  I have modified the show&#95;block&#95;image to wrap each thumbnail in a div with the class of thumbnail&#95;wrapper and to place a  after each thumbnail so that they sit one per line.  I'm assuming that the hikashopUpdateVariant javascript function might have something to do with this?  If anyone wants a login to the website so that they can test it and provide me with feedback just let me know!  Any help here is much appreciated. I can't figure out what exactly is causing the margin and the change in width in the main product image.  Thank you for any help")*

nicolas my friend you are the man. Something so simple!!!! Ugh been honestly reading through the javascript and the front end views line by line trying to figure out what could be causing that behaviour. I just went in and threw float:right to the .hikashop_product_main_image_thumb and immediately started behaving properly.

Thank you so much.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzg1MzIzLXRyb3VibGUtd2l0aC1jaGFyYWN0ZXJpc3RpY3Mtc2VsZWN0aW9uP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop- Install &amp; Update- Product &amp; Category Display- Content Creation- Sales and Orders- - Orders management- - Reports &amp; Statistics- Customers- Checkout- Payment Methods- Shipping Methods- Import &amp; Export (CSV, XLS…)- Specific Features- - Affilation- - Taxes- - Wishlist- - Vote- - Carousel &amp; Slider- - Mass Actions- - Filters &amp; Search- - Discount &amp; Coupon- - Feature Request- Integrations- Showcase- General Talk about HikaShop- Development- - HikaShop 3.0 Beta- Translation- Commercial Jobs HikaShop Components- HikaMarket- - Market: Feature requests- - Market: How to?- - Market: Bug Report- HikaSerial- - General talk about HikaSerial- - Serial: Bug Report- - Serial: How to?- - Support en Français de HikaSerial (French Support)- - HikaSubscription- HikaAuction- - Auction: Feature requests- - Auction: How to?- - Auction: Bug report Hikashop around the world- Support en Français (French Support)- Russian- - FAQ. Курс выживания с Hikashop. Частые вопросы и о- - Расширения Hikashop- - Наши сайты на Hikashop- 日本語版サポート(Japanese Support)- Thai- German Archives- Bug Report- How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.224 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)

[](#top)
