theme-settings.php 3.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. <?php
  2. /**
  3. * Implements hook_form_FORM_ID_alter().
  4. *
  5. * @param $form
  6. * The form.
  7. * @param $form_state
  8. * The form state.
  9. */
  10. function rainbow_form_system_theme_settings_alter(&$form, &$form_state) {
  11. $form['prof_settings'] = array(
  12. '#type' => 'fieldset',
  13. '#title' => t('Professional Theme Settings'),
  14. '#collapsible' => FALSE,
  15. '#collapsed' => FALSE,
  16. );
  17. $form['prof_settings']['breadcrumbs'] = array(
  18. '#type' => 'checkbox',
  19. '#title' => t('Show breadcrumbs in a page'),
  20. '#default_value' => theme_get_setting('breadcrumbs','rainbow'),
  21. '#description' => t("Check this option to show breadcrumbs in page. Uncheck to hide."),
  22. );
  23. $form['prof_settings']['top_social_link'] = array(
  24. '#type' => 'fieldset',
  25. '#title' => t('Social links in header'),
  26. '#collapsible' => TRUE,
  27. '#collapsed' => FALSE,
  28. );
  29. $form['prof_settings']['top_social_link']['social_links'] = array(
  30. '#type' => 'checkbox',
  31. '#title' => t('Show social icons (Facebook, Twitter and RSS) in header'),
  32. '#default_value' => theme_get_setting('social_links', 'rainbow'),
  33. '#description' => t("Check this option to show twitter, facebook, rss icons in header. Uncheck to hide."),
  34. );
  35. $form['prof_settings']['top_social_link']['twitter_url'] = array(
  36. '#type' => 'textfield',
  37. '#title' => t('Twitter profile url'),
  38. '#default_value' => theme_get_setting('twitter_url', 'rainbow'),
  39. '#description' => t("Enter your Twitter profile url."),
  40. );
  41. $form['prof_settings']['top_social_link']['facebook_url'] = array(
  42. '#type' => 'textfield',
  43. '#title' => t('Facebook profile url'),
  44. '#default_value' => theme_get_setting('facebook_url', 'rainbow'),
  45. '#description' => t("Enter your Facebook profile url."),
  46. );
  47. $form['prof_settings']['top_social_link']['gplus_url'] = array(
  48. '#type' => 'textfield',
  49. '#title' => t('Gplus profile url'),
  50. '#default_value' => theme_get_setting('gplus_url', 'rainbow'),
  51. '#description' => t("Enter your Gplus profile url."),
  52. );
  53. $form['prof_settings']['top_social_link']['linkedin_url'] = array(
  54. '#type' => 'textfield',
  55. '#title' => t('Linkedin profile url'),
  56. '#default_value' => theme_get_setting('linkedin_url', 'rainbow'),
  57. '#description' => t("Enter your Linkedin profile url."),
  58. );
  59. $form['prof_settings']['top_social_link']['dribbble_url'] = array(
  60. '#type' => 'textfield',
  61. '#title' => t('Dribbble profile url'),
  62. '#default_value' => theme_get_setting('dribbble_url', 'rainbow'),
  63. '#description' => t("Enter your Dribbble profile url."),
  64. );
  65. $form['prof_settings']['top_social_link']['pinterest_url'] = array(
  66. '#type' => 'textfield',
  67. '#title' => t('Pinterest profile url'),
  68. '#default_value' => theme_get_setting('pinterest_url', 'rainbow'),
  69. '#description' => t("Enter your Pinterest profile url."),
  70. );
  71. $form['prof_settings']['top_social_link']['youtube_url'] = array(
  72. '#type' => 'textfield',
  73. '#title' => t('Youtube profile url'),
  74. '#default_value' => theme_get_setting('youtube_url', 'rainbow'),
  75. '#description' => t("Enter your Youtube profile url."),
  76. );
  77. }