? robotstxt.test
? robotstxt_test.info
? robotstxt_test.module
Index: robotstxt.admin.inc
===================================================================
RCS file: robotstxt.admin.inc
diff -N robotstxt.admin.inc
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ robotstxt.admin.inc	17 Feb 2009 07:26:11 -0000
@@ -0,0 +1,31 @@
+<?php
+// $Id$
+
+/**
+ * @file
+ * Administrative page callbacks for the robotstxt module.
+ */
+
+/**
+ * Administration settings form.
+ *
+ * @see system_settings_form()
+ */
+function robotstxt_admin_settings() {
+  $base = variable_get('robotstxt', FALSE);
+
+  if ($base === FALSE) {
+    $base = _robotstxt_get_file_contents();
+  }
+
+  $form['robotstxt'] = array(
+    '#type' => 'textarea',
+    '#title' => t('Contents of robots.txt'),
+    '#default_value' => $base,
+    '#cols' => 60,
+    '#rows' => 20,
+    '#wysiwyg' => FALSE,
+  );
+
+  return system_settings_form($form);
+}
Index: robotstxt.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/robotstxt/robotstxt.module,v
retrieving revision 1.4.4.12
diff -u -p -r1.4.4.12 robotstxt.module
--- robotstxt.module	3 Jan 2009 20:50:27 -0000	1.4.4.12
+++ robotstxt.module	17 Feb 2009 07:26:30 -0000
@@ -16,11 +16,9 @@ function robotstxt_help($path, $arg) {
 }
 
 /**
- * Defines the robots.txt path as a callback.
+ * Implementation of hook_menu().
  */
 function robotstxt_menu() {
-  $access_config = array('administer site configuration');
-
   $items['robots.txt'] = array(
     'page callback' => 'robotstxt_robots',
     'access callback' => TRUE,
@@ -31,36 +29,14 @@ function robotstxt_menu() {
     'description' => 'Manage your robots.txt file.',
     'page callback' => 'drupal_get_form',
     'page arguments' => array('robotstxt_admin_settings'),
-    'access arguments' => $access_config,
+    'access arguments' => array('administer site configuration'),
+    'file' => 'robotstxt.admin.inc',
   );
 
   return $items;
 }
 
 /**
- * You can edit the robots.txt for your site under admin/settings/robotstxt
- */
-function robotstxt_admin_settings() {
-  $base = variable_get('robotstxt', FALSE);
-
-  if ($base === FALSE) {
-    $base = _robotstxt_get_file_contents();
-  }
-
-  $form['robotstxt'] = array(
-    '#type' => 'textarea',
-    '#title' => t('Contents of robots.txt'),
-    '#default_value' => $base,
-    '#cols' => 60,
-    '#rows' => 20,
-    '#required' => FALSE,
-    '#wysiwyg' => FALSE,
-  );
-
-  return system_settings_form($form);
-}
-
-/**
  * Serve up the robots.txt file stored in the db.
  */
 function robotstxt_robots() {
