• Welcome to Simple Machines Community Forum. Please login or sign up.
December 06, 2021, 07:22:56 AM

News:

SMF 2.1 RC4 has been released! Try it out and help us test! :) Read more.


SunRise

Started by SychO, September 22, 2018, 10:12:35 PM

Previous topic - Next topic

shadav

Quote from: PFigo on September 25, 2021, 04:03:27 PM
Quote from: SychO on September 17, 2021, 07:51:53 PM
Quote- in footer I need to edit theme author details

You can remove it, not edit it.
I appreciate your comments but it would be good if you read the previous posts first before making your comments.
I would suggest pming sycho for help then

as, again, that is something that you two will need to discuss via pms, not publicly if that is something that Sycho agreed to
no one else will help you with removing the copyright as that goes against the theme license
QuoteBut you may not remove the author's copyrights; either version 2 of the License, or (at your option) any later version.

Shambles

SychO - neat work on this theme.

Decided to grab it a couple of days ago and released it as an optional theme for my members.

Unfortunately, I believe a portion of the "theme settings" section is missing - namely, the bit that specifies which membergroups are allowed to use the theme ("theme permissions").

The result of not having that section is a blank value is made in smf_themes (variable "viewgroups") whenever the settings page is changed/saved.

Overall effect is that function PickTheme in Themes.php gets no data from the "viewgroups" value, thereby denying anyone other than Admin the use of SunRise.

I can manually update the "viewgroups" with a list of membergroup numbers and that fixes it, until the SunRise settings page is used again.

2.0.18

Shambles

.. and here is the fix.

Themes.template.php
Code (Find) Select
    // Do we allow theme variants?

Code ("Add Before") Select
    echo '
            <div class="cat_bar">
                <h3 class="catbg"><img src="', $settings['images_url'], '/icons/config_sm.gif" alt="" class="icon" /> ', $txt['alundra_theme_permissions_title'], '</h3>
            </div>
            <div class="windowbg2">
                <span class="topslice"><span></span></span>
                <div id="theme_permission_settings">';

    if (empty($context['groups']))
        echo $txt['alundra_theme_permissions_guest'];
    else
    {
        echo '
                    <ul class="reset">';

        foreach ($context['groups'] as $group)
        {
            echo '
                        <li><input type="checkbox" name="groups[]" value="', $group['id'], '" id="groups_', $group['id'], '"', $group['checked'] ? ' checked="checked"' : '', ' /> <span', $group['is_post_group'] ? ' style="border-bottom: 1px dotted;" title="' . $txt['mboards_groups_post_group'] . '"' : '', '><label for="groups_', $group['id'], '">', $group['name'], '</label></span></li>';
        }

        echo '
                        <li><input type="checkbox" onclick="invertAll(this, this.form, \'groups[]\');" /> <em>', $txt['check_all'], '</em></li>
                    </ul>
                    <br class="clear" />';
    }

    echo '
                </div>
                <span class="botslice"><span></span></span>
            </div>';



SychO

Quote from: Shambles on October 20, 2021, 09:10:28 AMUnfortunately, I believe a portion of the "theme settings" section is missing - namely, the bit that specifies which membergroups are allowed to use the theme ("theme permissions").

Yea, it's a mod that conflicts with the theme: https://www.simplemachines.org/community/index.php?topic=264667.0, other users using the mod can apply the fix you posted which is cool, though it's not code that can be added to the theme by default.
Checkout My Themes:
-

Potato  •  Ackerman  •  SunRise  •  NightBreeze

Shambles

Well, how embarrassing  :-[

I thought that "theme permissions" was standard SMF issue and never gave a second thought to it having been added by me as a mod all those years ago.

I do apologise.

SychO

Tough to keep track with all them mods ey  :P

All good though
Checkout My Themes:
-

Potato  •  Ackerman  •  SunRise  •  NightBreeze

Advertisement: