i have this:
<?php
if ( ($cart->count_product) > 0) {
print $cart->count_product;
} else {
print '';
}
?>
我需要将print $cart->count_product
放在<div class="my_class"></div>
中。
我尝试了不同的方法,但是语法上缺少了一些东西。如果有人能帮忙,我会很高兴。
else
语句没有作用。 - BenM