title: Widget Area not showing in Wordpress Staging Site
body: <p>I am having a weird issue with my footer widgets on a site I am working on. In my local environment the widgets appeared just fine, but on the staging site, the widgets do not appear. When I look at the live preview, it says I have 3 widget areas but they don't appear on this page. They are in the footer.php file (displays on every page), which is running and displaying the non-widget related parts on the screen. Like I said, it was working fine in my local environment. Any ideas?</p>
  <p>Edit: I forgot to mention that when I view it under Appearance&gt;Widgets, it says my site has no widget areas.</p>
  <p>Another Edit: I found these errors in the error log. In the first one, I noticed the 7.4. Does that mean it is loading php 7.4? I built this theme in local using php 8. Could that be the issue?</p>
  <pre><code>[06-Aug-2021 13:13:51 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/opt/cpanel/ea-php70/root/usr/lib64/php/modules/ixed.7.4.lin' - /opt/cpanel/ea-php70/root/usr/lib64/php/modules/ixed.7.4.lin: cannot open shared object file: No such file or directory in Unknown on line 0
  [06-Aug-2021 13:14:48 UTC] PHP Warning:  Invalid argument supplied for foreach() in /home3/growinj1/public_html/staging/8458/wp-includes/rest-api/endpoints/class-wp-rest-sidebars-controller.php on line 104
  [06-Aug-2021 13:15:33 UTC] PHP Warning:  array_merge(): Expected parameter 3 to be an array, bool given in /home3/growinj1/public_html/staging/8458/wp-includes/class-wp-customize-widgets.php on line 379
  [06-Aug-2021 13:15:33 UTC] PHP Warning:  Invalid argument supplied for foreach() in /home3/growinj1/public_html/staging/8458/wp-includes/class-wp-customize-widgets.php on line 426
  </code></pre>
  <p>Here is my functions.php:</p>
  <pre><code>
      &lt;?php 
          function smm_files() {
              wp_enqueue_script('header-js', get_theme_file_uri('/js/header.js'), NULL, '1.0.0', true);
              wp_enqueue_style('main-styles', get_stylesheet_uri());
              wp_enqueue_style('google-fonts', '//fonts.googleapis.com/css2?family=Arsenal:ital,wght@0,400;0,700;1,400&amp;display=swap');
          }
          add_action('wp_enqueue_scripts', 'smm_files');
      
          function smm_features() {
              add_theme_support('title-tag');
              register_nav_menu('headerMenuLocation', 'Header Menu Location');
          }
          add_action('after_setup_theme', 'smm_features');
      
          function smm_widgets_init() {
      
              register_sidebar( array(
                  'name' =&gt; 'Footer Sidebar 1',
                  'id' =&gt; 'footer-sidebar-1',
                  'description' =&gt; 'Appears in the footer area',
                  'before_widget' =&gt; '&lt;aside id=&quot;%1$s&quot; class=&quot;widget %2$s&quot;&gt;',
                  'after_widget' =&gt; '&lt;/aside&gt;',
                  'before_title' =&gt; '&lt;h3 class=&quot;widget-title&quot;&gt;',
                  'after_title' =&gt; '&lt;/h3&gt;',
                  ) );
                  register_sidebar( array(
                  'name' =&gt; 'Footer Sidebar 2',
                  'id' =&gt; 'footer-sidebar-2',
                  'description' =&gt; 'Appears in the footer area',
                  'before_widget' =&gt; '&lt;aside id=&quot;%1$s&quot; class=&quot;widget %2$s&quot;&gt;',
                  'after_widget' =&gt; '&lt;/aside&gt;',
                  'before_title' =&gt; '&lt;h3 class=&quot;widget-title&quot;&gt;',
                  'after_title' =&gt; '&lt;/h3&gt;',
                  ) );
                  register_sidebar( array(
                  'name' =&gt; 'Footer Sidebar 3',
                  'id' =&gt; 'footer-sidebar-3',
                  'description' =&gt; 'Appears in the footer area',
                  'before_widget' =&gt; '&lt;aside id=&quot;%1$s&quot; class=&quot;widget %2$s&quot;&gt;',
                  'after_widget' =&gt; '&lt;/aside&gt;',
                  'before_title' =&gt; '&lt;h3 class=&quot;widget-title&quot;&gt;',
                  'after_title' =&gt; '&lt;/h3&gt;',
                  ) );
          }
          add_action( 'widgets_init', 'smm_widgets_init' );
      
          function smm_post_thumbnails() {
              add_theme_support( 'post-thumbnails' );
          }
          add_action( 'after_setup_theme', 'smm_post_thumbnails' );
      
      //Page Slug Body Class
      function add_slug_body_class( $classes ) {
          global $post;
          if ( isset( $post ) ) {
          $classes[] = $post-&gt;post_type . '-' . $post-&gt;post_name;
          }
          return $classes;
          }
          add_filter( 'body_class', 'add_slug_body_class' );
  
  </code></pre>
  <p>And here is the footer.php:</p>
  <pre><code>        &lt;footer&gt;
              &lt;div id=&quot;footer-sidebar&quot; class=&quot;secondary&quot;&gt;
                  &lt;div id=&quot;footer-sidebar1&quot;&gt;
          &lt;?php
              if(is_active_sidebar('footer-sidebar-1')){
                  dynamic_sidebar('footer-sidebar-1');
              } endif;
          ?&gt;
                  &lt;/div&gt;
                  &lt;div id=&quot;footer-sidebar2&quot;&gt;
          &lt;?php
              if(is_active_sidebar('footer-sidebar-2')){
                  dynamic_sidebar('footer-sidebar-2');
              } endif;
          ?&gt;
                  &lt;/div&gt;
                  &lt;div id=&quot;footer-sidebar3&quot;&gt;
          &lt;?php
              if(is_active_sidebar('footer-sidebar-3')){
                  dynamic_sidebar('footer-sidebar-3');
              } endif;
          ?&gt;
                  &lt;/div&gt;
              &lt;/div&gt;
              &lt;div class=&quot;bottom-el&quot;&gt;
                  &lt;span&gt;&amp;copy 2021 SiteName&lt;/span&gt;&lt;span&gt;&lt;a href=&quot;&lt;?php echo site_url('/privacy-policy') 
                              ?&gt;&quot;&gt;Privacy Policy&lt;/a&gt;&lt;/span&gt;
              &lt;/div&gt;
          &lt;/footer&gt;
  &lt;?php wp_footer(); ?&gt;
      &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>