pH7Software / pH7-Social-Dating-CMS

😻 pH7Builder (formerly pH7CMS) is a Professional & Open Source Social Dating CMS written in PHP 8 🚀 This Social Dating Script aims to be low resource-intensive, powerful and secure. pH7Builder includes over 40 modules. It is the first Professional, Free & Open Source Social Dating Site Builder Software and the first choice for enterprise level Da
https://pH7Builder.com
MIT License
960 stars 575 forks source link

Theming engine not working #188

Closed Foxtrek64 closed 6 years ago

Foxtrek64 commented 6 years ago

After jumping through several hoops (#187) to even get the CMS installed, it seems it does not like the theming engine. Pages render as if the style sheets for the page could not be found (and when you look in the console, this is exactly what is happening.

The stylesheet which is supposed to be at /assets/css/color.css does not exist (more accurately, the /assets/ directory does not exist). I've ensured that permissions are set correctly and that this is not an issue with it not being able to create the folder.

I have tried changing the theme to see if this would kick the system into working properly, but the unthemed "theme" seems to prevail regardless of the configuration in the ACP.

Surprisingly, this bug is affecting the ACP as well, which I find interesting because in most other CMS the ACP does not use the theming system, rather it has its own hard-coded theme (see WoltLab, WordPress, etc.).

Any help in getting this working is appreciated. Besides the changes made to my .htaccess file (#187) and changes made in the ACP, this is an unmodified build as downloaded from SourceForge.

polynamaude commented 6 years ago

After reading over what you wrote, I'd add that the system itself doesn't use a direct filesystem references to deliver the css files (there's no direct link between a requested URL and it's position in filesystem hierarchy). For sure some folder are quite similar in name as the requested url but it's not directly served from the filesystem.

For example when the file color.css is requested, the system will do a "loopback" request using curl, compress, mimify and process the file as configured in the first place. Afterward on following request for the same file you'll get the cached version (what gives you a faster delivery). Some CMS like for example Joomla will do the same but use either APCu or other type of framework. Ph7CMS use s "home made" system.

There's no such thing as a "hard coded" theme, what you are seeing is basicly a theme that get served without the styling done and only bare html (no CSS files). Like I said in my first answer, start by disabling all the caching options, minify and such. Look at your logs for some 401 error also.

Afterward it will be easier to do some troubleshooting. Also, try to limit the number of opened issue as there's no use to making many when there's only one problem. It only make management harsher. I'm saying it here but it's something that you'll get wherever you do such action. Some people won't tell you but simply delete your actions at the end.

Foxtrek64 commented 6 years ago

Disabling all caching seems to have fixed the issue. I'm working through and seeing which ones I can leave enabled.

It seems I can get three versions of the site depending on what's enabled, looking purely at the home screen:

  1. The version that I was seeing before with only the default browser CSS
  2. A version with a full-screen background image with the login form on top of the image
  3. A version with a bordered background image with the login form below the image.

I'm assuming version 2 is the only correct one, so I only have the CSS cache enabled at this time.

pH-7 commented 6 years ago

The version 2 (version 3 could be OK too... I will need a screenshot to confirm it :)).

It shouldn't give different homepage versions depending on what caching option is enabled.

When you disable the caching options and reenable one per one, some cached files might still be broken and won't be updated again. I would suggest that you clean the "Static Files" cache, first and then, re-enable the option one per one in order to see which one is causing an issue (you might have a better idea of the problem if you look at the source file from your browser. e.g., http://your-website.com/asset/gzip/?t=js&d=static/js/&f=jquery/box.js,jquery/tipTip.js,bootstrap.js,common.js,str.js,holder.js)

KarlBaumann commented 6 years ago

Had the same issue, clearing static cache helped.

lock[bot] commented 5 years ago

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. Thanks, Pierre-Henry