• Welcome to Simple Machines Community Forum. Please login or sign up.
September 18, 2021, 06:33:53 PM

News:

Join the Facebook Fan Page.


Theme approval guidelines

Started by Gwenwyfar, July 08, 2018, 10:25:29 AM

Previous topic - Next topic

Gwenwyfar

July 08, 2018, 10:25:29 AM Last Edit: March 05, 2019, 09:36:12 AM by Gwenwyfar
So you want to make a theme (or you already made one!) and want to submit it to the theme site. All themes submitted to the theme site will first go through a review process before they receive an approved status and are shown in searches. If a problem is found during the review, you will be asked to fix it before proceeding. Here's how to get your theme ready:

Theme guidelines
Take some time to get acquainted with the guidelines outlined here. Your theme will have to comply with them.

Required folders

       
  • css: This folder should have all your custom css files.
  • images: Images folder containing all images used by your theme.
  • scripts: This is where you can add theme.js to add any custom js, or you may add your own files.
  • languages: This should contain the Settings.english.php file, which is where you can edit the description for your theme. You can include other language files for your theme here, but english should always be available. If you are using any custom strings, these can be added in ThemeStrings.english.php. This file will be loaded when ['require_theme_strings'] is set to true.

Required files

       
  • theme_info.xml: This file contains data about your theme. You can download a template below. (More about theme_info.xml)
  • license.txt: This file should contain license information for your theme, and any other licensed work you have used in your theme (ex: images). For help with choosing a license, see the wiki page on Customization Licenses and this topic. You can use any license you want to, or write your own license.
  • images/thumbnail.gif: A preview thumbnail of your theme. Preferably, you should use the same size as the default thumbnail.
  • index.php: A copy of the default file.

Packaging
And finally, once you have made your theme, time to package it! For the theme to install correctly, you should package only the root files and folders. Compress it into a .zip or .tar.gz file and it's ready to go. If you package is inside a main folder, your theme will not work.

To submit your theme, simply go to the theme site and post a new theme.

If you have any questions about the approval process or about the guidelines, you can ask here or send a PM to someone in the customization team.

Antechinus

Ok, I am asking here. :D

I know traditionally we are supposed to have all HTML validate for theme submissions, but these days we have all sorts of HTML5 grooviness available.

This groovy new stuff doesn't validate with the 2.0.x transitional doctype, but it does actually work, and it does give theme authors and users some handy new things. Just as one obvious example: placeholder text for inputs. It's useful, and it won't break anything, but it's not actually valid HTML if the doctype is transitional.   

So, are the infamous Purple Peeps cool with theme authors deliberating breaking 2.0.x validation to incorporate HTML5 elements that will not bork functionality or layout, and will provide useful enhancements for users?

Diego Andrés

Just change the doctype to html5 in index.template.php
would be !DOCTYPE html I think

SMF Tricks - Free & Premium Responsive Themes for SMF.

Antechinus

Lol. There's a problem with that. A lot of the HTML for 2.0.x doesn't validate with an HTML5 doctype. ;)

Diego Andrés

That's odd because there's already many html5 themes on the theme site.
I remember a few years ago I didn't encounter any validation errors while using html5, not sure

SMF Tricks - Free & Premium Responsive Themes for SMF.

Antechinus

Really? I would have thought there would be heaps. Not so much in the actual custom template provided with a theme, because the theme author can always sort those out for validation, but the rest of the 2.0.x templating contains heaps of stuff that doesn't validate with HTML5.

Mind you it won't actually break anything, but it'll send a validator bonkers if you take a trip around 2.0.x while running an HTML5 doctype in index.template.php. :D

But if the team is only worried about templates actually provided with a theme, that's generally pretty easy to sort.

Gwenwyfar

October 04, 2019, 06:21:30 AM #6 Last Edit: October 04, 2019, 06:34:29 AM by Gwenwyfar
QuoteOk, I am asking here.
I didn't lock this topic for a reason ;)

2.0 has lots of inline styles and <b> and <i> tags which are bad practice, but other than that I can't think of anything that would not validade in HTML5. <input/> and <br/> are still valid for example, although you can use those without the / in HTML5.

But yeah, it's a bit unfair to ask too much for 2.0 themes when the base theme is a mess. At least while I was in the team, 2.1 approvals were a bit stricter because of that (2.1 has had most inline styles done for, for example).

Antechinus

<link rel="stylesheet" type="text/css" href="https://static.simplemachinesweb.com/smf/default/css/index.css?fnl" />
<link rel="stylesheet" type="text/css" href="https://static.simplemachinesweb.com/smf/smsite2/css/smsite.css?rc3.0.6" />
<script type="text/javascript" src="https://static.simplemachinesweb.com/smf/default/scripts/script.js?fnl"></script>
<script type="text/javascript" src="https://static.simplemachinesweb.com/smf/default/scripts/theme.js?fnl"></script>


OK, start of the source code for this particular board. All of those will break validation with an HTML5 doctype. ;)

I went through this recently with TP (see: https://www.simplemachines.org/community/index.php?topic=27642.msg4025203#msg4025203 etc).

Now none of those will break functionality, which to my mind is the important thing but technically they are invalid in HTML5.

Gwenwyfar

Trying to validate those gives warnings, but not errors.

Antechinus

October 04, 2019, 06:57:10 AM #9 Last Edit: October 04, 2019, 07:14:54 AM by Antechinus
Ok, if you're not worried about warnings that's fine. What about charset? Charset is declared all through 2.0.x in a stack of places, and the only charset that will validate in HTML5 is utf-8. So every time a form or whatever pops up with another charset declared, that will conflict with the HTML5 doctype in index.template.php.

Screeny demonstration. :)

ETA: I know what you'll probably say. That everyone who wants to use a theme with an HTML5 doctype can do a complete utf-8 conversion on their forum. They're not going to though. They'll just install the theme and use it. ;)

Gwenwyfar

That's a good point. I think the instance on that has been that mod/theme authors can pick what they are supporting, to a (sane) point. They're already breaking core support to older browsers, for example, or they might require something not all users have. It's not something that has stopped themes getting approved, but I'm not sure how relevant this is being that utf-8 is the way to go, going forward. That's for the current customization team to decide.

SychO

You needn't worry about the charset @Antechinus, nothing you can do about it.
Checkout My Themes:
-

Potato  •  Ackerman  •  SunRise  •  NightBreeze

Antechinus

Ok, another question. :)

Is there any issue with including LGPL icons in an SMF theme? I mean apart from linking to the license and the author's site, which they (KDE/Oxygen) require as part of their conditions.

I'm just wondering if there's any conflict with SMF's BSD license, or if I want the theme itself to be under the ISC license.

(I vaguely recall there being all sorts of kerfuffles when trying to find icon sets compatible with 2.0.x and 2.1 Alpha).

Diego Andrés

Just linking them in the description is enough along with the license I'd assume

SMF Tricks - Free & Premium Responsive Themes for SMF.


Arantor

Correct, that's absolutely the case. You probably should go and include a readme.txt file somewhere outlining it and a copy of the LICENSE file as well (but with an edit to the top to say what it applies to) just to be on the safe side.

Including LGPL works into SMF core is a different battle to including them into a theme you are distributing separately from the core, as if part of the core the assumption would be that it is all BSD, including the parts that aren't.
No good deed goes unpunished
All helpful urges should be circumvented

Antechinus

Sounds reasonable. At the moment it's only a high-definition sprite for the quickbuttons strip. What I was thinking of doing was echoing that sprite to the credits page, along with a blurb thanking them for the icons and linking to their site and to the license. Might possibly throw a discrete credits link into the footer too. That should keep everyone happy.

Arantor

Credits page would be neat, credits link into the footer is above and beyond.

Unfortunately 2.0's credits page has no hook, which would make this sort of thing trivial to do.
No good deed goes unpunished
All helpful urges should be circumvented

Antechinus

Well the credits page has no actual way of getting to it if you don't have admin access. You can throw a direct url at your address bar if you happen to know how to do that, but most people won't know. So one more word/link, in the footer is not all that bonkers. Wouldn't bother me.

I have already edited Admin.template.php anyway, so throwing a bit more on the end doesn't bother me in this case. I suppose you could throw a hook in via a mod, if anyone wants to do that.

Arantor

QuoteWell the credits page has no actual way of getting to it if you don't have admin access.

Except for action=credits which is also linked in the footer and is visible to all users - the SMF 2.0.15 link in the footer is the credits link, SMF (C) 201x is a link to the SMF licence, and Simple Machines is a link here. Has been that way for years.

2.1 has multiple ways of doing this, it has both a hook and package-info.xml can directly do things (not sure about themes, but definitely can for mods)
No good deed goes unpunished
All helpful urges should be circumvented

Antechinus

Ok, in that case I won't bother with a credits link. :D

Skhilled

Hi, I'd like to take over Crip's themes from the Crip Zone. I am the Admin/Coder there and have been since Maxx's passing. I was also a long time beta tester for TinyPortal and a friend of Jeff's. Maxx's site as well as the Crip Zone are hosted on my server.

There's about 72 themes there and I'd like to update them all to SMF 2.1 after it is released. So far, I've only updated a few themes for RC1 and RC2. I have no plans to update a lot of them until after 2.1 becomes official.

I've noticed and have been informed by others that the current themes for 2.0.x need updating for the session time out issue. So, I'm sure the ones here will need to be updated as well.

Please keep in mind...I'm no coding guru but have learned a LOT since taking over the site. However, I'll be glad to help users of those themes any way I can.

Illori

this is something the team would have to discuss. since the owner is no longer able to approve the transfer it is a bit complicated to handle.

Arantor

For whatever it's worth, I'd support this.

Also 2.0.16 should fix the session issue across the board.
No good deed goes unpunished
All helpful urges should be circumvented

Skhilled

Quote from: Illori on October 28, 2019, 05:37:42 AM
this is something the team would have to discuss. since the owner is no longer able to approve the transfer it is a bit complicated to handle.

I understand, thanks.

Quote from: Arantor on October 28, 2019, 05:57:19 AM
For whatever it's worth, I'd support this.

Also 2.0.16 should fix the session issue across the board.

Thanks, and yes, I've heard about that but have no idea when it will be available and a few people are still having problems now. However, they can still come to the CZ site as I'll be updating the 2.0 themes that they need for now.

GigaWatt

Quote from: Skhilled on October 28, 2019, 06:07:37 AM
Thanks, and yes, I've heard about that but have no idea when it will be available and a few people are still having problems now. However, they can still come to the CZ site as I'll be updating the 2.0 themes that they need for now.

I've fixed the login issue for one of his themes ;).

https://www.simplemachines.org/community/index.php?msg=3963205

And also added a search button in the Search bar in the upper right corner ;).

https://www.simplemachines.org/community/index.php?msg=3965982
"This is really a generic concept about human thinking - when faced with large tasks we're naturally inclined to try to break them down into a bunch of smaller tasks that together make up the whole."

"A 500 error loosely translates to the webserver saying, "WTF?"..."

Skhilled

Yes! I did see that and meant to say something about that but was so busy yesterday that I forgot. Did you updated the theme in the downloads here to include the search bar and the session issue?

The theme I updated came from the CZ site's files and was never even put in the downloads there! However, that one does already have the search bar on it. So, Jeff may have added it himself but just never added it to the downloads.

I haven't downloaded the one from here nor any of the others on this site. There's about 72 themes in the /Themes folder on his site. However, when I moved the site to my server I started noticing a TON of other themes in various folder across the site! Some are even with folders of other themes and do several layers deep...multiple themes within themes! It may take me forever to sort those all out, if I ever get around to it. Maxx estimated that he did about 500 or so themes but I've never seen them all. But I think I've found a lot of them and they may never even been finished or released.

Illori

a lot of them were removed but Crip had submitted 294 themes on the theme site. seems many are for SMF 1.1.*.

Skhilled

October 29, 2019, 09:47:52 AM #28 Last Edit: October 29, 2019, 10:11:23 AM by Skhilled
Ah! I totally forgot about SMF 1.1. themes. LOL Anyhow, I'm not even going to attempt to sort through all of the others. The 72+ ones I've got will keep me busy forever. LOL

Thanks to both of you.
EDIT: If I am not approved, will I be able to post new and upcoming themes in the Theme Site Themes board and the Theme Previews board?

GigaWatt

Quote from: Skhilled on October 29, 2019, 09:24:19 AM
Yes! I did see that and meant to say something about that but was so busy yesterday that I forgot. Did you updated the theme in the downloads here to include the search bar and the session issue?

No, I'm not allowed to do that since it's not my theme ;).

Quote from: Skhilled on October 29, 2019, 09:24:19 AM
The theme I updated came from the CZ site's files and was never even put in the downloads there! However, that one does already have the search bar on it. So, Jeff may have added it himself but just never added it to the downloads.

That may be possible ;).
"This is really a generic concept about human thinking - when faced with large tasks we're naturally inclined to try to break them down into a bunch of smaller tasks that together make up the whole."

"A 500 error loosely translates to the webserver saying, "WTF?"..."

Antechinus

Got a question about building in support for some mods.

This new thing I've come up with is all groovily responsive and all that, but some mods are going to be a bit of a nuisance to install due to the markup changes I've had to make to rationalise things.

Back in the 1.1.x days it was not uncommon for custom themes to include built-in support for a selected range of mods. The relevant functions where just coded in to the relevant templates, with a condition set in the PHP so the function wasn't called unless the support was enabled in admin (with the relevant setting obviously being added to Settings.template.php).

This is all pretty straightforward stuff, and allows beginners to install the mods in question on a custom theme without having to deal with manual edits. The only caveat is they have to make sure they don't enable support for the mod until it is actually installed on the default theme, and have to make sure they disable support for the mod before they uninstall it, but apart from that it will all work.

So, if I wanted to do a bit of this trickery how does it affect theme approval?

SychO

I added mod support in my own themes as well, however I did not use a user editable setting, because most of the time users can hardly even find their way to the current theme settings (even though in my themes I added a button in the header to directly go to that page), but most importantly if the user enables support for a mod using that setting and the mod is actually not installed, that can lead to him getting locked out of the forum because of an internal server error where the theme calls for a mod function that actually doesn't exist in the code base.

If you want to add support for other mods, I would highly suggest you try what I did, for example vbgamer45's Like posts mod has a "LikePosts" php class, so what I did was test if the class exists or not to tell if the mod is installed using the class_exists() php function, the same can be done to mods adding new functions, you can use function_exists() but only if you're certain that if the mod was installed that function/class would be accessible from the page you're testing it from. Also when using this method you should also make sure whatever function/class name you're using to test isn't used by some other mod.

It may be a little complicated but at least it's better than having a setting that may mess the forum up if enabled.

This is just my opinion, I'm not saying that it is not allowed as I haven't had the chance to hear the other's opinions about it.
Checkout My Themes:
-

Potato  •  Ackerman  •  SunRise  •  NightBreeze

Antechinus

Those sound like sensible precautions. :)

This basically requires nicking some mod code to add to the template. Do I have to get permission from the mod author? Or is it just assumed they won't mind people supporting their mod?

SychO

Most mods have open licenses, I'd say just add a comment before the piece of code for the mod support that mentions the mod's name and author, and give the mod's license a read in case it doesn't allow it.
Checkout My Themes:
-

Potato  •  Ackerman  •  SunRise  •  NightBreeze

Antechinus

I'm currently thinking of the Ad Management mod, just because quite a few people seem to want it. That doesn't actually come with any license as such. I'll ask in the mod's support thread. Seems the easiest way of doing it.

vbgamer45

It's fine with me to ad support for any of my mods in your own themes. I used do it myself in old SMF 1.0.x themes with buttons.
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Antechinus

Ok cool. As it turns out I thought I had enough on my plate at the moment, so decided to skip it for now.
I can always write a patch for the theme later, once it's all sorted in default form, if anyone has trouble installing a particular mod.

addlife

Quote from: SychO on February 19, 2020, 04:52:06 PM
I added mod support in my own themes as well, however I did not use a user editable setting, because most of the time users can hardly even find their way to the current theme settings (even though in my themes I added a button in the header to directly go to that page), but most importantly if the user enables support for a mod using that setting and the mod is actually not installed, that can lead to him getting locked out of the forum because of an internal server error where the theme calls for a mod function that actually doesn't exist in the code base.

If you want to add support for other mods, I would highly suggest you try what I did, for example vbgamer45's Like posts mod has a "LikePosts" php class, so what I did was test if the class exists or not to tell if the mod is installed using the class_exists() php function, the same can be done to mods adding new functions, you can use function_exists() but only if you're certain that if the mod was installed that function/class would be accessible from the page you're testing it from. Also when using this method you should also make sure whatever function/class name you're using to test isn't used by some other mod.

It may be a little complicated but at least it's better than having a setting that may mess the forum up if enabled.

This is just my opinion, I'm not saying that it is not allowed as I haven't had the chance to hear the other's opinions about it.
Correct me if I'm understanding wrong. The themes that you're referring to will work with the like posts mod without manual edits even if it's installed after the like posts mod?

I saw somewhere in the code of Sunrise that it mentions vbgamers mod in a comment. Is that the part of code that you did whatever you posted above?

SychO

Quote from: addlife on May 03, 2020, 06:05:37 PM
Correct me if I'm understanding wrong. The themes that you're referring to will work with the like posts mod without manual edits even if it's installed after the like posts mod?

I saw somewhere in the code of Sunrise that it mentions vbgamers mod in a comment. Is that the part of code that you did whatever you posted above?

Yes & Yes, that's the purpose of adding mod support.
Checkout My Themes:
-

Potato  •  Ackerman  •  SunRise  •  NightBreeze

Advertisement: