You are here

function insert_view_filter_tips in Insert View 6.2

Same name and namespace in other branches
  1. 5 insert_view.module \insert_view_filter_tips()
  2. 6 insert_view.module \insert_view_filter_tips()
  3. 7.2 insert_view.module \insert_view_filter_tips()

Implementation of hook_filter_tips().

File

./insert_view.module, line 29
Insert view.

Code

function insert_view_filter_tips($delta, $format, $long = FALSE) {
  if ($long) {
    return '<br />' . t('<dl>
<dt>Insert view filter allows to embed views using tags. The tag syntax is relatively simple: [view:name=display=args]</dt>
<dt>For example [view:tracker=page=1] says, embed a view named "tracker", use the "page" display, and supply the argument "1".</dt>
<dt>The <em>display</em> and <em>args</em> parameters can be omitted. If the display is left empty, the view\'s default display is used.</dt>
<dt>Multiple arguments are separated with slash. The <em>args</em> format is the same as used in the URL (or view preview screen).</dt>
</dl>
Valid examples:
<dl>
<dt>[view:my_view]</dt>
<dt>[view:my_view=my_display]</dt>
<dt>[view:my_view=my_display=arg1/arg2/arg3]</dt>
<dt>[view:my_view==arg1/arg2/arg3]</dt>
</dl>') . '<br />';
  }
  else {
    return t('You may use <a href="@insert_view_help">[view:<em>name=display=args</em>] tags</a> to display views.', array(
      "@insert_view_help" => url("filter/tips/{$format}", array(
        'fragment' => 'filter-insert_view',
      )),
    ));
  }
}