-
Notifications
You must be signed in to change notification settings - Fork 119
Extensions
This manual relates to the correct structure for Subrion templates, plugins, packages.
Extension name should be lowercase alphanumeric. You can also use underscore when needed, but it's recommended to avoid it. Please note, folder name MUST BE similar to the extension name in install.xml file.
Description tag in install.xml should be short and descriptive. It should not end with . (dot) so please carefully follow the instructions. If you want to add a detailed description of your extension you can put it in description.html file and format using HTML.
Extensions have an icon that represents package, plugin, or template. This icon is displayed on our websites and in Dashboard so it should be pretty. We highly recommend to avoid using transparent images, as they might look ugly for some pages.
Icon should be placed in FOLDER_NAME/docs/img/ folder and it should have 'icon.png' name (PNG is required icon format). Dimensions are: 350px width, 350px height (Square format is required).
We highly recommend to add an icon file to all your extensions.
It is highly recommended to add screenshots to your extension so that users will be able to see how it looks if there is no demo available.
Screenshot image format: JPG
Screenshot dimensions (minimum): 1200x900
Screenshots folder: EXTENSION/docs/img/
Below is the common structure for the extension.
templates/
templatename/
css/
img/
docs/
img/
icon.png
changelog.html (optional)
description.html
installation.html (optional)
screenshots.html (optional)
js/
less/ (optional)
packages/ (optional)
plugins/ (optional)
install.xml
layout.tpl
modules/
modulename/
docs/
img/
icon.png
changelog.html (optional)
description.html
installation.html (optional)
screenshots.html (optional)
js/ (optional)
includes/ (optional)
classes/ (optional)
templates/ (optional)
install.xml
Plugin structure depends on the functionality your modules offer. Anyhow, it's recommended to follow the recommended structure. If you have any questions, please comment here.
Once you make sure your extension works fine, you might decide to share it with our community. We offer a way for you to release your extensions and start selling it on our website directly. Of course, you are allowed to release extensions free of charge. I'm sure this move will add much to your karma :) Anyhow, you decide.
So what we need to get started. You should carefully check the following extension attributes:
- Plugin name - it should be unique. Please make sure we don't have an extension with the same name on our website.
- Compatibility - please set the minimum core Subrion version your extension is compatible with.
- Version - it should be X.X.X format. No other versioning is allowed.
- Date - it should be YYYY-mm-dd. Ex: 2016-02-01 stands for 1st February, 2016
Once you make sure the extension data is correct, you need to create a zip file. Please note you must put extension content in zip file, no need to pack the folder itself. So your archive file should contain the following structure:
docs/
img/
icon.png
changelog.html (optional)
description.html
installation.html (optional)
screenshots.html (optional)
js/ (optional)
includes/ (optional)
classes/ (optional)
templates/ (optional)
install.xml
You can upload your extension by using this instruction:
- Go to subrion.org
- Sign in by using your account
- Click on your profile username at the top right
- Move to Extensions
- Click on Upload Extension button
- Fill all the needed fields and upload your extension.
Quickstart
Installation
Adding plugins
Changing front-end template
Creating content
Development
Coding Standards
Naming Conventions
Debug mode
Smarty custom functions
{ia_add_media}
{ia_add_js}
{ia_print_js}
{ia_add_css}
{printImage} (obsolete since 4.1)
{ia_image}
Tutorials
Package installation
Install plugin
Install template
Hybrid Auth Configuration