Displaying an empty Mini Basket
Displaying an empty Mini Basket
We are changing up our layout and have the Mini Basket in the right sidebar, but when it is empty it does not display at all. It would be best to have the mini basket display, but simply show "Empty". Can anyone help with this?
Rick Morris
Brewhaus (America) Inc.
Hot Sauce Depot
Brewhaus (America) Inc.
Hot Sauce Depot
Re: Displaying an empty Mini Basket
You can do the following updates to make this happen:
Open Website/ConLib/MiniBasket.ascx.cs
Locate the following code inside BindBasket method
and replace with
This should work as expected now.
Open Website/ConLib/MiniBasket.ascx.cs
Locate the following code inside BindBasket method
Code: Select all
ShowBasket(true);
}
else
{
ShowBasket(false);
}
Code: Select all
ShowBasket(true);
BasketTable.Visible = true;
EmptyBasketPanel.Visible = false;
}
else
{
ShowBasket(true);
BasketTable.Visible = false;
EmptyBasketPanel.Visible = true;
}
Last edited by nadeem on Thu Dec 17, 2015 1:22 am, edited 3 times in total.
Re: Displaying an empty Mini Basket
This does get the mini basket to show up and display "Empty", however, it also displays the alternate control. Is there a way to display the mini basket and 'Empty' without the alternate control?
Rick Morris
Brewhaus (America) Inc.
Hot Sauce Depot
Brewhaus (America) Inc.
Hot Sauce Depot
Re: Displaying an empty Mini Basket
I have updated the above code. Please try this updated code.
Re: Displaying an empty Mini Basket
That resolved the issue of displaying the alternate control, but I found that both the revised code and new code have a different issue- the mini basket does not update until you refresh the page. Under the default code, when you add an item to the cart it immediately shows up in the mini basket. With the altered piece of code the mini basket does not update until you refresh the page.
Rick Morris
Brewhaus (America) Inc.
Hot Sauce Depot
Brewhaus (America) Inc.
Hot Sauce Depot
Re: Displaying an empty Mini Basket
Sorry.... I didn't test this, that's why it created trouble for you. Revert all the previous changes and use the new updated/tested code.
Re: Displaying an empty Mini Basket
That did the trick- thank you!
Rick Morris
Brewhaus (America) Inc.
Hot Sauce Depot
Brewhaus (America) Inc.
Hot Sauce Depot