Snippets

Snippets is an extension for Sitemagic CMS that enables you to add boxes (snippets) with information or functionality to a panel on the left or right side of your site. This page takes you through the steps necessary to set it up.

/guide/SnippetsExtension.jpg
 
Install extension
  1. Download SMSnippets.zip containing the neccesary files
  2. Extract SMSnippets.zip
  3. Copy the SMSnippets folder to the extensions folder on the server
  4. Enable extension
    1. Log in
    2. Go to Admin > Settings
    3. Select Snippets in the extensions enabled area
    4. Click the Save button

Add snippet to all pages
To add a box (snippet) that shows up on all pages, simply create a new content page with a filename prefixed with Box:
  1. Go to Content > Pages
  2. Create a new page with the following values:
    Filename: BoxQuickLinks
    Title: Read more
  3. Click the Create button
  4. Select BoxQuickLinks in the Pages area
  5. Click the Edit content button
  6. Enter some content and click the save button
Now browse to an ordinary page - you should see your new snippet on the page.

Add snippet to a specific page
It is possible to have a box (snippet) show up on a specific page only - to achieve this, the filename of the snippet must be prefixed with the name of the page on which it should be displayed, followed by Box - example:
  1. Go to Content > Pages
  2. Create a new page with the following values:
    Filename: IndexBox1
    Title: Welcome info
  3. Click the Create button
  4. Select IndexBox1 in the Pages area
  5. Click the Edit content button
  6. Enter some content and click the save button
This snippet will show up only on the front page (Index).

Limitations
Snippets do not work with pages using the Cards Layout (which is also deprecated), and only static content is supported, meaning Page Extensions such as Contact Forms do not work.

Change the design of snippets
Changing how snippets look and feel is really simple.
  1. Browse to a page containing a snippet
  2. Go to Content > Design (you must be logged in first)
  3. Click on a snippet
The Designer now displays all the properties that can be changed.
Once done, make sure to click the Save button in the designer.
Thanks goes to Frank Rasmussen who financially supported the development of snippets.
Get Sitemagic CMS