sanl Posted June 20, 2014 Share Posted June 20, 2014 okey, where is my problem? My IF doesnt work. <span id="availability_label">{l s='Availability:'}</span> So here is the main part. If I have product which has arrival date , customer should see that date in availability_value. Now I can see available now , available later text and after this new ID with arrival date. {if !isset($product->available_date) } // If product has DATE when it comes SHOULD show date <span id="availability_value">{dateFormat date=$product->available_date full=false} </span> {else} // If dont have DATE should show as always default. <span id="availability_value"{if $product->quantity <= 0} class="warning_inline"{/if}>{if $product->quantity <= 0}{if $allow_oosp}{$product->available_later}{else}{l s='This product is no longer in stock'}{/if}{else}{$product->available_now}{/if}</span> {/if} Where is my problem? Link to comment Share on other sites More sharing options...
vekia Posted June 20, 2014 Share Posted June 20, 2014 !isset($product->available_date) it is negation of isset so it means: if isn't $product->available_date then do something Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now