dynamic-large.jpg

Dynamic Asset Listings

By Liam Coltman posted on 14 Aug 2010

What is it?

A listing of the documents, files, images or whatever other assets you choose to display for the current page.

Functionality: Global

Assets used: Asset Listing, Design, Design Customisation

How do I do it?

Configure the Asset Listing

  1. Make an Asset Listing and give it an appropriate name
  2. Acquire the locks and select the asset types you would like to list, for this example we will use PDF File and MS Word Document
  3. Select Live from the Asset Statuses to List section
  4. Select the Root Node from Asset Locations. As we are creating a dynamic listing you need to select the tree area where the listing will be used, it should be set as high as possible so at the site level is perfect. (TIP: You can set multiple root nodes and use this listing across several sites, as we are replacing the node it is listing from it will never show content across sites)

    Set root node screenshot
  5. Set Direct Links Only to Yes forcing the listing to only look under the current asset being viewed
  6. Move down to the Customise No Results Bodycopy and set this to No, there is no need to tell your readers that there are no documents for this page
  7. Change the Dynamic Parameter to Replacement Root node for the listing (must be a child of the static root node) and set Source to Current Asset

    Set dynamic root node screenshot
  8. Commit the changes

Create a space in your Design File

  1.  Navigate to your Design, right click on it and go to Edit Parse File (TIP: Whenever you edit your parse file it's a good idea to take a copy in case any changes you make turn up some unexpected surprises.)
  2. In the appropriate area of your design add in a nest content area
    <MySource_AREA id_name="file_listing" design_area="nest_content" print="no">
        <MySource_SET name="type_codes" value="page" />
    </MySource_AREA>
  3. Commit the Parse file
  4. Right click on the Parse file and select Customisations
  5. Acquire the locks
  6. Tick the box to create a new customisation and give it an appropriate name then commit it

    Create design customisation screenshot
  7. Click on the link to go to the newly create Design Customisation
  8. Find the design area for file_listing that you just created and tick the Customise box next to it and click commit

    Customise design area screenshot
  9. The design area should now move to the Customised area. Now click on the link to select it.
  10. Acquire the lock if required and set Print to Yes.
  11. Under the Link area change the Nested Asset to the Asset Listing you created in the steps above

All that's left to do is to apply the design customisation to the appropriate pages in your site.

Once everything is working you can go back to the Asset Listing and edit the type formats for the different formats you selected so they display differently in the listing.  It's a good idea to change the different file names and if you really like you can set unique icons for the different file types.

It's also possible to nest the Asset Listing into a paint layout instead of a design customisation which allows you to control where it appears within the content of the page rather than in the design.


Comments


There are currently no comments for this article. Why not be the first to post a comment?

Build your own search

By Ladoo posted on 20 Oct 2011

You can create your own personal Search Page to assist with locating and editing the content you look after. This can be especially helpful in larger systems where quick search becomes less accurate.

Output content to a file

By Ladoo posted on 17 Nov 2011

As well as HTML and text, Matrix can be configured to directly output XML, iCal, RTF and even Word and Excel documents, so that users can directly download and work with these files.

Pretty as a picture Image Gallery

By Liam Coltman posted on 13 Nov 2010

Image Galleries can help to add a bit of colour to your website. With a little bit of tinkering you can make an image gallery that will rival the Louvre

Comment all you want

By Liam Coltman posted on 08 Sep 2011

Using a combination of an Asset Builder and an Asset Listing in Mysource Matrix can allow you to create a comment area in your website and can be used for blogs.

Trigger happy images

By Liam Coltman posted on 23 Aug 2010

Triggers are a very powerful feature in MySource Matrix. Learn how to set up a trigger to create image varieties

Paint Layouts

By Liam Coltman posted on 06 Mar 2010

The best way to think of a Paint Layout is a Design File for your page content.

News delivered to your doorstep

By Liam Coltman posted on 10 Sep 2010

With users becoming more and more demanding on their news and website updates RSS provides the perfect option to keep readers up to date with what is happening on your site.

Matrix PHP API - Creating Standard Page Assets

By Anton Babushkin posted on 28 Feb 2011

Using the Matrix PHP API can allow you to do more than you previously would have thought possible. This article will teach you how to create Standard Page assets as well as give you some insight into when you could utilize the PHP API in the real world.

Release notes for Matrix 1.2

By Anton Babushkin posted on 16 Jul 2013

You can create your own personal Search Page to assist with locating and editing the content you look after. This can be especially helpful in larger systems where quick search becomes less accurate.

Search

By Ladoo posted on 23 Feb 2012

Most content management systems only offer basic search functionality, and Matrix is no exception.