Sticky Post for responsive Templates?

Skinning and designing Serendipity (CSS, HTML, Smarty)
User avatar
onli
Regular
Posts: 2254
Joined: Tue Sep 09, 2008 10:04 pm
Contact:

Re: Sticky Post for responsive Templates?

Post by onli » Tue Apr 19, 2016 5:00 pm

Timbalu wrote:Was this ever really tested?
I tested it in my testblog and it worked there. The component I could not test there was setting the recommended-property of spartacus themes.

Don't forget that 2.1 is alpha. It is allowed to break and new features don't have to be perfect.

*Edit:* But that is still working for me in my devblog, so I think you had a local mismatch.
Timbalu wrote:Don't get me wrong, I personally would recommend these themes too, compared to most of these old xhtml ones. But I would recommend this a a personal, subjective action to someone or more generally here in the forum. Hm..
So why is that? If we can recommend them in the forum we can also recommend them in the backend. There is nothing inherently good about a "neutral" alphabetical list.
Timbalu wrote:These sort of changes need a positive willingness from us all to carry it into the future.
It would, if we had many new themes. We do not and never had since I'm here. Without new themes the work related to this is zero, with the few themes I expect it will be very low. Nothing we can't handle.

User avatar
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Sticky Post for responsive Templates?

Post by Timbalu » Wed Apr 20, 2016 12:54 pm

onli wrote:*Edit:* But that is still working for me in my devblog, so I think you had a local mismatch.
I don't think so ... since I only needed to rewrite some of your commit changes.
Which backend do you use?
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian

User avatar
onli
Regular
Posts: 2254
Joined: Tue Sep 09, 2008 10:04 pm
Contact:

Re: Sticky Post for responsive Templates?

Post by onli » Wed Apr 20, 2016 1:49 pm

There is only one currently, isn't there? Normal 2k11 admin backend.

The commit (https://github.com/s9y/Serendipity/comm ... a2261b8788) seems correct to me, I don't think I forgot to commit something. What did you have to change?

YL, is it working properly for you? Themes are in the recommended section and only there?

User avatar
yellowled
Regular
Posts: 7078
Joined: Fri Jan 13, 2006 12:46 pm
Location: Eutin, Germany
Contact:

Re: Sticky Post for responsive Templates?

Post by yellowled » Wed Apr 20, 2016 3:15 pm

onli wrote:YL, is it working properly for you? Themes are in the recommended section and only there?
Yes. This is a git checkout currently sitting at 59e569e5, which is quite a few commits after the changes to spartacus. I'm using netmirror.org for both Spartacus mirrors. 2k11, next, bartleby, Clean Blog and photo are listed as “Recommended” and do not appear a second time in the list below.

YL
amazon Wishlist - Serendipity-Podcast (German only, sorry)

User avatar
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Sticky Post for responsive Templates?

Post by Timbalu » Wed Apr 20, 2016 3:27 pm

Timbalu wrote:I didn't get the infos for my backend theme any more (which hit me visually at first) and (after fixing this) had the resting templates array still carry the recommended themes also.
This was not the one in question though. What about your backend theme box. Does it show up?
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian

User avatar
onli
Regular
Posts: 2254
Joined: Tue Sep 09, 2008 10:04 pm
Contact:

Re: Sticky Post for responsive Templates?

Post by onli » Wed Apr 20, 2016 3:31 pm

Thanks! :)

Ian, still, feel invited to show me what you had to change. It still could be an issue with PHP versions or other unforeseen discrepancies. But I regard it as working so far.
This was not the one in question though. What about your backend theme box. Does it show up?
Yes, certainly. At the right of the chosen frontend theme, like before:

Image

User avatar
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Sticky Post for responsive Templates?

Post by Timbalu » Wed Apr 20, 2016 3:44 pm

Strange!
Mine was empty because of this https://github.com/s9y/Serendipity/comm ... aedb82R229
I removed that if { unset } part to get the array item back for the backend theme, but had to later on exclude the recommended from the templates array because of this.

Code: Select all

unset($data['templates'][$data['cur_template']]);
foreach ($data['recommended_templates'] AS $recommended_templates_name => $recommended_templates_value) {
    unset($data['templates'][$recommended_templates_name]);
}
unset($data['recommended_templates'][$data['cur_template']]);
Maybe this was, since I have a different frontend theme set.
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian

User avatar
onli
Regular
Posts: 2254
Joined: Tue Sep 09, 2008 10:04 pm
Contact:

Re: Sticky Post for responsive Templates?

Post by onli » Wed Apr 20, 2016 3:55 pm

Hm, that's actually really possible that it is a bug. Your frontend theme is something else than 2k11? Ah. I just saw you wrote that. I think I have a better patch for that (don't unset if it is the current theme or the current backend theme). Thanks for reporting it!

User avatar
onli
Regular
Posts: 2254
Joined: Tue Sep 09, 2008 10:04 pm
Contact:

Re: Sticky Post for responsive Templates?

Post by onli » Wed Apr 20, 2016 8:50 pm


User avatar
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Sticky Post for responsive Templates?

Post by Timbalu » Thu Apr 21, 2016 9:16 am

Four+ if checks vs a quick foreach - is that an easier approach? This seems more complicated to me than in need. (Didn't test this yet though.)
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian

User avatar
onli
Regular
Posts: 2254
Joined: Tue Sep 09, 2008 10:04 pm
Contact:

Re: Sticky Post for responsive Templates?

Post by onli » Thu Apr 21, 2016 11:49 am

Timbalu wrote:Four+ if checks vs a quick foreach - is that an easier approach?
Your approach is going through all recommended templates and removing them from the normal temple list. I'm directly removing them when they get marked as recommended, and then remove only the one that can get skipped. Saves iterating through the list again, even if the list is small so far.

Yeah, I think that is the better approach.

User avatar
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Sticky Post for responsive Templates?

Post by Timbalu » Fri Apr 29, 2016 9:12 am

BTW

I think we should copy (not move!) all core themes (except 'default' and the special and PHP themes) to Spartacus (additional_themes).

Imagine you are a new user, you get easily directed to the page http://spartacus.s9y.org/index.php?mode=template_all, which holds all themes. At least it says it does.
Which it certainly does not, since it will not show the more or less recommended themes delivered by and living in core (releases only).

Now: A new user will view and taste all these themes, old or middleaged, and even some newer ones and then decides in there, in these first seconds, if (s)he likes the presentation, the look and feel of Serendipity. Also the one is able to switch themes by using the demo link for each theme.

I think we really need to extend this with all themes! (And add some missing preview images.)

(This will also give us the option to make themes being upgradable by Spartacus in future.)
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian

User avatar
onli
Regular
Posts: 2254
Joined: Tue Sep 09, 2008 10:04 pm
Contact:

Re: Sticky Post for responsive Templates?

Post by onli » Fri Apr 29, 2016 10:01 am

That's a good point!

I think we should combine it with giving spartacus the capability to upgrade themes.

User avatar
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Sticky Post for responsive Templates?

Post by Timbalu » Fri Apr 29, 2016 2:42 pm

I think this is totally independent, cause else you would then have to wait for a 2.x release.
The Copy is a thing of minutes and then available for all.
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian

User avatar
yellowled
Regular
Posts: 7078
Joined: Fri Jan 13, 2006 12:46 pm
Location: Eutin, Germany
Contact:

Re: Sticky Post for responsive Templates?

Post by yellowled » Fri Apr 29, 2016 4:34 pm

i agree that at least having the core themes listed on Spartacus is a good idea, but I don't know if it could have any side effects to actually have them on Spartacus. Then again, a neat side effect would be that people could use the theme preview in the official s9y blog for core themes as well. (I think it makes a huge difference to be able to see and test a theme in a live environment.)

I assume at this point only Garvin knows about the emerge script for Spartacus (at least I haven't gotten around to checking it out yet) and what's best here, so, erm, Garvin …?

YL
amazon Wishlist - Serendipity-Podcast (German only, sorry)

Post Reply