0
votes

I am created a sub domain www.support.rdmac.org.uk which works fine except that it has no styling. Having looked at several forums it seems like the browser needs to be directed towards the domain name for .css files.

At present it is:

"link rel="stylesheet" type="text/css" media="all" href="http://www.support.rdmac.org.uk/wp-content/themes/twentyten/style.css" /".

I think it should be:

"link rel="stylesheet" type="text/css" media="all" href="http://www.rdmac.org.uk/wp-content/themes/twentyten/style.css" /"

I have created an .htaccess file in my subdomain folder and used the following code

RewriteEngine on
RewriteRule ^themes/twentyten/style.css$ http://www.rdmac.org.uk/wp-content/themes/twentyten/style.css[L]

This is not working. Can anyone help?

1
Where you have placed the .htaccess? - Rahil Wazir
I have put the .htaccess file in the public_html/support folder where I loaded the Wordpress files. - user3480537
I have discovered that I also have a .htaccess in the main domain in public-html. It looks like <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> Should I have 2 .htaccess files? - user3480537

1 Answers

1
votes

If the htaccess is at the top level of your subdomain, perhaps you could add 'wp-content/' to the start of the rule. Formally the end should be " [R,L]", but I understand the R for rewrite is assumed when apache sees an external URL in the rewrite target.

RewriteRule ^wp-content/themes/twentyten/style.css$ http://www.rdmac.org.uk/wp-content/themes/twentyten/style.css [L]

Update:

However I see that your support subdomain appears to be using nginx. If this is the case then I think you need to look at how you configure nginx redirects instead of apache style htaccess directives on this server.