Q:

Setting up permissions for non-registered users

How do I set permissions for non-register users?
Step 1: I registered Drupal 7 in my system.
Step 2: I wrote a module for user_register().
Step 3: When I call the menu callback an access denied error  is shown.
How should i set permission to non-register users to register?

A:

In your menu item definitions, you can specify TRUE as the access callback to make the item always accessible.
<?php
  function mymodule_menu() {
    $items['abc/def'] = array(
      'page callback' => 'mymodule_abc_view',
      'access callback' => TRUE,
    );
    return $items;
  }

?>

See http://api.drupal.org/api/function/_menu_check_access/7
Hope this helps,
Mark

