<?xml version="1.0" encoding="utf-8"?>
<s1 title="PrepareParameters"><table><strong class="highlight"><![CDATA[]]></strong><tr><td><strong class="highlight"><![CDATA[]]></strong><p>Usage: </p>
</td><td><strong class="highlight"><![CDATA[]]></strong><p>PrepareParameters(&quot;string&quot;) </p>
</td></tr><tr><td><strong class="highlight"><![CDATA[]]></strong><p>Example: </p>
</td><td><strong class="highlight"><![CDATA[]]></strong><p>PrepareParameters(&quot;This is a test&quot;) </p>
</td></tr></table><p>This function will convert a string into an array of parameters. It will split any non-whitespace character, and can handle quotes and other punctuation. </p>
<ul><li><source><![CDATA[Example 1:
arr = PrepareParameters("This is a test")
echo arr

Result:
21:51:36 This,is,a,test
21:51:37 Script stopped

Example 2:
arr = PrepareParameters("this is a /test 'with spaces and quotes'")
echo arr

21:55:17 (5) - this,is,a,/test,with spaces and quotes
21:55:18 (5) - Script stopped

Example 3:
arr = PrepareParameters("this is a test /a=\"qqq ww\" s")
echo arr

Result:
21:52:40 this,is,a,test,/a=qqq ww,s
21:52:41 Script stopped]]></source></li>
</ul>
<p></p>

<br/>------------------------------------------------------------------------------<br/>
<p> <jump href="/wiki/CategoryFunctions">CategoryFunctions</jump> </p>
</s1>