Content Styles... more info.

3 posts / 0 new
Last post
#1 Fri, 06/22/2007 - 21:42
CharlesMason

Content Styles... more info.

Hi everyone,

Just looking for more information on creating "Content Styles". Looked in the forum and docs but no luck. Any documentation would be appreciated.

Best regards, Charles

Sat, 06/23/2007 - 20:12
CharlesMason

Ok, I found where the style are located on the server "/usr/libexec/webmin/virtual-server/styles" not will look into how to create. Will post more information once I am done...

Regards,
Charles

Sun, 06/07/2009 - 07:03
Joe
Joe's picture

Hey Charles,

Good question. It's actually quite easy to add new styles, and we plan to add quite a few more in the future. If the styles you choose to add are under an open license, you can send them over, and we'll add them to the official distribution.

We also plan to add the ability for designers to sell style bundles right here on Virtualmin.com, so if you're feeling artistic, make a few nice styles, and you could make a few bucks.

Anyway, here's how you do it:

Create sub-directories under /etc/webmin/virtual-server/styles , each of which contains the template HTML and image files for your own style. The only other special file that needs to go in a style directory is style.info , which should contain a line like:

desc=My Custom Style

You can see the styles supplied with Virtualmin under
/usr/libexec/webmin/virtual-server/styles, which are formatted in the same type
of directories.

The other bit is you'll want to create a thumbnail image of the style. The format of this is PNG at 500x375 pixels. Call this file thumb.png.

Within the .html files you can use variables ${CONTENT}, ${OWNER}, ${DOM} to tell Virtualmin where to put the user data (which can all be edited later in the WYSIWYG editor).

In celebration of having a Wiki, and as a demonstration of good faith about how we would use the wiki, I have dumped the into a new page in the docs. Hooray for wikis and constant documentation refinement! Here's the link (already more detailed than what I've written here):

http://www.virtualmin.com/documentation/id,content_styles/

Feel free to add anything you learn while building your styles.

--

Check out the forum guidelines!

Topic locked