title: 500 error in multisite on new subdomain - are my wp-config.php and htaccess files correct
body: <p>I'm getting Error 500 on my new subdomain. I'm aware that there are multiple steps to resolving this issue (there's a lot of support on this issue in stackoverflow), but before I proceed with troubleshooting, I first want to be sure that the code is correct.</p>
  <p>Here is the last part of my wp-config.php (this includes what I added to the file):</p>
  <pre><code>/**
   * For developers: WordPress debugging mode.
   *
   * Change this to true to enable the display of notices during development.
   * It is strongly recommended that plugin and theme developers use WP_DEBUG
   * in their development environments.
   *
   * For information on other constants that can be used for debugging,
   * visit the Codex.
   *
   * @link https://codex.wordpress.org/Debugging_in_WordPress
   */
  define('WP_DEBUG', false);
  
  define( 'WP_ALLOW_MULTISITE', true );
  
  define('MULTISITE', true);
  define('SUBDOMAIN_INSTALL', true);
  define('DOMAIN_CURRENT_SITE', 'mydomain.com');
  define('PATH_CURRENT_SITE', '/');
  define('SITE_ID_CURRENT_SITE', 1);
  define('BLOG_ID_CURRENT_SITE', 1);
  define('WP_ALLOW_REPAIR', true);
  
  /* That's all, stop editing! Happy blogging. */
  
  /** Absolute path to the WordPress directory. */
  if ( !defined('ABSPATH') )
      define('ABSPATH', dirname(__FILE__) . '/');
  
  /** Sets up WordPress vars and included files. */
  require_once(ABSPATH . 'wp-settings.php');
  
  // define( 'WP_CRON_LOCK_TIMEOUT', 120   ); 
  // define( 'AUTOSAVE_INTERVAL',    300   );
  // define( 'WP_POST_REVISIONS',    5     );
  // define( 'EMPTY_TRASH_DAYS',     7     );
  define( 'WP_AUTO_UPDATE_CORE',  true  );
  </code></pre>
  <p>I feel quite confident about the wp-config.php file, but less so about the changes I made to the .htaccess file. Here is the entire .htaccess file:</p>
  <pre><code># BEGIN WordPress
  # The directives (lines) between &quot;BEGIN WordPress&quot; and &quot;END WordPress&quot; are
  # dynamically generated, and should only be modified via WordPress filters.
  # Any changes to the directives between these markers will be overwritten.
  &lt;IfModule mod_expires.c&gt;
      ExpiresActive On
      ExpiresByType image/jpg &quot;access plus 24 hours&quot;
      ExpiresByType image/jpeg &quot;access plus 24 hours&quot;
      ExpiresByType image/gif &quot;access plus 24 hours&quot;
      ExpiresByType image/png &quot;access plus 24 hours&quot;
      ExpiresByType text/css &quot;access plus 24 hours&quot;
      ExpiresByType application/pdf &quot;access plus 1 week&quot;
      ExpiresByType text/javascript &quot;access plus 24 hours&quot;
      ExpiresByType text/html &quot;access plus 5 minutes&quot;
      ExpiresByType image/x-icon &quot;access plus 1 year&quot;
      ExpiresDefault &quot;access plus 24 hours&quot;
  &lt;/IfModule&gt;
  &lt;ifModule mod_headers.c&gt;
  Header set X-Endurance-Cache-Level &quot;2&quot;
  &lt;/ifModule&gt;
  &lt;IfModule mod_rewrite.c&gt;
  RewriteEngine On
  RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
  RewriteBase /
  RewriteRule ^index\.php$ - [L]
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule . /index.php [L]
  &lt;/IfModule&gt;
  
  # END WordPress
  RewriteEngine On
  RewriteCond %{HTTPS} off
  RewriteCond %{REQUEST_URI} !^/\.well-known/acme-challenge/[0-9a-zA-Z_-]+$
  RewriteCond %{REQUEST_URI} !^/\.well-known/cpanel-dcv/[0-9a-zA-Z_-]+$
  RewriteCond %{REQUEST_URI} !^/\.well-known/pki-validation/(?:\ Ballot169)?
  RewriteCond %{REQUEST_URI} !^/\.well-known/pki-validation/[A-F0-9]{32}\.txt(?:\ Comodo\ DCV)?$
  RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]]
  
  # php -- BEGIN cPanel-generated handler, do not edit
  # Set the “ea-php73” package as the default “PHP” programming language.
  &lt;IfModule mime_module&gt;
    AddHandler application/x-httpd-ea-php73 .php .php7 .phtml
  &lt;/IfModule&gt;
  # php -- END cPanel-generated handler, do not edit
  
  RewriteEngine On
  RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
  RewriteBase /
  RewriteRule ^index\.php$ - [L]
  
  # add a trailing slash to /wp-admin
  RewriteRule ^wp-admin$ wp-admin/ [R=301,L]
  
  RewriteCond %{REQUEST_FILENAME} -f [OR]
  RewriteCond %{REQUEST_FILENAME} -d
  RewriteRule ^ - [L]
  RewriteRule ^(wp-(content|admin|includes).*) $1 [L]
  RewriteRule ^(.*\.php)$ $1 [L]
  RewriteRule . index.php [L]
  </code></pre>
  <p>What I don't quite get about the .htaccess file is that it says to replace the rules: <a href="https://i.stack.imgur.com/nA8I0.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/nA8I0.png" alt="Multisite Network Admin WordPress" /></a> As you can see in my .htaccess posted above, all I did was add this code to the end. Am I supposed to overwrite the existing rules? If so, which rules do I overwrite?</p>
  <p>I would greatly appreciate it if someone could look these two files over and tell me if they are correct or not. And if not, how to fix my code. This way, I'll know if I can proceed with the rest of the troubleshooting steps (with resources such as: <a href="https://stackoverflow.com/questions/20400685/500-error-for-new-site-in-multisite-wordpress">500 error for new site in multisite wordpress</a>)</p>