Only Guests

There re some contents that i want only guests to see.



for the ones that login as member i found the code below



{if $auth.user_id}

Check If User Logged In - Hints & Modifications - CS-Cart Forums



but i couldn’t find a code for guests only.





however i can do like this


test


{if $auth.user_id} .guest {display:none;}

but a code like this would take less place {if $auth.guest}

Can't you just use the Availability options at the bottom of the Website > Content > Edit page?

Put a check mark in front of “Guest” and uncheck “All”.

[quote name='Magpie Don' timestamp='1422207266' post='203388']

Can't you just use the Availability options at the bottom of the Website > Content > Edit page?

Put a check mark in front of “Guest” and uncheck “All”.

[/quote]



thank you for answer. but code required for tpl file. this isn't a block or page problem.

[quote name='webus' timestamp='1422189592' post='203375']

There re some contents that i want only guests to see.

[/quote]

Sorry, when you said “contents” I thought you were referring to the actual Website > Contents (where you create Pages & Forms) that is included with CS-Cart.

{if empty($auth.user_id)}

[quote name='tbirnseth' timestamp='1422249589' post='203396']

{if empty($auth.user_id)}

[/quote]



[color=#282828][font=arial, verdana, tahoma, sans-serif]thank you for answer.[/font][/color]

Hello,



The full and more correct line will be





Sincerely yours,

CS-Market.

Thanks for your reply it worked with a bit different way