Viewing 5 replies - 1 through 5 (of 5 total)
  • I’m not sure what causes it, but the site tries to load the stylesheets and JavaScript files from https://python-gaming.com/blog/wordpress/mekire/%5B…css/js%5D, while they are at https://python-gaming.com/blog/wordpress/%5B…css/js%5D.

    My first guess would be to check the .htaccess. Here you can see how it should look.

    Thread Starter metulburr

    (@metulburr)

    this is my .htaccess file

    RewriteEngine On
    RewriteBase /blog/wordpress/
    RewriteRule ^index\.php$ - [L]
    
    # add a trailing slash to /wp-admin
    RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
    
    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^ - [L]
    RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) $2 [L]
    RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L]
    RewriteRule . index.php [L]

    and my version from wp-includes/version.php is

    <?php
    /**
     * The WordPress version string
     *
     * @global string $wp_version
     */
    $wp_version = '4.3.1';

    I cannot really decipher what it means inside the htaccess file.

    the htaccess file is in my root of var/www/html while wordpress is installed in /var/www/html/blog/wordpress

    Would this be a problem?

    in my apache config i have AllowOverride All fro Directive /var/www/html. Should i add a new directive for /var/www/html/blog/wordpress? Or does it not matter?

    EDIT:
    I tried adding

    <Directory /var/www/html/blog/wordpress>
    Options Indexes FollowSymLinks MultiViews
    AllowOverride All
    Order allow,deny
    allow from all
    </Directory>

    and restarting apache but nothing changed

    Thread Starter metulburr

    (@metulburr)

    after researching online and looking at others having the same issue with sub sites not finding the css/js path. They just changed their htaccess to what mine was. So i am not sure.

    and it looks to be regex which i never use and never can remember what much means.

    I am not sure if you need my config file too or not but here it is with modified passwords, etc.

    wp-config.php

    /* Multisite */
    define('WP_ALLOW_MULTISITE', true);
    
    // ** MySQL settings - You can get this info from your web host ** //
    /** The name of the database for WordPress */
    define('DB_NAME', 'name');
    
    /** MySQL database username */
    define('DB_USER', 'user');
    
    /** MySQL database password */
    define('DB_PASSWORD', 'pass');
    
    /** MySQL hostname */
    define('DB_HOST', 'host');
    
    /** Database Charset to use in creating database tables. */
    define('DB_CHARSET', 'utf8');
    
    /** The Database Collate type. Don't change this if in doubt. */
    define('DB_COLLATE', '');
    
    /**#@+
     * Authentication Unique Keys and Salts.
     *
     * Change these to different unique phrases!
     * You can generate these using the {@link https://api.www.ads-software.com/secret-key/1.1/salt/ www.ads-software.com   secret-key service}
     * You can change these at any point in time to invalidate all existing cookies. This will force all      users to have to log in again.
     *
     * @since 2.6.0
     */
    define('AUTH_KEY',         'put your unique phrase here');
    define('SECURE_AUTH_KEY',  'put your unique phrase here');
    define('LOGGED_IN_KEY',    'put your unique phrase here');
    define('NONCE_KEY',        'put your unique phrase here');
    define('AUTH_SALT',        'put your unique phrase here');
    define('SECURE_AUTH_SALT', 'put your unique phrase here');
    define('LOGGED_IN_SALT',   'put your unique phrase here');
    define('NONCE_SALT',       'put your unique phrase here');
    
    /**#@-*/
    
    /**
     * WordPress Database Table prefix.
     *
     * You can have multiple installations in one database if you give each
     * a unique prefix. Only numbers, letters, and underscores please!
     */
    $table_prefix  = 'wp_';
    
    /**
     * 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.www.ads-software.com/Debugging_in_WordPress
     */
    define('WP_DEBUG', false);
    define('MULTISITE', true);
    define('SUBDOMAIN_INSTALL', false);
    define('DOMAIN_CURRENT_SITE', 'python-gaming.com');
    define('PATH_CURRENT_SITE', '/blog/wordpress/');
    define('SITE_ID_CURRENT_SITE', 1);
    define('BLOG_ID_CURRENT_SITE', 1);
    /* 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');

    Thread Starter metulburr

    (@metulburr)

    EDIT:
    I fixed it. I copied my .htaccess file from my root /var/www/html to where wordpress is installed /var/www/html/blog/wordpress and it worked after that.

    Thanks, as your post led me find the answer

    Glad it helped and good to know ??

    Could you mark this topic as resolved?
    You can do that in the right sidebar.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Subsites look like raw html with no css’ is closed to new replies.