Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

Archive /

Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo

Template Variables?


Go to End


8 Posts   5059 Views

Avatar
olafmol

Community Member, 10 Posts

5 September 2008 at 9:36am

Hello,

coming from MODx, one of the most powerfull items in MODx are TemplateVariables (TV's). Basically you can add properties/fields of different types (ie texfield, WYSIWYG field, dropdown, checkbox, etc.) to a template from within the manager. Now all pages that use this template show the added TV's for editing. This is a very quick way for non-programmers to add f.e. extra content to a page.

Is something like this also available in Silverstripe?

cheers, Olaf

Avatar
motoservo

Community Member, 27 Posts

5 September 2008 at 10:11am

Edited: 05/09/2008 10:16am

I think what you are asking about is a User Defined Form page. It is similar to what you describe, allowing a content admin to add basic form controls to a page. It's based around the usual Contact Us type of form that you find on most sites. It shows the admin a table of submissions as well as an email notification.

This is a little different than what you describe because it's done on a per page basis and not on a template.

Check out the Forms Tutorial and see if this is what you need.

Avatar
olafmol

Community Member, 10 Posts

5 September 2008 at 10:19am

thanks for replying :)
No, that's not what i am looking for. It's purely to be able to customise/add additional datafields in the manager to certain templates, and to enable non-programmers to do this.
Basically it's what is described in tutorial 2 for creating new page types, but in a very user-friendly way right inside the CMS manager.

Olaf

Avatar
Willr

Forum Moderator, 5523 Posts

5 September 2008 at 4:20pm

SilverStripe takes a much more stricter approach then other CMS's. It tries to really separate editing the site to developing the site. So things like adding fields, changing themes, editing themes are all not available in the CMS. Doesn't mean you can't develop a way to do it but it is a design decision of the core team to keep this sort of stuff out of it

Avatar
olafmol

Community Member, 10 Posts

5 September 2008 at 6:33pm

i understand, cheers for explaining :)

Olaf

Avatar
motoservo

Community Member, 27 Posts

6 September 2008 at 9:55am

Edited: 06/09/2008 9:59am

Now I understand what you want. You aren't going to find that in Silverstripe at the moment, and probably not ever. From my understanding, the Silverstripe approach is a strong separation between admin tasks and development tasks. Personally, I like this approach as I am a developer and would rather code structural changes and use the CMS just for basic content management. I used to use Drupal and it has the CCK module that lets an admin add new content types like you want you want. Overall though, I felt that the Drupal CMS was bloated, ugly, and unintuitive. I appreciate that the Silverstripe CMS is lean & mean.

But that's just my $.02.

EDIT: Shazbat. Was replying to this page that was open in my browser since yesterday. Didn't see that the question was answered already.

Avatar
olafmol

Community Member, 10 Posts

6 September 2008 at 9:26pm

cheers for taking the time to answer! :)
We are also looking at Drupal for our more demanding open-source implementations where MODx doesn't cut it (ie workflow, versioning, build-in multilanguage and multisite) but the admin-interface and conventions of Drupal are simply not friendly enough for our customers who have to work with the system. One of the big powers of MODx (and i think also Silverstripe) is that end-users are not scared by it's interface and seem to understand it right away. This is very important, even more important than all the functionality you can think off. We are a company very much focused on useability and we cannot sell a system that people don't understand after a day of coaching.

Olaf

Avatar
Sigurd

Forum Moderator, 628 Posts

10 September 2008 at 11:57pm

Olaf, good to see you here :)

There's a correct message here that we prefer to define the data model in code so that you can embrace logic and elegance in defining it all. We might in time find a way that permits some of what you talk about in a way that doesn't feel too much like a compromise, so do share if you feel an existing software product out there provides inspiration as such. For us it hasn't been a squeaky wheel, but I'm sure it will need resolving in time.

However, there have been efforts along these lines in the past;
http://www.youtube.com/watch?v=iwwBle1TK2U
http://xebidy.com/tag/silver-stripe/