What does this function do? And what is the odd syntax?
<p>Can someone explain what this piece of code does. what is the test function testing for?</p>

<pre><code>temp = "blah"
if ( /from_url=$/.test(temp) ) {
    //do something
}

test : function(s, p) {
    s = s.nodeType == 1 ? s.value : s;

    return s == '' || new RegExp(p).test(s);
}
</code></pre>

<p>Also in the initial condition what does the syntax if(/from_url=$/)  do?</p>
