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

What tools do people use for building themes / templates?


Go to End


28 Posts   47212 Views

Avatar
Sam

Administrator, 690 Posts

13 August 2007 at 10:14am

Hi everyone,

I was wondering what tools people use, or would like to use, for building their SilverStripe .SS and .CSS files, in other words, the skin of their application?

How well suited to editing .SS files are these tools?
What sort of problems do you run into?
Can you make any suggestions for ways to improve the editing process?

The goal for the .SS templates was that front-end web designers would be able to develop them; I want to make sure that we haven't drifted from this goal.

Avatar
Nathan Cox

Community Member, 99 Posts

14 August 2007 at 11:07am

Edited: 14/08/2007 12:28pm

I use notepad2 for my editing needs...think notepad with syntax highlighting and line numbers and other little handy bits.

It's nothing fancy, so .ss files aren't really any different from .htm. It can also do ASP highlighting, which colours the <% control %> blocks nicely.

Avatar
SLJ

Community Member, 23 Posts

15 August 2007 at 9:01am

I do my coding on a windows machine. My primary code editor is Dreamweaver. I have customized it so that it recognizes .SS files as HTML and gives me all the functionality I have with standard HTML files plus it highlights <% control %> blocks. If you are looking for the designer perspective, most of the ones I have known use Dreamweaver or something similar that lets you see the effects of your code/css changes in the editor itself. Customizing Dreamweaver to recongnize .SS files is pretty easy.

I usually use Dreamweaver for initial design and major updates because it saves me a lot of time. When I do minor updates, I use PSPad or Notepad+. As Nathancox said, the files aren't much different than HTML files so any editor a person is comfortable with should work pretty well.

Avatar
Nathan Cox

Community Member, 99 Posts

15 August 2007 at 9:35am

On a slightly related note, one thing I'm not liking about the SS templating is the empty lines it leaves.

If your .ss file has something like this:

[html]
<ul id='main_menu'>
<% control Menu(1) %>
<li class="$LinkingMode $FirstLast">
<% if LinkingMode = current %>
<span>$MenuTitle</span>
<% else %>
<a href="$Link">$MenuTitle</a>
<% end_if %>
</li>
<% end_control %>
</ul>
[/html]

your source code ends up looking like this:

[html]
<ul id='main_menu'>

<li class="link first">

<a href="/home/">Home</a>

</li>
<li class="current last">

<span>Contact</span>

</li>

</ul>
[/html]

You can squash the template code up a bit to get rid of the blank lines, but you still need to choose between nice template code and nice source code.

I don't know anything about the parser, but would it be possible to have it remove any line that had nothing but <% blah %> and whitespace on it?

Avatar
Willr

Forum Moderator, 5523 Posts

15 August 2007 at 9:31pm

I second nathans thoughts on the the whitespace issue

Avatar
BeefStake

23 Posts

16 August 2007 at 7:15pm

I'm using Dreamweaver now... little bit better than gedit....lol
I find Dreamweaver sufficient now that I've learned some more html and I've stopped getting frustrated at why something does something I didn't think it should have.
After sitting down for several days and reading lots of html books and tutorials I've decided that its not actually that hard, though those <div> tags get annoying...

Avatar
Tatey

Community Member, 18 Posts

24 August 2007 at 7:15pm

Edited: 24/08/2007 7:17pm

Primarily, I develop on OS X using a GPL editor called Smultron. While it doesn't recognise ".SS" extension by default, it has no problem with syntax highlighting. It's relatively easy to configure the editor to recognise the .SS extension.

I also share the same concerns with Nathan and Will in regards to the white spaces. I always strive to produce clean markup, especially considering that anybody can easily view the source of a website. It's a bit embarrassing when it's not as neat as it could be ;)

Avatar
bmc38119

Community Member, 45 Posts

6 March 2008 at 5:29pm

anyone know how to make the html code coloring work on .ss files in dreamweaver? just started heavily looking into this CMS and have been very impressed so far.

Go to Top