1

I want to display login form in shopping cart page below checkout button in Magento.

There is any way to display the login form in that section, just like below image

enter image description here

2

You will need to set the child login block in your theme layout xml file. you can create local.xml file or you can add it in checkout.xml file. you can create new template file for your login form.

<reference name="checkout.cart">
   <block type="customer/form_login" name="custom_login_form" template="customer/form/customloginform.phtml" />
</reference>

You will need to get this block in your template file app/design/frontend/your_package/your_theme/template/checkout/cart.phtml at the end of the file or make sure your child block will not call inside the cart form.

<?php echo $this->getChildHtml('custom_login_form') ?>

Customize your new login template file as per your theme and requirement.

  • hi, this not working. Will you please suggest me where to get reference name. Because my site contains a extension for checkout. i want to replace popup form with static form. And the extension placed in base theme. – CodeBriefly Jul 21 '16 at 6:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.