Drupal Custom Comment Module I am trying to create my first module in drupal 6.
I just need to add some new fields to the already existing comment form(comment module).
Eg: City,Email and state fields.

I have created 2 files:
1. mmcomment.module
2. mmcomment.info 

Used a function hook_form_alter() like this:

 function mmcomment_form_alter(&amp;$form, $form_state, $form_id) { // form override
 if ($form_id == 'comment_form') {
    // unset the other field elements

    $form['subject'] = array(
      '#access' =&gt; FALSE
    );
    $form['comment_filter']['comment'] = array(
      '#access' =&gt; FALSE
    );
    // add field to all comments

    $form['Email'] = array(
      '#type' =&gt; 'textfield',
      '#title' =&gt; t('Email Address'),
      '#maxlength' =&gt; 255,
      '#size' =&gt; 30,
      '#required' =&gt; 1,
      '#weight' =&gt; 1,
      '#default_value' =&gt; $email
    );
     $form['displayName'] = array(
      '#type' =&gt; 'textfield',
      '#title' =&gt; t('Display Name'),
      '#maxlength' =&gt; 255,
      '#size' =&gt; 30,
      '#weight' =&gt; 2,
      '#default_value' =&gt; $displayName
    );

    $form['_author'] = array(
      '#access' =&gt; FALSE
    );
    $form['author'] = array(
      '#access' =&gt; FALSE
    );


I need to get the form values and insert into DB.
What Function can I use for the same.
I have tried:
hook_nodeapi(mmcomment_nodeapi).
But can't get the form values.
Any suggestions..
Thanks
In the $form structure you have to add/override the submit (and maybe the validate) handler.