--This module shows to create a Custom login form and assign it to the Drupal Block programmatically by following the Drupal 6 Standards. --A template file is created, that contains a login form with all the associated fields. --A custom block is created and can be placed anywhere in the website. --The hooks are used to alter the form, create a block.
Few easy steps.
- Know where custom modules go, not in /modules but in /sites/all/modules
- Create a folder there, e.g., customlogin.
- Open a text editor and create a file named customlogin.info
- In customlogin.info add the following lines:
name = Customlogin description = Custom Drupal Login Module. It creates a block for Drupal Login and can be positioned anywhere on the page. package = Custom core = 6.x
-
Create another file named customlogin.module
-
In customlogin.module, we have used the function hook_menu(), hook_theme(), hook_form_alter() to implement.
Also, functions as callback are created to display the output.