View Full Version : mini basket edit
I have the mini basket display module and am using the brief totals option. I was wondering how I can get it to say "You currently have 0 item(s) in your cart" instead of "You currently have (blank) item(s) in your cart". I don't know how to get it to have a 0 until items are added.
Here is the Code:
<mvt:if expr="l.settings:minibask:count GT 0">
<mvt:item name="fonts" param="body_font">
<br> &mvt:minibask:count;
</mvt:item>
</mvt:if>
The site is http://66.36.184.183/mm5/merchant.mvc?Screen=SFNT&Store_Code=M
Thank you
Dns pointer is moved...it is now:
http://maxwho.com/mm5/merchant.mvc?Screen=SFNT&Store_Code=M
Vic - WolfPaw Computers
08-05-06, 01:25 AM
Have you contacted the developer for support on his module?
Normally the brief entry is for a running total, but if you want it to have a different line, see the following.
<mvt:if expr="l.settings:minibask:count GT 0">
<mvt:item name="fonts" param="body_font">
You currently have 0 item(s) in your cart
</mvt:item>
<mvt:else>
<mvt:item name="fonts" param="body_font">
<br>Items in Basket: &mvt:minibask:count;
</mvt:item>
</mvt:if>
dreamingdigital
08-11-06, 11:46 PM
it's the same with the normal basket too. if you don't have any items and you output the number of items it's not "0" (zero) it's "" (as in nothing). This is different from OpenUI for Miva4 which gives you an actual "0" (zero). :confused:
Anywho, I've just used JavaScript to display the item count in the past. Assign the miva variable to a javascript variable and use javascript to document.write() a 0 if the variable ="" else write the real count. I'm sure you can use miva to do it as well.
I'm going to take a stab at doing it in Miva here. Please correct me so I learn as well.
<mvt:if expr="NOT ISNULL l.settings:minibask:count">
&mvt:minibask:count;
<mvt:else>
0
</mvt:if>
edit: looks like the real deal beat me to it.
vBulletin® v3.7.4, Copyright ©2000-2008, Jelsoft Enterprises Ltd.