functions.php 914 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?php
  2. /**
  3. * Theme functions and definitions
  4. *
  5. * @package HelloElementorChild
  6. */
  7. include( get_stylesheet_directory() . '/mark.php' );
  8. add_theme_support( 'post-thumbnails', array( 'page' ) );
  9. /**
  10. * Load child theme css and optional scripts
  11. *
  12. * @return void
  13. */
  14. function hello_elementor_child_enqueue_scripts() {
  15. wp_enqueue_style(
  16. 'hello-elementor-child-style',
  17. get_stylesheet_directory_uri() . '/style.css',
  18. [
  19. 'hello-elementor-theme-style',
  20. ],
  21. '1.0.0'
  22. );
  23. wp_enqueue_script(
  24. 'hello-elementor-child-scripts',
  25. get_stylesheet_directory_uri() . '/scripts.js',
  26. [
  27. 'jquery',
  28. ],
  29. '1.0.0'
  30. );
  31. }
  32. add_action( 'wp_enqueue_scripts', 'hello_elementor_child_enqueue_scripts' );
  33. add_filter('hello_elementor_page_title', '__return_false');
  34. add_filter( 'body_class', function( $classes ) {
  35. return array_merge( $classes, [ 'q-app-styles' ] );
  36. } );