function nodewords_frontpage_form in Nodewords: D6 Meta Tags 5
Menu callback: front page settings form.
1 string reference to 'nodewords_frontpage_form'
- nodewords_menu in ./
nodewords.module - Implementation of hook_menu().
File
- ./
nodewords.module, line 425 - Assign META tags to nodes, vocabularies, terms and pages.
Code
function nodewords_frontpage_form() {
$tags = _nodewords_load('page', '');
$form = array();
$form['nodewords'] = _nodewords_form('page', $tags);
unset($form['nodewords']['#title']);
unset($form['nodewords']['#type']);
if (empty($form['nodewords'])) {
$form['nodewords'] = array(
'#value' => t('Currently no meta tags can be assigned to the front page because you have disabled all tags to show on the edit forms. <a href="!nodewords-settings-url" title="meta tags settings">Enable some meta tags to show on edit forms</a> first.', array(
'!nodewords-settings-url' => url('admin/content/nodewords'),
)),
);
}
else {
if (!variable_get('nodewords-use_front', 1)) {
$form['nodewords'] = array(
'#value' => t('You can not assign meta tags for the front page here because you have disabled them at the <a href="!nodewords-settings-url" title="Meta tags settings">meta tags settings page</a>. Instead, the meta tags for the view, panel or node you have set as front page will be used.', array(
'!nodewords-settings-url' => url('admin/content/nodewords'),
)),
);
}
else {
$form['submit'] = array(
'#type' => 'submit',
'#value' => t('Submit'),
'#weight' => 40,
);
}
}
return $form;
}