Jump to content

Archived

This topic is now archived and is closed to further replies.

jasonkadlec

CSS doesn't load with WordPress in a SubDirectory?

Recommended Posts

jasonkadlec

I've got the site done and everything looking perfect - but I installed WordPress and everything in a folder:

 

/admin

 

Now I'm ready to take the site live, and I'm doing the usual:

 

copy the .htaccess and index into the root, edit the index.php file:

 

/** Loads the WordPress Environment and Template */
require('./admin/wp-blog-header.php');
 
I also added
 
define( 'LESS_FILE_MODE', true );
 
define( 'PL_NO_DYNAMIC_URL', true );
 
To the wp-config file
 
I went to the Permalinks Page to flush the re-rewrite 
 
I went to the DMS Tools - and saved the CSS and saved the custom scripts and all to no avail.
 
The site content loads, but not the CSS... 
 
What else can be done?  The site is hosted on GoDaddy * not my fault * 

Share this post


Link to post
Share on other sites
Jake

Hi jasonkadlec - I've got DMS running in sub-directories with no problems so it must have something to do with the move and all the steps you took along the way. Are you using a child theme? Is it just your custom changes that aren't loading?


Have you searched the forums yet or checked out the DMS user docs?

PageLines geek, blogging at MyUntangledLife.com

Share this post


Link to post
Share on other sites
jasonkadlec

Jake -- I am using a child theme - I installed it onto a different server, using a subdirectory and everything worked fine, so I'm pretty sure it is related to GoDaddy's server setup.

 

The GoDaddy tech support was pretty amazingly responsive, but in the end they could not figure out why it wasn't loading or compiling. 

 

There was already a WordPress installed in the Root of that same domain, so I ended up just moving the whole thing over, and it is now working (because once again the DMS theme, child theme are now in the same directory as the WordPress install). 

 

The GoDaddy folks were saying that they didn't see any calls to a CSS file... 

 

We'll just have to close the thread as "who knows" unless anyone else comes across this, has a GoDaddy hosting account and wants to continue to test it out.

 

Me? I like to host elsewhere than GoDaddy... second time I've been burned by some random thing not working, that works on the host I prefer.

Share this post


Link to post
Share on other sites
Jake

Thanks for checking back in and updating us jasonkadlec. I'm with you on GoDaddy but I'll leave it at that ;) .


Have you searched the forums yet or checked out the DMS user docs?

PageLines geek, blogging at MyUntangledLife.com

Share this post


Link to post
Share on other sites
mtaus

I'm running in to the same issue, but not with GoDaddy... Rackspace Cloud Sites.

 

I followed the WP instructions for pointing the site from a subdirectory to the root (http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory#Using_a_pre-existing_subdirectory_install). While it mostly worked, the one file that seemed to be "missing" was the dynamically compiled CSS/LESS file, which was pointing to http://www.domain.com/wordpress/?pageless=X_XXXXXXXXXX. I went to that address in my browser and found the stylesheet. So I'm not sure why it wasn't loading.

 

Any ideas?

 

Thanks in advance!

Share this post


Link to post
Share on other sites
jasonkadlec

mtaus -- sorry you're having the dreaded CSS missing issue... I wish I could tell you I solved it... I didn't, I worked around it. 

 

Try to enable wp_debug -- (edit wp-config.php ) and change false to true and see if you can debug it that way.

Share this post


Link to post
Share on other sites
Rob

Good advice. 

 

Do either of you have a cache plugin activated?

 

By any chance, did either of you use supersize for the background of a former Framework site?

 

Are either of you using some CDN?

 

Have you tried deactivating the plugin?


Former PageLines Moderator, Food Expert and Raconteur

Share this post


Link to post
Share on other sites
jasonkadlec
No cache used / not aware of godaddy having one on by default, no on the other question and no plugins used in my case, except for Contact Form7 but I doubt that would be the cause

Share this post


Link to post
Share on other sites
Danny
mtaus jasonkadlec Can you both provide a link to the site in question and also, enable PageLines debug mode please, (DMS Toolbar > Global Options > Advanced).

Please search our forums, before posting!

Share this post


Link to post
Share on other sites
danieldynasty

I had/have the same problem. I was told that there must be a "page/post" and post loop on the page so that the CSS can be generated. Then you can select the homepage to be a page/post in the Reading tab of Wordpress admin.

 

I tried troubleshooting it this way with DMS support but I haven't had much time to fully fix the problem; so in the meantime, I just saved the CSS from the /?pageless=XXXXXXXXX to a .css file, upload it, and link it using <link rel...> in the Custom CSS portion of DMS.

Share this post


Link to post
Share on other sites
jasonkadlec

Hm in my case, the "home" page was an actual page called "home" that had a post loop on it and in the settings was set to be the "static" home page.

 

What was strange is that when I set up the site on a different webhost, everything worked as expected -- which got me thinking it may be a server config thing more than a DMS thing.

Share this post


Link to post
Share on other sites
Rob

I hate to sound like I'm defending DMS till infinity but most of the things that have been mentioned by all who've added to it, seemed like server or settings related issues. That's why I've been questioning, and I think my colleagues have as well, what's going on in the background.

 

The news that you've resolved it comes as a great relief because diagnosing server or settings issues by forum is intensely difficult, slow and painstaking. I'm very happy for you!


Former PageLines Moderator, Food Expert and Raconteur

Share this post


Link to post
Share on other sites
mtaus

mtaus"] @[member="jasonkadlec Can you both provide a link to the site in question and also, enable PageLines debug mode please, (DMS Toolbar > Global Options > Advanced).

 

Danny sorry for the delayed reply... I moved the installation, so I could work around this issue. 

 

Thanks for your help.

Share this post


Link to post
Share on other sites
Danny
OK, so can we confirm that everyone who has experience this error, has had Wordpress installed via a sub-directory ? Would it be possible for you all to enable PL debug mode and copy and paste into you reply here please.

Please search our forums, before posting!

Share this post


Link to post
Share on other sites
bloom1creative

Hiya, I too seem to be having this issue, site loads minus all the base css in the editor / admin panel is a-ok... subdirectory linked ?- I have found the source of the issue.... if I swap in a file into the home directory called: hello-world.css" with the base css pasted in from another instal - all is well...

 

my site links should be..."http://localhost/me/dbbadgers/hello-world?pagedraft=1"

 

the css that the DMS generates is looking for:

<link rel="stylesheet" id="pagelines-draft-css" href="http://localhost/me/hello-world?pagedraft=1" type="text/css" media="all">

That returns a 404 at the mo in PL without my hashed up file being added...

I am guessing this dynamically generated page is a js creation somewhere in the DMS? 

 

Does this throw any light on the situation?

 

D.


Many thanks

 

Rob1n

Share this post


Link to post
Share on other sites
bloom1creative

not a subdirectory issue :\

 

just reset the global settings - flushed the cache inside the dms - could see the site css running ok without the hacked file.

 

The dynamic css file (/hello-world?pagedraft=1) was back (showing in the home directory) - then turned on debugging... it broke again! No css...


Many thanks

 

Rob1n

Share this post


Link to post
Share on other sites
Danny

Can you enable PL Debug mode please.

 

DMS Toolbar > Global Options > Advanced.

 

Then provide a link to the site in question, if the site is local, can you screenshot your settings please.


Please search our forums, before posting!

Share this post


Link to post
Share on other sites
bloom1creative

Hi Danny, here is a pic of the error... Site is local - which screenshot would help you best?

 

2cntds5.jpg


Many thanks

 

Rob1n

Share this post


Link to post
Share on other sites
Danny

How are you creating your local sites via MAMP ?

If so can you show me your local sites settings via MAMP.

Can you also screenshot your PL debug info, instructions above.

Can you disable all active plugins.

Can you also go to DMS Toolbar > Resets > Flush LESS

 

and then see if this resolves your issue.


Please search our forums, before posting!

Share this post


Link to post
Share on other sites
bloom1creative

Debug info:

WordPress Version : 3.6.1 Multisite Enabled : No Current Role : Administrator Framework Path : /Applications/AMPPS/www/me/dbbadgers/wp-content/themes/dms Framework URI : http://localhost/me/dbbadgers/wp-content/themes/dms Framework Version : 1.0.4 Framework Build : 1.0.4 PHP Version : 5.4 Child theme : Yes
/Applications/AMPPS/www/me/dbbadgers/wp-content/themes/viewer
http://localhost/me/dbbadgers/wp-content/themes/viewer PHP memory : 256 Mysql version : 5.6.13-log PHP type : Apache2handler PHP User : Bloom1Ltd OS : Darwin Licence OK : Dean@bloom1.co.uk Plugins : 3
dms-plugin-pro/dms-plugin-pro.php
postpins/postpins.php
salebar/salebar.php

Many thanks

 

Rob1n

Share this post


Link to post
Share on other sites
Danny

Did you Flush your LESS ?


Please search our forums, before posting!

Share this post


Link to post
Share on other sites
bloom1creative

Hiya,

All plugins now disabled, flushed cache, site created in Ampps on the MAC, standard php, mysql extensions configured...
WP installed as on any hosting platform...

 

Confused as to how the DMS generates the base css... and the whole <link rel="stylesheet" id="pagelines-draft-css" href="http://localhost/me/hello-world?pagedraft=1" type="text/css" media="all"> ???

 

 

Is it something to do with the draft css? We haven't added custom less yet on the local?

 

where is this file coming from as it I guess it is being created dynamilcally - no file exists in my directories?

 

Please help - going mental here! :)

D.


Many thanks

 

Rob1n

Share this post


Link to post
Share on other sites
bloom1creative

just a note: when I enabled the debug... the path it wanted to open for info was: http://localhost/me/dbbadgers/?pldebug=1... - which doesn't work

 

The actual path is: http://localhost/me/?pldebug=1 - when i remove the subdirectory - that works and gives me the debug info... Does that make any sense to you?


Many thanks

 

Rob1n

Share this post


Link to post
Share on other sites
Danny

No, but I haven't used the app you're using to create your local host. If you're on a Mac, can you try MAMP and see if this repeats the issue, as I am not able to recreate it on my test installs.


Please search our forums, before posting!

Share this post


Link to post
Share on other sites
jasonkadlec

Danny - I ended up migrating the site into the root domain to solve the issue, so I no longer can reproduce it.

Share this post


Link to post
Share on other sites

×