From 7e1527ee61bc10b3765b95b9af8faaa2254da5a8 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Fri, 7 Oct 2005 06:11:12 +0000 Subject: - Patch #29465: new form API by Adrian et al. TODO: + The contact.module was broken; a new patch for contact.module is needed. + Documentation is needed. + The most important modules need to be updated ASAP. --- modules/blogapi/blogapi.module | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'modules/blogapi/blogapi.module') diff --git a/modules/blogapi/blogapi.module b/modules/blogapi/blogapi.module index e983177be..a85e1d485 100644 --- a/modules/blogapi/blogapi.module +++ b/modules/blogapi/blogapi.module @@ -548,10 +548,21 @@ function blogapi_blogger_title(&$contents) { } function blogapi_settings() { + $form['blogapi_engine'] = array( + type => 'select', title => t('XML-RPC Engine'), default_value => variable_get('blogapi_engine', 0), + options => array(0 => 'Blogger', 1 => 'MetaWeblog', 2 => 'Movabletype'), + description => t('RSD or Really-Simple-Discovery is a mechanism which allows external blogger tools to discover the APIs they can use to interact with Drupal. Here you can set the preferred method for blogger tools to interact with your site. The common XML-RPC engines are Blogger, MetaWeblog and Movabletype. If you are not sure which is the correct setting, choose Blogger.') + ); + $node_types = node_get_types(); $defaults = isset($node_types['blog']) ? array('blog') : array(); - $output .= form_checkboxes(t('Blog types'), "blogapi_node_types", variable_get('blogapi_node_types', $defaults), $node_types, t('Select the content types for which you wish to enable posting via blogapi. Each type will appear as a different "blog" in the client application (if supported).'), 0, 1); - return $output; + $form['blogapi_node_types'] = array( + type => 'checkboxes', title => t('Blog types'), required => TRUE, + default_value => variable_get('blogapi_node_types', $defaults), options => $node_types, + description => t('Select the content types for which you wish to enable posting via blogapi. Each type will appear as a different "blog" in the client application (if supported).') + ); + + return $form; } function blogapi_menu($may_cache) { -- cgit v1.2.3