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

#   No Stock notice breaking layout

##

- **[recedo](/forum/user/773-recedo "View recedo's Profile")**
- [![recedo's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar773.png)](/forum/user/773-recedo "View recedo's Profile") Topic Author
- [ Offline](/forum/user/773-recedo)

Less More

- Posts: 37
- Thank you received: 0
-
-

15 years 9 months ago -  15 years 9 months ago [\#5645](#5645) by [recedo](/forum/user/773-recedo "View recedo's Profile")  *[No Stock notice breaking layout](/forum/4-how-to/5645-no-stock-notice-breaking-layout#5645 "I have just tried a product with 0 stock to show the 'No Stock' message instead of an add to cart button.  The product showed correctly however it has broken my layout, with the sidebar now showing below the main content of the page (see screenshot - Login/Your Cart should be in right hand side bar).  I had a similar problem when I installed the JCE component and had the &quot;Force Container Element&quot; set to &quot;div&quot; so any content without a container was automatically given a div.  Just can't figure out what element is doing this - couldn't come across anyone with a similar problem in the forum.  Thanks Simon")* was created by *[recedo](/forum/user/773-recedo "View recedo's Profile")*

I have just tried a product with 0 stock to show the 'No Stock' message instead of an add to cart button.

The product showed correctly however it has broken my layout, with the sidebar now showing below the main content of the page (see screenshot - Login/Your Cart should be in right hand side bar).

I had a similar problem when I installed the JCE component and had the "Force Container Element" set to "div" so any content without a container was automatically given a div.

Just can't figure out what element is doing this - couldn't come across anyone with a similar problem in the forum.

Thanks
Simon

[ ![&#91;img](http://www.hikashop.com/media/kunena/attachments/legacy/images/screen-20110120.png) ](http://www.hikashop.com/media/kunena/attachments/legacy/images/screen-20110120.png "&#91;img")

- [ ![screen-20110120.png](/forum/attachment/356) ](/forum/attachment/356 "...n-20110120.png") [ ](/forum/attachment/356?download=1 "...n-20110120.png")

Last edit: 15 years 9 months ago by [recedo](/forum/user/773-recedo "View recedo's Profile").

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzU2NDUtbm8tc3RvY2stbm90aWNlLWJyZWFraW5nLWxheW91dD90bXBsPW1hcmtkb3du) 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?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86561
- Thank you received: 14307
-
-

15 years 9 months ago [\#5654](#5654) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Re: No Stock notice breaking layout](/forum/4-how-to/5645-no-stock-notice-breaking-layout#5654 "I have just tried a product with 0 stock to show the 'No Stock' message instead of an add to cart button.  The product showed correctly however it has broken my layout, with the sidebar now showing below the main content of the page (see screenshot - Login/Your Cart should be in right hand side bar).  I had a similar problem when I installed the JCE component and had the &quot;Force Container Element&quot; set to &quot;div&quot; so any content without a container was automatically given a div.  Just can't figure out what element is doing this - couldn't come across anyone with a similar problem in the forum.  Thanks Simon")*

Hi,

We just checked on our end and the HTML code when there is no stock is ok for us.

Could you provide a link to that page ?

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

- **[recedo](/forum/user/773-recedo "View recedo's Profile")**
- [![recedo's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar773.png)](/forum/user/773-recedo "View recedo's Profile") Topic Author
- [ Offline](/forum/user/773-recedo)

Less More

- Posts: 37
- Thank you received: 0
-
-

15 years 9 months ago [\#5659](#5659) by [recedo](/forum/user/773-recedo "View recedo's Profile")  Replied by *[recedo](/forum/user/773-recedo "View recedo's Profile")* on topic *[Re: No Stock notice breaking layout](/forum/4-how-to/5645-no-stock-notice-breaking-layout#5659 "I have just tried a product with 0 stock to show the 'No Stock' message instead of an add to cart button.  The product showed correctly however it has broken my layout, with the sidebar now showing below the main content of the page (see screenshot - Login/Your Cart should be in right hand side bar).  I had a similar problem when I installed the JCE component and had the &quot;Force Container Element&quot; set to &quot;div&quot; so any content without a container was automatically given a div.  Just can't figure out what element is doing this - couldn't come across anyone with a similar problem in the forum.  Thanks Simon")*

Hey - sorry running on my localhost so can't give a link.

Have provided the html for the page as an attachment to this post if thats any good - otherwise I'll keep digging and playing!

Simon

####  *This attachment is hidden for guests.
Please log in or register to see it.*

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzU2NDUtbm8tc3RvY2stbm90aWNlLWJyZWFraW5nLWxheW91dD90bXBsPW1hcmtkb3du) 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?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86561
- Thank you received: 14307
-
-

15 years 9 months ago [\#5665](#5665) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Re: No Stock notice breaking layout](/forum/4-how-to/5645-no-stock-notice-breaking-layout#5665 "I have just tried a product with 0 stock to show the 'No Stock' message instead of an add to cart button.  The product showed correctly however it has broken my layout, with the sidebar now showing below the main content of the page (see screenshot - Login/Your Cart should be in right hand side bar).  I had a similar problem when I installed the JCE component and had the &quot;Force Container Element&quot; set to &quot;div&quot; so any content without a container was automatically given a div.  Just can't figure out what element is doing this - couldn't come across anyone with a similar problem in the forum.  Thanks Simon")*

The opening span is missing in your HTML.

Normally, in the file quantity of the view product (accessible via the menu Display-&gt;Views), you should have the span below defined just before the NO_STOCK string:
&lt;span class="hikashop_product_no_stock"&gt;

Did you change that view maybe ?

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

- **[recedo](/forum/user/773-recedo "View recedo's Profile")**
- [![recedo's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar773.png)](/forum/user/773-recedo "View recedo's Profile") Topic Author
- [ Offline](/forum/user/773-recedo)

Less More

- Posts: 37
- Thank you received: 0
-
-

15 years 9 months ago [\#5667](#5667) by [recedo](/forum/user/773-recedo "View recedo's Profile")  Replied by *[recedo](/forum/user/773-recedo "View recedo's Profile")* on topic *[Re: No Stock notice breaking layout](/forum/4-how-to/5645-no-stock-notice-breaking-layout#5667 "I have just tried a product with 0 stock to show the 'No Stock' message instead of an add to cart button.  The product showed correctly however it has broken my layout, with the sidebar now showing below the main content of the page (see screenshot - Login/Your Cart should be in right hand side bar).  I had a similar problem when I installed the JCE component and had the &quot;Force Container Element&quot; set to &quot;div&quot; so any content without a container was automatically given a div.  Just can't figure out what element is doing this - couldn't come across anyone with a similar problem in the forum.  Thanks Simon")*

As far as I can tell that span is still there;
Code:

&lt;div style="width: 49%;" class="hikashop_product"&gt; &lt;div class="hikashop_container"&gt; &lt;div class="hikashop_subcontainer"&gt; &lt;div class="hikashop_product_image" style="height: 128px; text-align: center; clear: both;"&gt; &lt;a href="/tmg2/index.php?option=com_hikashop&amp;amp;ctrl=product&amp;amp;task=show&amp;amp;cid=13&amp;amp;name=mine-t-shirt&amp;amp;Itemid=115&amp;amp;category_pathway=0"&gt; &lt;img height="128" width="121" alt="Mine T-Shirt" src="/tmg2/media/com_hikashop/upload/thumbnail/t-shirt_11240.png"&gt; &lt;/a&gt; &lt;/div&gt; &lt;span class="hikashop_product_price_full"&gt; &lt;span class="hikashop_product_price"&gt;£ 10.00&lt;/span&gt; per unit&lt;/span&gt;&lt;span class="hikashop_product_name"&gt; &lt;a href="/tmg2/index.php?option=com_hikashop&amp;amp;ctrl=product&amp;amp;task=show&amp;amp;cid=13&amp;amp;name=mine-t-shirt&amp;amp;Itemid=115&amp;amp;category_pathway=0"&gt; Mine T-Shirt &lt;/a&gt; &lt;/span&gt; &lt;form name="hikashop_product_form_13_hikashop_category_information_menu_115" method="post" action="/tmg2/index.php?option=com_hikashop&amp;amp;ctrl=product&amp;amp;task=updatecart&amp;amp;Itemid=115"&gt; &lt;span class="hikashop_product_no_stock"&gt; No stock&lt;/span&gt; &lt;/form&gt;&lt;/div&gt; &lt;br&gt; &lt;input type="hidden" value="13" name="product_id"&gt; &lt;input type="hidden" value="1" name="add"&gt; &lt;input type="hidden" value="product" name="ctrl"&gt; &lt;input type="hidden" value="updatecart" name="task"&gt; &lt;/div&gt; &lt;/div&gt;

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzU2NDUtbm8tc3RvY2stbm90aWNlLWJyZWFraW5nLWxheW91dD90bXBsPW1hcmtkb3du) 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?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86561
- Thank you received: 14307
-
-

15 years 9 months ago [\#5669](#5669) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Re: No Stock notice breaking layout](/forum/4-how-to/5645-no-stock-notice-breaking-layout#5669 "I have just tried a product with 0 stock to show the 'No Stock' message instead of an add to cart button.  The product showed correctly however it has broken my layout, with the sidebar now showing below the main content of the page (see screenshot - Login/Your Cart should be in right hand side bar).  I had a similar problem when I installed the JCE component and had the &quot;Force Container Element&quot; set to &quot;div&quot; so any content without a container was automatically given a div.  Just can't figure out what element is doing this - couldn't come across anyone with a similar problem in the forum.  Thanks Simon")*

Ah ok, you're right, the span is there, it's getting late!

However, I can see a closing div tag after the closing div in your attachment:
No stock&lt;/span&gt;&lt;/div&gt;&lt;br/&gt;

In our code, in that same file, I don't see it:
echo JText::_('NO_STOCK');
}?&gt;
&lt;/span&gt;
&lt;?php
}
}
?&gt;
&lt;br/&gt;

Could you check this one out ?

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

- **[recedo](/forum/user/773-recedo "View recedo's Profile")**
- [![recedo's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar773.png)](/forum/user/773-recedo "View recedo's Profile") Topic Author
- [ Offline](/forum/user/773-recedo)

Less More

- Posts: 37
- Thank you received: 0
-
-

15 years 9 months ago [\#5671](#5671) by [recedo](/forum/user/773-recedo "View recedo's Profile")  Replied by *[recedo](/forum/user/773-recedo "View recedo's Profile")* on topic *[Re: No Stock notice breaking layout](/forum/4-how-to/5645-no-stock-notice-breaking-layout#5671 "I have just tried a product with 0 stock to show the 'No Stock' message instead of an add to cart button.  The product showed correctly however it has broken my layout, with the sidebar now showing below the main content of the page (see screenshot - Login/Your Cart should be in right hand side bar).  I had a similar problem when I installed the JCE component and had the &quot;Force Container Element&quot; set to &quot;div&quot; so any content without a container was automatically given a div.  Just can't figure out what element is doing this - couldn't come across anyone with a similar problem in the forum.  Thanks Simon")*

removing that div places the entire main content area into 1 column... I have made some modifications to wrap the buttons in both a div and a span to facilitate my styling.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzU2NDUtbm8tc3RvY2stbm90aWNlLWJyZWFraW5nLWxheW91dD90bXBsPW1hcmtkb3du) 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?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86561
- Thank you received: 14307
-
-

15 years 9 months ago [\#5672](#5672) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Re: No Stock notice breaking layout](/forum/4-how-to/5645-no-stock-notice-breaking-layout#5672 "I have just tried a product with 0 stock to show the 'No Stock' message instead of an add to cart button.  The product showed correctly however it has broken my layout, with the sidebar now showing below the main content of the page (see screenshot - Login/Your Cart should be in right hand side bar).  I had a similar problem when I installed the JCE component and had the &quot;Force Container Element&quot; set to &quot;div&quot; so any content without a container was automatically given a div.  Just can't figure out what element is doing this - couldn't come across anyone with a similar problem in the forum.  Thanks Simon")*

Are you sure that you properly added an opening div for it ? Could you attach the content of that view ?

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

- **[recedo](/forum/user/773-recedo "View recedo's Profile")**
- [![recedo's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar773.png)](/forum/user/773-recedo "View recedo's Profile") Topic Author
- [ Offline](/forum/user/773-recedo)

Less More

- Posts: 37
- Thank you received: 0
-
-

15 years 9 months ago [\#5674](#5674) by [recedo](/forum/user/773-recedo "View recedo's Profile")  Replied by *[recedo](/forum/user/773-recedo "View recedo's Profile")* on topic *[Re: No Stock notice breaking layout](/forum/4-how-to/5645-no-stock-notice-breaking-layout#5674 "I have just tried a product with 0 stock to show the 'No Stock' message instead of an add to cart button.  The product showed correctly however it has broken my layout, with the sidebar now showing below the main content of the page (see screenshot - Login/Your Cart should be in right hand side bar).  I had a similar problem when I installed the JCE component and had the &quot;Force Container Element&quot; set to &quot;div&quot; so any content without a container was automatically given a div.  Just can't figure out what element is doing this - couldn't come across anyone with a similar problem in the forum.  Thanks Simon")*

Managed to sort it - it was the div you mentioned. I had opened it correctly but closed the wrong side of an elseif statement and therefore it wasn't closing when the 'no stock' message was shown instead of a button - must have just stuck it down there at some point to try to make it all work together!

Thanks again for your fantastic support.

Regards
Simon

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzU2NDUtbm8tc3RvY2stbm90aWNlLWJyZWFraW5nLWxheW91dD90bXBsPW1hcmtkb3du) 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.058 seconds

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