twitter_post.pages.inc 796 B

1234567891011121314151617181920212223
  1. <?php
  2. /**
  3. * Settings form callback
  4. */
  5. function twitter_post_admin_settings($form, &$form_state) {
  6. $form['twitter_post_types'] = array(
  7. '#type' => 'checkboxes',
  8. '#title' => t('Node types'),
  9. '#options' => node_type_get_names(),
  10. '#default_value' => variable_get('twitter_post_types', array('story' => 'story', 'blog' => 'blog')),
  11. );
  12. $form['twitter_post_default_format'] = array(
  13. '#type' => 'textfield',
  14. '#title' => t('Default format string'),
  15. '#maxlength' => 140,
  16. '#description' => t('The given text will be posted to twitter.com. You can use !url, !url-alias, !tinyurl, !title, and !user as replacement text.'),
  17. '#default_value' => variable_get('twitter_post_default_format', 'New post: !title !tinyurl'),
  18. );
  19. return system_settings_form($form);
  20. }