Jump to content

[SOLVED] Validate Customer display text on AccountForm


Recommended Posts



I'm trying to make a module that requiers the user to be validated by an admin before he can log in.


Currently i want to add a msg in the account creation page. I found that you should use

 public function hookDisplayCustomerAccountForm() {
  global $smarty;




to add text to that forum. According to the documentation that code should add my text right above the register button. But instead it's added directly to the login / enter mail to reg address.

And it's displayed at the very top of the page. Not under the little boxes.


And when I click on Create your account button i also get

TECHNICAL ERROR: unable to load form.
Error thrown: [object Object]
Text status: parsererror



Using default theme and running

Edited by PhpMadman (see edit history)
Link to comment
Share on other sites

Managed to fix it myself, found another code example in the documents.

Changed both install function, file path and hook code.

needactivation.tpl should be in


install code

 public function install()
  return parent::install()
  && $this->registerHook('displayLeftColumn')
  && $this->registerHook('actionCustomerAccountAdd')
  && $this->registerHook('displayCustomerAccountForm') ;

the hook

 public function hookDisplayCustomerAccountForm($params) {
  return $this->display(__FILE__,'needactivation.tpl');

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...