class-taxonomy-content-fields.php 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. <?php
  2. /**
  3. * WPSEO plugin file.
  4. *
  5. * @package WPSEO\Admin
  6. */
  7. /**
  8. * This class parses all the values for the general tab in the Yoast SEO settings metabox.
  9. */
  10. class WPSEO_Taxonomy_Content_Fields extends WPSEO_Taxonomy_Fields {
  11. /**
  12. * Returns array with the fields for the general tab.
  13. *
  14. * @return array
  15. */
  16. public function get() {
  17. $fields = [
  18. 'title' => $this->get_field_config(
  19. '',
  20. '',
  21. 'hidden',
  22. ''
  23. ),
  24. 'desc' => $this->get_field_config(
  25. '',
  26. '',
  27. 'hidden',
  28. ''
  29. ),
  30. 'linkdex' => $this->get_field_config(
  31. '',
  32. '',
  33. 'hidden',
  34. ''
  35. ),
  36. 'content_score' => $this->get_field_config(
  37. '',
  38. '',
  39. 'hidden',
  40. ''
  41. ),
  42. 'focuskw' => $this->get_field_config(
  43. '',
  44. '',
  45. 'hidden',
  46. ''
  47. ),
  48. ];
  49. /**
  50. * Filter: 'wpseo_taxonomy_content_fields' - Adds the possibility to register additional content fields.
  51. *
  52. * @api array - The additional fields.
  53. */
  54. $additional_fields = apply_filters( 'wpseo_taxonomy_content_fields', [] );
  55. return $this->filter_hidden_fields( array_merge( $fields, $additional_fields ) );
  56. }
  57. }