Simple Machines Community Forum

Customizing SMF => Graphics and Templates => Topic started by: Random Username on January 20, 2023, 02:45:50 PM

Title: Error on installing theme.
Post by: Random Username on January 20, 2023, 02:45:50 PM
Themes/temp/theme_info.xml): Failed to open stream: No such file or directory

Any ideas?

Thank you
Title: Re: Error on installing theme.
Post by: Diego Andrés on January 20, 2023, 02:48:31 PM
What theme are you trying to install?
Title: Re: Error on installing theme.
Post by: Kindred on January 20, 2023, 02:49:03 PM
is the theme named temp?

Is there a theme_info.xml in the theme archive that you are trying to install?
Title: Re: Error on installing theme.
Post by: Random Username on January 20, 2023, 02:58:53 PM
No, I named the theme Dark. Yes, I copied and altered a theme_info.xml file from two different themes. Both failed the same way. I don't know why it's looking for a folder named temp. I tried clearing the cache. But I have caching turned off anyway at the moment and smf caching was set to use a directory named cache, not temp.

Thank you Kindred.
Title: Re: Error on installing theme.
Post by: Kindred on January 20, 2023, 03:00:29 PM
You are attempting to install a theme using the theme manager?

Please attach the theme archive that you are trying to use.
Title: Re: Error on installing theme.
Post by: Random Username on January 20, 2023, 03:32:32 PM
Yes I am using the theme manager to upload a zip folder. This is the error I get on upload "SMF was unable to find any valid information within the package-info.xml file included within the Package. There may be an error with the modification, or the package may be corrupt" in addition to the error I mentioned in the error log: /Sources/Subs-Themes.php (Line 253)

Type of error: General
Error message Select
2: file_get_contents(.../public_html/Themes/temp/theme_info.xml): Failed to open stream: No such file or directory

The theme works if simply placed in the themes directory, except for the thumbnail preview in SMF Packs CMS mod. I figured the reason that the thumbnail didn't work and the default theme kept showing in the available theme list for members to select even when unchecked as on the available list was because I didn't install it through the theme manager. Line 253 of Subs.Themes.php reads $theme_info_xml = new xmlArray(file_get_contents($path . '/theme_info.xml'));

This is what I used the second time for an xml file:

<theme-info xmlns="http://www.simplemachines.org/xml/theme-info" xmlns:smf="http://www.simplemachines.org/">
<id>Dark</id>
<!--   The theme's version   -->
<version>1.0</version>
<install for="2.1 - 2.1.99"/>
<name>Dark</name>
<author name="Dark"/></author>
<website>https://custom.simplemachines.org/</website>
<!--   Template layers to use, defaults to "html,body".   -->
<layers>html,body</layers>
<!--   Templates to load on startup. Default is "index".   -->
<templates>index</templates>
</theme-info>


Title: Re: Error on installing theme.
Post by: TwitchisMental on January 20, 2023, 09:33:59 PM
Quote from: Kindred on January 20, 2023, 03:00:29 PMPlease attach the theme archive that you are trying to use.
This would help us help you a bit better.

You can delete the attachment after we find the issue if you are worried about others having it.
Title: Re: Error on installing theme.
Post by: Random Username on January 23, 2023, 11:49:18 PM
I've decided to hold off on this since I am still making changes to the default theme. I will share when complete, including some special goodies I think people will like.

Thank you