Please enable JavaScript to view this site.

iService Forms User Guide

Navigation: Form Commands > $Value

$Value -articlelist

Scroll Prev Top Next More

The -articlelist parameter is used to display the various parts of a find answers article within an article list. This list is generated from a search or from a selected topic in a list of find answers topics.

The syntax for the command is:

 

$Value -articlelist(part)$ where part is the aspect of the article that you want to display within the list.

 

Example: Display the subject of an article within a list of articles

$value -articlelist(subject)$ 

 

The options include:

(id|subject|date|topicid|topicname|rating|viewcount|public)

 

A more complete example of usage is shown below.

<div id="searchArea">

   <form method="POST" enctype="multipart/form-data">

      $if -fieldregex'topicID'='$^'$

    <input type="hidden" name="topicID" id="topicID" value="1" />

 $endif$

    <input name="search" id="search" value="$form -id'search'$" /><input type="image" id="ok" name="ok" src="http://www.1to1service.com/images/iServiceCRM/searchButton.png" value="Go" />

 $if -fieldregex'search'='$ *^'$

         <br />

    $else$

         <p>Search Results:</p>

              $if -articlelist(search) -Psearchid'search' -Ptopic'topicID' -Ppagenum'1' -Pperpage'100' -Psort'DATE_REVERSE'$

                 <table>

                  <tr><th>Subject</th><th>Date</th><th>Rating</th><th>Viewed</th><th>Topic</th></tr>

                   $repeat -articlelist(search) -Psearchid'search' -Ptopic'topicID' -Ppagenum'1' -Pperpage'100' -Psort'DATE_REVERSE'$

                   <tr>

                      <td>$value -articlelist(subject)$</td>

                      <td>$value -articlelist(date)$</td>

                      <td>$value -articlelist(rating)$</td>

                      <td>$value -articlelist(viewcount)$</td>

                      <td>$value -articlelist(topicname)$</td>

                    </tr>

                    $endrepeat$

                  </table>

                $else$

                  <p>There are no articles.</p>

                $endif$

      $endif$  

   </form>

</div>

 

The above find answers search generates a list of articles that includes columns for the article subject, date, rating, viewcount, and topic name.