<html>
<head>
<link href="mmres://user_interface_reference.css" rel="stylesheet" type="text/css">
<title>REVERSE</title>
</head>
<body bgcolor="#FFFFFF" text="#000000">
   <div id="Description">
   <table cellpadding="0" cellspacing="0" border="0" width="100%" class="main">
      <tr> 
         <td valign="top" class="name">REVERSE</td>
         <td valign="top" nowrap class="compatibility">&nbsp;</td>
      </tr>
      <tr>
         <td colspan="2" class="divider"><img src="dwres:18084" width="100%" height="1"></td>
      </tr>


    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Description</span>
<p>
Reverses the order of items, such as the characters in a string, the digits in a number, or the elements in an array. 
</p>
    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Returns</span>
<p>
A copy of string, with the characters in reverse order.
</p>
    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Category</span>
<p>
String functions
</p>
    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Function syntax</span><pre>Reverse(string)
</pre>    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">See also</span>
<p>
Left, Mid, Right
</p>
    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Parameters</span>
<p>

</p>
    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Usage</span>
<p>
You can call this function on a number with code such as the following:
</p>
<pre>&lt;cfoutput&gt;reverse(6*2) equals #reverse(6*2)#&lt;cfoutput&gt;
</pre>
<p>
This code outputs the following:
</p>
<pre>reverse(6*2) equals 21
</pre>    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Example</span><pre>&lt;h3&gt;Reverse Example&lt;/h3&gt;

&lt;p&gt;Reverse returns your string with the positions of the characters reversed.
&lt;cfif IsDefined(&quot;FORM.myString&quot;)&gt;
   &lt;cfif FORM.myString is not &quot;&quot;&gt;
      &lt;p&gt;Reverse returned:
      &lt;cfoutput&gt;#Reverse(FORM.myString)#&lt;/cfoutput&gt;
   &lt;cfelse&gt;
      &lt;p&gt;Please enter a string to be reversed.
   &lt;/cfif&gt;
&lt;/cfif&gt;

&lt;form action = &quot;reverse.cfm&quot;&gt;
&lt;p&gt;Enter a string to be reversed:
&lt;input type = &quot;Text&quot; name = &quot;MyString&quot;&gt;
&lt;p&gt;&lt;input type = &quot;Submit&quot; name = &quot;&quot;&gt;
&lt;/form&gt;
</pre>
         </td>
      </tr>
   </table>
   </div>
<div id="STRING">
<table border="0" cellspacing="0" cellpadding="0" width="100%">
<tr>  
<td valign="top" class="name">STRING</td>
  <td valign="top" nowrap class="compatibility">&nbsp;</td>
  </tr>
  <tr>
  <td colspan="2" class="divider"><img src="dwres:18084" width="100%" height="1"></td>
  </tr>


<p>A string or a variable that contains one </p>

  </td>
  </tr>
  </table>
</div>

  </body>
</html>
