D
D
Dima4jin2014-11-13 08:59:01
Drupal
Dima4jin, 2014-11-13 08:59:01

How to hide standard registration pages in drupal 7?

Hey!
Implemented a page with a registration/authorization block on the site.
I want users to use only it to enter and could not accidentally, or specifically use the standard
site.ru/user/register
site.ru/user/site.ru/user/password
how
to hide / disable them?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
P
Pavel, 2014-11-13
@Dima4jin

<?php
function theme_preprocess_page(&$variables){
  if(arg(0) == 'user'){
    drupal_goto('Твой URL регистрации');
/** или 404
*   drupal_not_found();
*/  drupal_exit();
  }
}
?>

you will add the condition yourself, what you need

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question