1

Here is my simple magento login form but I am unable to submit my form. What may be the possible reasons?

<form action="<?php echo $this->getPostActionUrl() ?>" method="post" id="login-form">
 Email:
 <input type="text" name="login[username]" value="<?php echo $this->htmlEscape($this->getUsername()) ?>"  title="<?php echo $this->__('Email Address') ?>" />
 Password:
 <input type="password" name="login[password]" id="pass" title="<?php echo $this->__('Password') ?>" />
 <button type="submit" class="button" title="<?php echo $this->__('Login') ?>" name="send" id="send2"><span><span><?php echo $this->__('Login') ?></span></span></button>

11
  • where r u using this lo-gin page?
    – Keyur Shah
    Sep 11, 2013 at 6:30
  • I need to create a new popup and in that i need to place this login form. Sep 11, 2013 at 6:31
  • is any js error occur?when submitting form?
    – Keyur Shah
    Sep 11, 2013 at 6:47
  • Still the problem exists. No there is no JS Error Sep 11, 2013 at 6:52
  • 1
    Is your form inside an other form?
    – Marius
    Sep 11, 2013 at 8:03

1 Answer 1

4

It looks like you're missing a </form> tag. Try this:

<?php $custmlogin= new Mage_Customer_Block_Form_Login();?>
<form action="<?php echo $custmlogin->getPostActionUrl() ?>" method="post" id="login-form">
 Email:
 <input type="text" name="login[username]" value="<?php echo $this->htmlEscape($this->getUsername()) ?>"  title="<?php echo $this->__('Email Address') ?>" />
 Password:
 <input type="password" name="login[password]" id="pass" title="<?php echo $this->__('Password') ?>" />
 <button type="submit" class="button" title="<?php echo $this->__('Login') ?>" name="send" id="send2"><span><span><?php echo $this->__('Login') ?></span></span></button>
</form>
0

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