Making Javascript Variables...not variables
<p>Possibly a silly question, and i'm not sure how to phrase it.</p>

<p>I have an array in a function and I want put it through a loop  print the text, not the variable.  I've just starting banging my head on this, but whats really getting me is how to only print lets say the "category" and value if the value is not empty.  Here's and example to show,  The outcome i'm looking for is "u =1 and x = 1 AND z = 3".  If anyone could point me in the write direction, it would be most helpful.</p>

<pre><code>(categories called from multiple selection menus in text)
s=
t=
u=1
v=
w=
x=1
y=
z=3
function example(s,t,u,v,w,x,y,z) {

    selection=[s,t,u,v,w,x,y,z];
    for (var i=0;;i++)
    {
        if (!selection[i]) {
            selection="";
        }
        else
        {
            selection= selection + 
        };
    }
}
</code></pre>

<p>The outcome i'm looking for is
"u =1 and x = 1 AND z = 3"</p>
