--- flickr.module.orig	2007-06-02 05:46:58.000000000 +0100
+++ flickr.module	2007-11-30 13:10:39.000000000 +0000
@@ -10,7 +10,7 @@ require_once(drupal_get_path('module', '
 function flickr_help($section) {
   switch ($section) {
     case 'admin/settings/flickr':
-     return t("You will need a Flickr API key to use this module. You can apply for one at <a href='@link'>@link</a>", array('@link' => url('http://www.flickr.com/services/api/keys/apply/')));
+     return t("You will need a Flickr API key to use this module. You can apply for one at <a href='@link'>@link</a> . To create a flickr entry click <a href='@link2'>here</a>", array('@link' => url('http://www.flickr.com/services/api/keys/apply/'),'@link2' => url('/admin/flickr/create/entry')));
     case 'admin/help#flickr':
       return t('The flickr module uses XML-RPC to connect to Flickr\'s API and retreive photo information.');
   }
@@ -31,7 +31,15 @@ function flickr_menu($may_cache) {
   global $user;
   $items = array();
  
+  $items[] = array(
+    'path' => 'admin/flickr/create/entry', 'title' => t('Create a Flickr entry'),
+    'callback' => 'flickr_admin_create_entry',
+    'access' => user_access('administer site configuration'),
+    'type' => MENU_NORMAL_ITEM,
+    'description' => t('Create a Flickr entry.')
+  );
+  
 

@@ -317,3 +327,63 @@ function theme_flickr_photoset($ps, $own
   return l($img, $photo_url, array('title' => $title), NULL, NULL, TRUE, TRUE);
 }
 
+function flickr_admin_create_entry() {
+  $output = drupal_get_form('flickr_admin_create_entry_form'); 
+  return $output; 
+}
+
+function flickr_admin_create_entry_form() {
+  $form['#validate'] = array('flickr_admin_create_entry_form_validate' => array()); 
+  $form['flickr_entry_name'] = array(    
+    '#type' => 'textfield',
+    '#title' => t('Flickr entry name'),
+    '#required' => TRUE,
+    '#description' => t('Flickr entry name eg . Birthday party.  '),
+  ); 
+  $form['flickr_entry_tags'] = array(    
+    '#type' => 'textfield',
+    '#title' => t('Flickr tags'),
+    '#required' => FALSE,
+    '#description' => t('Flickr tags  eg  birthday,party '),
+  ); 
+  $form['flickr_entry_genre'] = array(
+    '#type' => 'radios',
+    '#title' => t('Flickr photos that are'),
+    '#default_value' => 're',
+    '#options' => array('re' =>'recently added','ra' =>'randomly selected'),
+    '#description' => t('Flickr photos that are recently added or randomly selected '),
+  );
+  $form['flickr_entry_scope'] = array(
+    '#type' => 'radios','#title' => t('Flickr photos that are'),
+    '#default_value' => 'pu',
+    '#options' => array('pu' =>'selected from all flickr accounts','pr' =>'selected from an individual flickr account'),
+    '#description' => t('Flickr photos that are  selected for all or individula accounts ')
+  ); 
+  $form['flickr_entry_submit'] = array(
+    '#type' => 'submit',
+    '#value' => t('Create an flickr entry')
+  );
+  return $form ;
+}
+
+function flickr_admin_create_entry_form_submit($form_id, $form_values) {
+  $flickr_entries = variable_get('flickr_entries',"") ;
+  $flickr_entry  = array(
+    'name' => $form_values['flickr_entry_name'] ,  
+    'tags' => $form_values['flickr_entry_tags'] ,  
+    'genre' => $form_values['flickr_entry_genre'] , 
+    'scope' => $form_values['flickr_entry_scope'] 
+  );
+  if ($flickr_entries ==  "") { 
+    $flickr_entries = array();
+    $flickr_entries[] = array();
+  }
+  array_push($flickr_entries , $flickr_entry);
+  variable_set('flickr_entries',$flickr_entries);
+  drupal_set_message("Flickr entry <em>".$form_values['flickr_entry_name'] ."</em> has been posted") ;
+ }
+
