/[drupal]/contributions/modules/active_translation/active_translation.admin.inc
ViewVC logotype

Contents of /contributions/modules/active_translation/active_translation.admin.inc

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.4 - (show annotations) (download) (as text)
Mon Nov 17 08:42:56 2008 UTC (12 months, 1 week ago) by drewish
Branch: MAIN
CVS Tags: DRUPAL-6--1-4, DRUPAL-6--1-2, DRUPAL-6--1-3, HEAD
Changes since 1.3: +16 -3 lines
File MIME type: text/x-php
#328642 by drewish: Add option to hide local.module's translated language links on the node.
1 <?php
2 // $Id: active_translation.admin.inc,v 1.3 2008/06/13 19:48:52 drewish Exp $
3
4 /**
5 * Settings form.
6 */
7 function active_translation_settings_form() {
8 $form['active_translation_show_status'] = array(
9 '#type' => 'radios',
10 '#title' => t('Show Translation Status Message'),
11 '#options' => array(
12 1 => t('Yes, inform visitors when they are viewing the node in another language because it has not been translated into their language.'),
13 0 => t("No, don't bother them."),
14 ),
15 '#default_value' => variable_get('active_translation_show_status', 1),
16 );
17 $form['active_translation_hide_node_links'] = array(
18 '#type' => 'radios',
19 '#title' => t("Hide Node Translation Links"),
20 '#options' => array(
21 1 => t("Yes, hide the local module's links to other translations."),
22 0 => t('No, leave the links alone.'),
23 ),
24 '#default_value' => variable_get('active_translation_hide_node_links', 0),
25 '#description' => t("This can be useful the locale module's language switcher block is being used to select the language making the node links redundant."),
26 );
27
28 return system_settings_form($form);
29 }
30
31 /**
32 * Rebuild translation table form.
33 */
34 function active_translation_rebuild_form() {
35 $form['help'] = array(
36 '#type' => 'item',
37 '#value' => t('If you are experiencing problems with missing translations you should try rebuilding the Active Translation table.'),
38 );
39 $form['submit'] = array(
40 '#type' => 'submit',
41 '#value' => t('Rebuild'),
42 );
43 $form['#submit'] = array('active_translation_rebuild_on_submit');
44 return $form;
45 }

  ViewVC Help
Powered by ViewVC 1.1.2