Jump to content

Designers Mode and Theme Issues.


Recommended Posts

I have three difference issues with designer mode and themes, and I am not sure if they are all related or not.

1. When enabling Designer's Mode, I get the following error:

Could contain: Text, File

It seems that there is an issue with writing certain files (not all of them), and it happens every time with the exact same template files. As you can see from this image, the file is written as 0 bytes, but the content is not.

Could contain: Chart, Plot, Page, Text, Measurements

If I hit the back button on the browser, the create.phtml file will be written to correctly, but there will be another error afterwards with another file.

Could contain: Chart, Plot, Page, Text, Measurements

As I stated earlier, the errors are on the same template files each time, but as you can see, other template files are written without issue.

I did some of my own test writing data to the disk and did not have any issues. No read write, or owner permission issues.

I also get this message when installing applications.

2. In other cases, after running Designer's Mode, will get the message that Designers' mode is enabled, but in fact, it is not.

This seems to be random when it will work and when it does not. But I have noticed that if there is only one theme installed or the default theme is set as the default, then Designer Mode will not stay enabled, regardless if the following message states that it is.

Could contain: File, Computer, Electronics, Pc, Text, Computer Hardware, Hardware

3. It seems that I have a lot of remnant templates in the core_theme_template table which cannot be removed. These templates now belong to template_set_id 0, and while they are user added, and there is no way to delete these from the template sets in the ACP as they are regarded as core entries. 

The problem is that each time I add a new theme, all of these remnant templates entries get added to the theme set.

I want to know if it is okay to just delete these entries from the database template table or is there another way I can do this more safely?

 

Edited by TDBF
Link to comment
Share on other sites

Checking your server error logs would be your best bet. I suspect its very highly likely something is actually blocking them because of the content, so if you have things running like mod_sec, securi or similar, I would check the logs of those too.

Link to comment
Share on other sites

4 hours ago, Marc Stridgen said:

Checking your server error logs would be your best bet. I suspect its very highly likely something is actually blocking them because of the content, so if you have things running like mod_sec, securi or similar, I would check the logs of those too.

It seems that Imunify is flagging /system/Theme/Advanced/Theme.php as 'black hash triggering' when saving contents using file_put_contents.

Looks like this is a false positive, as the templates that are being flagged are core and have not modified, but it could also be the theme.php script which triggering this error?

I have put the rule on ignore and this seems to have fixed all the issues I was getting. As I said, they all seemed related, and Imunify happened to be the last logs I checked today.

Link to comment
Share on other sites

7 minutes ago, Marc Stridgen said:

Glad to hear you found the issue 🙂

Me too, and thanks for the assist. However, in the process of trying to fix this, I have found a bug which relates to number 3 in my list. 

I'm just going through the process of trying to replicate this issue before posting the issue.

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...