Support Forum

Templating – Initial Thoughts

YS Yellow Swordfish
Yellow Swordfish
Member

This is a very rough and quick mockup of the sort of thing I had in mind for templating. I am sure we all have different ideas but I thought it was maybe time to start to get a little more specific. So this is how I see it.

I see four panels – Group. forum. topic and the outer wrapper of those three, This one is the outer wrapper (part of it anyway).

The idea here is that along the bottom are objects representing each and every component appropriate to that view. You start at the top by opening a new ‘block’. Then you drag and drop the components where you want them into the block

Once a component is inside a block, clicking on it will bring up a properties list which will contain all relevant properties for that component. Like CSS, (left, right, top, middle, bottom. If appropriate – colour, width, depth) and/or text label, icon etc. – you get the idea.

Each block also has it’s properties – CSS class etc.

Some properties can be changed. Some can not.

Now this ties in with the other thing I would like to do as mentioned in an earlier thread. One of the things they can change should be the CSS itself.

We save the template data as, basically, a list of sequenced display tasks. We regenerate the CSS stylesheet for the ‘skin’ based upon what they have specified while saving all of this is the database as well.

Thoughts?

5 Answers

New Answer

MP Mr Papa
Mr Papa
Member

do I understand this right?  you are thinking about a UI with drag and drop for structuring the forum appearance? 

hmmm…  not quite what I was thinking, but intriguing – very intriguing…  guess I was thinking small and basically doing it like WP does themes…  a bunch of functions (template tags) that you call to get display elements and arrange them how you want (by calling when you want and with css) like you would when creating a wp theme…

One question I guess I would have is the list of appropriate components.  seems like it should be almost anything and not be bound by how we think today.

also should think a bit more about how one would extend this…  That is, maybe some new blocks/components that are simply php blocks so one could insert a template tag or other code.  sort of a limitless replacement for hooks.  not sure at quick thought how one would ‘pass’ things to these blocks, but…

think we would need a way to export and import setups ala themes so folks could share set ups…

a bit confused by the templates… why four?  outer, group, forum and topic?  what about other page views today?  like profile, pm, members, etc etc…  I see them in the bottom components, but does that mean they are really just links to those?

also, what about thinks like the pagelinks, rss, and all the other display element options we have?  I know the list wasnt entended to be all encompassing at this point, but are you thinking all those options ‘go away’ from the admin panel and get incorporated here?  say, drag the element and drop in if you want?  and then use the properties of the element for things like sort order?

very intriguing idea and more ambitious than what I was thinking!  Think its worth continuing the thought process.

Since you have jumped in here, guess that means I get the admin stuff, eh? Wink helping here of course when needed!

YS Yellow Swordfish
Yellow Swordfish
Member

Mr Papa said:

do I understand this right?  you are thinking about a UI with drag and drop for structuring the forum appearance?

That’s right. At the moment just a thought. I realise it is very adventurous and we would need to prove it before really commiting but hey – radical…

hmmm…  not quite what I was thinking, but intriguing – very intriguing…  guess I was thinking small and basically doing it like WP does themes…  a bunch of functions (template tags) that you call to get display elements and arrange them how you want (by calling when you want and with css) like you would when creating a wp theme…

And that was my starting point as well but your average punter doesn’t know his loop from his tag template – the majority do not make their own themes and do not want to. Give them a tool like this and they can play away safely.

One question I guess I would have is the list of appropriate components.  seems like it should be almost anything and not be bound by how we think today.

I prefer to think that it would have to include everything we supply as a visible component – plus there would have to be a way for adding them through SPF plugins.

also should think a bit more about how one would extend this…  That is, maybe some new blocks/components that are simply php blocks so one could insert a template tag or other code.  sort of a limitless replacement for hooks.  not sure at quick thought how one would ‘pass’ things to these blocks, but…

Absolutely right. And did you nit say yourself that we pass an array? One parameter which the custom code shoud take care of.

think we would need a way to export and import setups ala themes so folks could share set ups…

Agreed. And we supply a few sample sets ike we do now with skins.

a bit confused by the templates… why four?  outer, group, forum and topic?  what about other page views today?  like profile, pm, members, etc etc…  I see them in the bottom components, but does that mean they are really just links to those?

You are right – there are more than four. I was just concentrating on the core forum views.

also, what about thinks like the pagelinks, rss, and all the other display element options we have?  I know the list wasnt entended to be all encompassing at this point, but are you thinking all those options ‘go away’ from the admin panel and get incorporated here?  say, drag the element and drop in if you want?  and then use the properties of the element for things like sort order?

Correct. Neat eh?

very intriguing idea and more ambitious than what I was thinking!  Think its worth continuing the thought process.

Well it IS ambitious and, as I said above, at the moment just a thought but just think how flexible this sort of approach could be…

Since you have jumped in here, guess that means I get the admin stuff, eh? Wink helping here of course when needed!

I don’t think you thought that statement through… This IS the Admin Stuff! This is the back end. So you want it? All yours if you do…

MP Mr Papa
Mr Papa
Member

lololololol…  guess the UI is really in the admin (new main panel – so segmented), but the actual display stuff is in the front end…  No need to assign tasks yet! Cool shaking a bit at the amount of jquery/js to be written for it! Surprised might be way to tag team it, with one guy in lead and the other carrying
out tasks…  wonder if we can use that jquery drag and drop stuff I put in for the avatar priorities…

yes, very ambitious, but ya know, if we can pull it off, it would be huge!!!!!  and ya know, we need to try something exotic and different and push ourselves with this release…  lately its been a lot about support and bug fixes…  time for some new ground breaking stuff and have some fun with it!  very good point about average wp user not knowing how to theme – look at number that pay big bucks for ready made theme!!!

We are actually getting pretty stable right now with 4.2 – too bad a major wp change is coming…. hopefully 4.3 remains stable and we can concentrate on this…  I have no problem with it being a long development as long as its stuff that gets our juices flowing and learning is occurring…

Lets keep the create thought process going… like where this is heading and even a bit excited (was about templating in general, but this- wow!)…

YS Yellow Swordfish
Yellow Swordfish
Member

I think this can all be done with standard jQuery UI library plugins – like the sort and drag and drop we use on the Tinymce toolbar and avatar panels. Actually you know, I am not convinced there is that much coding once the shell and basic routines are in place. I would envisage each ‘component’ having a database record of what properties are needed – i.e., skeleton/configuration records so the actual coding should be fairly lightweight. Well, maybe I am kidding myself here!

What I would suggest is that, post 4.3 realease, we define a sandbox system in SVN purely for testing out ideas and new things. That way we can both keep in sync and use it for anything that needs passing back and forth.

One thing on the above. We briefly mentioned that many of these components can replace the option settings and I think that is the case. There will be many that can not of course, and will still be subject to checking at display time. Such as tags for example, that can be enabled/disabled at forum level. But this very ‘check’ could also be a property.

MP Mr Papa
Mr Papa
Member

a sandbox is no problem… just a branch like I did with 4.3…  pretty easy to keep in synch…