I have a webshop were I have to hide away the login and create user form, because I only want customers with a specific link to be able to register. When they have registered they will be able to see a category that only they have a link for. What I want to do is create a static block that contains links to this category, customers dashboard etc. that only logged in users/or users in a specific customer can see. How can i achieve this?
are you want to show .... category after register?? which have static block??– Amit Bera ♦Aug 26, 2014 at 14:07
Mage::getSingleton('customer/session')->isLoggedIn() before your block as a conditional and you have scenario 1 fixed.
Also you can use
Mage::getSingleton('customer/session')->getCustomerGroupId() to get the Customer group Id as another conditional before echoing your block. See how to echo a block here.
<?php if (Mage::getSingleton('customer/session')->isLoggedIn() && Mage::getSingleton('customer/session')->getCustomerGroupId() == "something") :?> <?php echo $this->getChildHtml('sample_links') ?> <?php endif;?>
Remember to define your block in your XML file.