znap Posted July 22, 2004 Posted July 22, 2004 Hi.. I have a problem, In infoboxes, (Categories and Whatsnew)I want to HIDE the text or more correct. EMPTY IT! so its all blank (White/Blank/Space) Understand? BUT, When the user LOGIN, the empty space in the infoboxes, will be revaled as a MENU (Like it is from the beginning) so only when you have enter your user name/password, and pressed login, the Menu/Text will be showed. and the menu should be fully functional. I think it would be an easy way to see the site, but not the menu becuase.. the user will pay for the login and password, of my product that is text based. and in the categories, i will have my secret text that only a logged in person can see and have acess to. Any1 now how to do? havent heard about this before, as I just figureed it out. Thanks / Andrew
Acheron Posted July 22, 2004 Posted July 22, 2004 mm, give this a shot for whats_new ... if (!tep_session_is_registered('customer_id')) { showthis; } else { show nothing; } Just my 2 cents, but wouldn't it look better to simply not show those boxes at all if a user isn't logged in? It's also easier that way. ;)
znap Posted July 22, 2004 Author Posted July 22, 2004 Ahceron.. If i want the Categories box, gone.. in the front page, then visible when user Log's in.. how do i do ?
Guest Posted July 22, 2004 Posted July 22, 2004 in catalog/includes/column_left.php (or column_right.php) Simply change your line ... for example, this one: if ((USE_CACHE == 'true') && empty($SID)) { echo tep_cache_categories_box(); } else { include(DIR_WS_BOXES . 'categories.php'); } would be changed to: if (((USE_CACHE == 'true') && empty($SID)) && (tep_session_is_registered('customer_id'))) { echo tep_cache_categories_box(); } elseif (tep_session_is_registered('customer_id')) { include(DIR_WS_BOXES . 'categories.php'); } else { } and for the whats_new box ... if (tep_session_is_registered('customer_id')) include(DIR_WS_BOXES . 'whats_new.php');
znap Posted July 22, 2004 Author Posted July 22, 2004 Hells River.. DA*N! Tottally correct.. it worked.. thanks alot!!!!! :D :D / Chris
Recommended Posts
Archived
This topic is now archived and is closed to further replies.