<?php /*

  This file is part of a child theme called Artech welders.
  Functions in this file will be loaded before the parent theme's functions.
  For more information, please read
  https://developer.wordpress.org/themes/advanced-topics/child-themes/

*/

// this code loads the parent's stylesheet (leave it in place unless you know what you're doing)

function your_theme_enqueue_styles() {

    $parent_style = 'parent-style';

    wp_enqueue_style( $parent_style, 
      get_template_directory_uri() . '/style.css'); 

    wp_enqueue_style( 'child-style', 
      get_stylesheet_directory_uri() . '/style.css', 
      array($parent_style), 
      wp_get_theme()->get('Version') 
    );
}

add_action('wp_enqueue_scripts', 'your_theme_enqueue_styles');
add_filter('use_block_editor_for_post','__return_false',10);

/*  Add your own functions below this line.
    ======================================== */ 
add_action('wp_head', function (){
if( is_single() || is_page() ) {
$meta_keywords_raw = (get_post_meta(get_the_ID(), 'keywords', true));
if ($meta_keywords_raw)	 {
$meta_keywords = preg_replace('/\s*,\s*/', ', ', $meta_keywords_raw);
?>
<meta name="keywords" content="<?= $meta_keywords; ?>">
<?php }} } );
