» MSAS Documentation

MSAS documentation

• Note that many of the configuration options are explained via tooltips in the admin backend.


» Installation

» Template Configuration

» Using Paths

» Template Tags

Hosts that have subpar php configurations that we simply do not support:

  1. hostmonster.com

back to top

Installation:

  1. Upload everything from the UPLOAD folder to where you want your MSAS script installed.
  2. Open your browser and navigate to [msas install location]/install.php and follow the on-screen directions.

back to top

Using Paths:

There are 3 types of paths available to you in the (msas) templating enging. All returned paths include a trailing slash

  • URL: (->url)
    ->url->tohome
    output: http:// url path to the root directory (msas) is installed.
    ->url->totemplate
    output: http:// url path to the (msas) template directory currrently in use.
    ->url->touploads
    output: http:// url path to the /uploads directory
  • Absolute: (->abs)
    ->abs->tohome
    output: absolute system path to the root directory (msas) is installed.
    ->abs->totemplate
    output: absolute system path to the (msas) template directory currrently in use.
    ->abs->touploads
    output: absolute system path to the /uploads directory
  • Relative: (->rel)
    ->rel->tohome
    output: relative (from root of web directory) system path to the root directory (msas) is installed.
    ->rel->totemplate
    output: relative (from root of web directory) system path to the (msas) template directory currrently in use.
    ->rel->touploads
    output: relative (from root of web directory) system path to the /uploads directory

back to top

Template Tags

BreadCrumbs()

Returns the breadcrumbs information as an object.
Example: Open templates/default/inc_breadcrumb.php

GetAd()

Gets the ad with the coorosponding you have created in your admin back end.

GetContent()

A list of ampersand (&) separated arguments in a similar style to a querystring, i.e:
var1=kung&var2=foo&var3=bar

This is the Uber function that does most of the magic in MSAS. First let's start with an example:

Example: GetContent("type=layout&sortby=downloads&limit=5&page=no&getads=no") Returns an object containing 5 layouts ordered by the number of downloads (ascending) and will not show pagination or list ads. Cool huh?

Example 2: GetContent("type=image&query=funny&limit=10&order=date") Returns an object containing up to 10 videos with titles or descriptions that have the word "funny" in them ordered from newest to oldest.

Here are a list of the parameters you can pass to GetContent()

type
Content type to return: layout, image, video, content. Default: layout
restrict
Used to get content at the current URL by: current, category, type. Default: type
sortby
Method to sort by: date, name, rating, views, downloads, random. Default: date (note: for images and videos views = downloads)
order
Order to sort: asc, desc. Default: desc
query
Search query string.
category
Category to search in if query is set.
limit
Number of rows to get. Default: LIMITMAX
page
Page content: yes,no. Default: yes
getads
Get list ads: yes,no. Default: yes
raw
Just return mysql rowset: yes,no. Default: no

GetCategoryTree()

A list of ampersand (&) separated arguments in a similar style to a querystring, i.e:
var1=kung&var2=foo&var3=bar

start
Category id to start with. 0 is {root}. Default is 0
depth
Depth of categories to show. Default is 1
ul_class
class name to give the ul tag. Default is 'menu'
ul_sub_class
class name to give any children ul tags. Default is 'sub'
li_class
class name to give li tags. Default is none
a_class
class name to give a tags. Default is none
a_before
html to put before the category link. Default is none
a_after
html to put after the category link. Default is none
link_before
html to put before the link text. Default is none
link_after
html to put after the link text. Default is none
show_count
Show the content count. Takes either yes or no. Default is yes.
count_tag
What tag to wrap the content count in. Default is 'span'

GetSetting()

Returns value of requested information from options table.
Example: <? echo GetSetting('sitename'); ?> will print out the name you set for your site in the options panel.

GetExchangeLinks()

Returns all of the active exchange links

isCategory()

This will return true if a user is viewing a category

isImage()

This will return true if a image is being requested

isLayout()

This will return true if a layout is being displayed

isPreview()

This will return true if a user is previewing a layout

isSearch()

This will return true if a search is being preformed

isContent()

This will return true if the user is displaying a content page.

isNewContent()

This will return true if the user is displaying a content page in a category.

GetMySpaceId()

This will return the users myspace id, if it isnt set it will return the default

SetMySpaceId()

This will set the myspace ID, you do not actually need to call this. All that needs to be done is have a form that uses post, and have the variable called "myspaceid", which the user inputs there myspace id into.

UnSetMySpaceId()

This will unset a myspace id, once again you do not acctually need to call this function, just have a form with a hidden field called "unsetmyspaceid", and it will happen automaticlly when the user submits the form.

ClearMySpaceProfile()

This will clear the current MySpace profile cache, you do not need to call this function directly, just have a form with a hidden form field called "clearcache".
Page Visitors: 2668, Last Visitor was Guest at Today - 04:34 AM.
Page Created at April 4th, 2009 - 12:12 AM, Last Modified : April 15th, 2009 - 07:03 PM.

All times are GMT -8. The time now is 08:42 AM.
 


Powered by: vBulletin Version 3.7.1 & Logician's WebTemplates v.3.6.03
vBulletin Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
© 2005-2009 MySpacePros.com